hunyadi-dev commented on a change in pull request #961:
URL: https://github.com/apache/nifi-minifi-cpp/pull/961#discussion_r545093778



##########
File path: extensions/librdkafka/PublishKafka.cpp
##########
@@ -126,7 +126,11 @@ const core::Property PublishKafka::CompressCodec(
 const core::Property PublishKafka::MaxFlowSegSize(
     core::PropertyBuilder::createProperty("Max Flow Segment 
Size")->withDescription("Maximum flow content payload segment size for the 
kafka record. 0 B means unlimited.")
         ->isRequired(false)->withDefaultValue<core::DataSizeValue>("0 
B")->build());
-const core::Property PublishKafka::SecurityProtocol("Security Protocol", 
"Protocol used to communicate with brokers", "");
+const core::Property PublishKafka::SecurityProtocol(
+        core::PropertyBuilder::createProperty("Security Protocol")
+        ->withDescription("Protocol used to communicate with brokers")
+        ->withAllowableValues<std::string>({SECURITY_PROTOCOL_PLAINTEXT, 
SECURITY_PROTOCOL_SSL, SECURITY_PROTOCOL_SASL_PLAINTEXT, 
SECURITY_PROTOCOL_SASL_SSL})

Review comment:
       1. Feel free to delete unused parts.
   2. Up to you. If you feel fancy, you can extend the property API to be able 
to return the allowable values and check against presence there.
   3. Yes.  The more important thing is that we are compatible with NiFi 
configs, but compatibility in the other direction is probably nice to have.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to