Skip to content
This repository has been archived by the owner on May 30, 2024. It is now read-only.

[com.launchdarkly.client.LDClient] should not WARN about unknown feature flags in test mode. #84

Closed
luke-esther opened this issue Jan 11, 2017 · 4 comments

Comments

@luke-esther
Copy link

luke-esther commented Jan 11, 2017

When a feature flag cannot be found, the client logs at the WARN level:

Unknown feature flag example-feature-flag-key; returning default value

We find it useful in test mode to rely on the default value for features, and only enable/disable features as required. This means we don't have to configure our application to load a default flag list into the client.

The resulting logging statements are painful, and we would like if they could be suppressed in test mode.

@drichelson
Copy link
Contributor

Hi,
Are you able to set the log level to ERROR for the offending class? Most logging frameworks allow you to do this.

@luke-esther
Copy link
Author

luke-esther commented Jan 11, 2017

We can, but we will then miss out on any other warnings that LDClient provides.

@drichelson
Copy link
Contributor

@luke-esther do you mind emailing support@launchdarkly.com and we can continue there?
Thanks

eli-darkly added a commit that referenced this issue Aug 17, 2018
@wildthing81
Copy link

wildthing81 commented Oct 6, 2023

@drichelson Apart from changing granularity of Logger class to suppress this message, is there any other way ?
I also have a feature flag for TEST mode & want to rely on default value for it. don't want to define it in LD portal for all our envs.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants