-
Notifications
You must be signed in to change notification settings - Fork 33
Update configuration to load from yaml or env vars. #147
Conversation
We don't currently have docs for the configuration. I made a new issue to address that: #148 |
val automaticHostTag = config[AgentConfig.automaticHostTag] | ||
val input: InputManagerModule = config[AgentConfig.input] | ||
val output: OutputManagerModule = config[AgentConfig.output] | ||
val searchDomain = config[AgentConfig.searchDomain] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this be SearchDomainDiscovery?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The type is SearchDomainDiscovery
but I kept the original variable name of searchDomain
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the object type still is - down below the config will return val searchDomain by lazy { SearchDomainDiscovery.supplyDefault() }
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1 general comment about the shading - lgtm
@@ -119,6 +124,18 @@ | |||
<goals> | |||
<goal>shade</goal> | |||
</goals> | |||
<configuration> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what is this for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are apparently signed jar dependencies that cause the shading to fail with a security error. The filter removes the signed artifacts from the jars its bundling so that the JVM will actually run it.
val automaticHostTag = config[AgentConfig.automaticHostTag] | ||
val input: InputManagerModule = config[AgentConfig.input] | ||
val output: OutputManagerModule = config[AgentConfig.output] | ||
val searchDomain = config[AgentConfig.searchDomain] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the object type still is - down below the config will return val searchDomain by lazy { SearchDomainDiscovery.supplyDefault() }
Env vars are the preferred way to configure ffwd when its running in kubernetes, and will be needed for #132
This also fixes #120 since the Konf library ignores unknowns by default.