-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor(deriv_feature_flag): DERG-1561 Integration_of_Growthbook #444
Conversation
@ilya-deriv this is a wrong approach. This approach will make our client applications to be tightly coupled to our package. |
@ilya-deriv i have a question from you. your key is inside your growthBook dashboard. In order to pass it to the package, you need to have it somewhere in runtime. How do you want to handle it? |
Hi @horam-deriv thanks for checking this. |
Hi @ilya-deriv |
@horam-deriv thank you, I got your point. |
@horam-deriv Making the feature flag package dependant to deriv_env, reduces the flexibility of the package. abstract class FeatureFlagService {
} class DerivGrowthBook implements FeatureFlagService {
} class GrowthBookConfig {
final String url;
final String apiKey;
...
} class DerivFeatureFlag {
/// Initilize the FeatureFlag service for the whole app.
Future<void> initialize(FeatureFlagService) async {
...
}
.. In DerivGO side: DerivFeatureFlag().initialize(DerivGrowthBook(GrowthBookConfig(url, key))); the feature flag provides the default implementation which is |
I agree with @ramin-deriv’s approach. Including flexibility issue, having deriv_env as dependency in growthbook package might need extra maintenance because if a change happen in deriv_env we have to change in both app and the package itself.
|
this pr has been handled in #477 |
Clickup link:
https://deriv-group.slack.com/archives/C04U81FL9D4/p1707119424046629
This PR contains the following changes:
Developers Note (Optional)
Pre-launch Checklist (For PR creator)
As a creator of this PR:
Reviewers
@horam-deriv
Pre-launch Checklist (For Reviewers)
As a reviewer I ensure that:
Pre-launch Checklist (For QA)
Pre-launch Checklist (For Maintainer)