Closed timtebeek closed 9 months ago
When gradually promoting a feature, at some point you might want to flip the fallback default value, in the real value can not be retrieved.
A recipe should find usages of the specified key, and change the default value.
Configure feature flag used.
import com.launchdarkly.sdk.LDContext; import com.launchdarkly.sdk.server.LDClient; class Foo { void bar(LDClient client, LDContext context) { if (client.boolVariation("flag-key-123abc", context, false)) { System.out.println("Feature is on"); } } }
import com.launchdarkly.sdk.LDContext; import com.launchdarkly.sdk.server.LDClient; class Foo { void bar(LDClient client, LDContext context) { if (client.boolVariation("flag-key-123abc", context, true)) { System.out.println("Feature is on"); } } }
What problem are you trying to solve?
When gradually promoting a feature, at some point you might want to flip the fallback default value, in the real value can not be retrieved.
A recipe should find usages of the specified key, and change the default value.
What precondition(s) should be checked before applying this recipe?
Configure feature flag used.
Describe the situation before applying the recipe
Describe the situation after applying the recipe