-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
NIFI-14109 Refactored remaining processors and control services to be uniform when creating properties and relationships. #9600
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -125,7 +125,7 @@ public class AzureEventHubRecordSink extends AbstractControllerService implement | |
.required(false) | ||
.build(); | ||
|
||
private static final List<PropertyDescriptor> PROPERTY_DESCRIPTORS = List.of( | ||
private static final List<PropertyDescriptor> PROPERTIES = List.of( | ||
SERVICE_BUS_ENDPOINT, | ||
EVENT_HUB_NAMESPACE, | ||
EVENT_HUB_NAME, | ||
|
@@ -143,7 +143,7 @@ public class AzureEventHubRecordSink extends AbstractControllerService implement | |
|
||
@Override | ||
protected List<PropertyDescriptor> getSupportedPropertyDescriptors() { | ||
return PROPERTY_DESCRIPTORS; | ||
return PROPERTIES; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As I look through here it is clearly inconsistent whether we use the term properties, descriptors, or property descriptors. However, we should be careful. These things we're messing with in all these files are PropertyDescriptor objects. They're not actually properties. If we're going to establish more consistency we should consider using the term DESCRIPTOR or PROPERTY_DESCRIPTOR but probably not simply PROPERTIES There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. How about PROPERTY_DESCRIPTORS (plural)? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah sorry I meant the plural form (what it was originally). |
||
} | ||
|
||
protected EventHubProducerClient createEventHubClient(final String namespace, | ||
|
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.
Here the parent class 'getCommonPropertyDescriptors' method is removed and instead a subclass is supposed to know to use the static list of descriptors as they build their own lists. I think this weakens what the author intended in building that class.
Also there is at least one example much later on in this PR where you kept the parent method. I think keeping the parent method better conveys intent to any subclassers.
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.
I will revert this back.