We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
AppConfig.java
package app; import java.util.Optional; import io.smallrye.config.ConfigMapping; import io.smallrye.config.WithDefault; @ConfigMapping(prefix = "o-sso") public interface AppConfig { @WithDefault("300") int tokenDuration(); Provider prov1(); Provider prov2(); interface Provider { @WithDefault("false") boolean allowAll(); @WithDefault("false") boolean enabled(); Optional<String> whiteList(); Optional<String> cert(); @WithDefault("ANY") Env env(); Optional<Integer> tokenDuration(); default boolean isActivated() { return enabled() && (whiteList().isPresent() || cert().isPresent()); } enum Env { PROD, STAGING, ANY } } }
When I try to write in my application.properties file, beginning with 'o-sso', only keys for my first "Provider" appears:
application.properties
o-sso.prov1.allow-all o-sso.prov1.cert o-sso.prov1.enabled o-sso.prov1.white-list o-sso.token-duration
What I expected:
o-sso.prov1.allow-all o-sso.prov1.cert o-sso.prov1.enabled o-sso.prov1.white-list o-sso.prov2.allow-all o-sso.prov2.cert o-sso.prov2.enabled o-sso.prov2.white-list o-sso.token-duration
The text was updated successfully, but these errors were encountered:
angelozerr
No branches or pull requests
AppConfig.java
When I try to write in my
application.properties
file, beginning with 'o-sso', only keys for my first "Provider" appears:What I expected:
The text was updated successfully, but these errors were encountered: