NIFI-14555 - Option to empty parameter values in git registry clients#9927
NIFI-14555 - Option to empty parameter values in git registry clients#9927exceptionfactory merged 4 commits intoapache:mainfrom
Conversation
exceptionfactory
left a comment
There was a problem hiding this comment.
Thanks @pvillard31, the general concept sounds useful. As I often comment on Boolean properties, this might be better expressed as an enumeration like Parameter Context Values with options of Retain and Remove, with Retain being the default option. Perhaps there aren't other options, but raising it for consideration. What do you think?
|
Thanks @exceptionfactory - good point, adjusted the code |
exceptionfactory
left a comment
There was a problem hiding this comment.
Thanks for adjusting the approach @pvillard31. I noted one more recommendation to use an enum implementing DescribedValue for the definition, then this should be ready to go.
| static final AllowableValue RETAIN = new AllowableValue("retain", "Retain", "Will not modify the parameter values"); | ||
| static final AllowableValue REMOVE = new AllowableValue("remove", "Remove", "Will remove the parameter values"); |
There was a problem hiding this comment.
Instead of using AllowableValue, it would be helpful to define this as an enum, there the enum name can be the value itself, as opposed to the lowercase retain and remove. This also makes the property retrieval cleaner with asAllowableValue().
There was a problem hiding this comment.
Thanks @exceptionfactory - pushed a commit to use an enum instead
exceptionfactory
left a comment
There was a problem hiding this comment.
Thanks for the updates @pvillard31, I pushed a small change to use the enum name() instead of an additional String value, aligning with other enum values. I plan to merge following a successful build.
Summary
NIFI-14555 - Option to empty parameter values in git registry clients
The goal of this PR is to add an optional property for all Git based registry clients. The property "Empty Parameters" will default to false to retain current behavior. If set to true, all values of all parameters will be removed before the flow is being versioned and stored in the git repo.
Parameters are usually environment dependent and it might not be desirable to include in the versioned flow the parameters values that have been set in a lower/dev environment while designing the flow.
Tracking
Please complete the following tracking steps prior to pull request creation.
Issue Tracking
Pull Request Tracking
NIFI-00000NIFI-00000Pull Request Formatting
mainbranchVerification
Please indicate the verification steps performed prior to pull request creation.
Build
mvn clean install -P contrib-checkLicensing
LICENSEandNOTICEfilesDocumentation