NIFI-16070: Add nifi-api support for migrateProperties to Connectors.#102
Conversation
* Create api with default implementation
markap14
left a comment
There was a problem hiding this comment.
Thanks @bobpaulin I think this makes sense. I did call out the hasStep/hasProperty - let me know what you think, if there's a strong reason for it or if it makes sense to eliminate. Otherwise I'm in favor of this addition.
| * @param stepName the name of the configuration step | ||
| * @return <code>true</code> if this configuration contains the given step | ||
| */ | ||
| boolean hasStep(String stepName); |
There was a problem hiding this comment.
Is there a benefit in having this over just using getStepNames().contains(stepName)? I'd recommend keeping the interface minimal unless there's a reason for it.
There was a problem hiding this comment.
It is not required. As you've show there is an alternative way to do it. I was trying to stay consistent with https://github.com/apache/nifi-api/blob/main/src/main/java/org/apache/nifi/migration/PropertyConfiguration.java which has a similar redundancy.
Open to removing but I think there is some benefit from providing a consistent approach with Processors and Controller Services.
| * @param propertyName the property name | ||
| * @return <code>true</code> if this step has an entry for the property, including when its value reference is null | ||
| */ | ||
| boolean hasProperty(String propertyName); |
There was a problem hiding this comment.
Similar to hasStep, I'd recommend omitting if there's not a strong reason for having.
There was a problem hiding this comment.
Similar to above. I was trying to stay consistent with https://github.com/apache/nifi-api/blob/main/src/main/java/org/apache/nifi/migration/PropertyConfiguration.java which has a similar redundancy.
Summary
NIFI-16070
API changes to support https://issues.apache.org/jira/browse/NIP-34
Add migrateProperties API to Connector
Tracking
Please complete the following tracking steps prior to pull request creation.
Issue Tracking
Pull Request Tracking
NIFI-00000NIFI-00000Pull Request Formatting
mainbranch