-
Notifications
You must be signed in to change notification settings - Fork 121
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
Add JsonProperty to ControlPlanePluginConfig constructor parameter #996
Conversation
Modification: - Add `JsonProperty` to `ControlPlanePluginConfig` constructor parameter Result: - You can now configure `ControlPlanePluginConfig` via configuration file properly.
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.
👍 👍 👍
@@ -26,7 +28,7 @@ public final class ControlPlanePluginConfig extends AbstractPluginConfig { | |||
/** | |||
* Creates a new instance. | |||
*/ | |||
public ControlPlanePluginConfig(@Nullable Boolean enabled) { | |||
public ControlPlanePluginConfig(@JsonProperty("enabled") @Nullable Boolean enabled) { |
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.
Don't we need @JsonCreator
?
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.
It's not needed when there's only one constructor. Let me add it though for clarity.
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.
Thanks! 🙇♂️🙇♂️
Modification:
JsonProperty
toControlPlanePluginConfig
constructor parameterResult:
ControlPlanePluginConfig
via configuration file properly.