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
MINIFICPP-393: Add security support for MQTT #259
Conversation
extensions/mqtt/ConsumeMQTT.cpp
Outdated
@@ -35,7 +35,7 @@ namespace nifi { | |||
namespace minifi { | |||
namespace processors { | |||
|
|||
core::Property ConsumeMQTT::MaxQueueSize("Max Flow Segment Size", "Maximum flow content payload segment size for the MQTT record", ""); | |||
core::Property ConsumeMQTT::MaxQueueSize("Max Queue Size", "Maximum receive queue size for the MQTT record", ""); |
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.
May not want to change a variable name. If someone is using this option it may break their configuration.
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.
we need to correct that because the variable is not right in the first place. also if user was using that option, it will default to the default value.
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.
Do we intend to follow semver?
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.
The previous version of the parameter configuration is wrong so that is no backward compatible.
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 see your point that the variable name doesn't equal the option name "Max Flow Segment Size" vs "Max Queue Size" , but if a user happens to be using "Max flow segment size" per the option we've changed the semantics of what they want. Does that make sense? We should have that option available to them until we can deprecate it. Further, "receive queue size" seems to not connote if the size is in the number of flow files or the number of bytes. That should be clarified.
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.
Fixed in latest commit
|
||
if (context->getProperty(SecurityProtocol.getName(), value) && !value.empty()) { | ||
if (value == MQTT_SECURITY_PROTOCOL_SSL) { | ||
sslEnabled_ = true; |
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.
what happens if a cert isn't specified or the CA isn't specified but needs to be?
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.
the SSL handshake will fail and based on the error, user need to config the right certs.
c5d46bd
to
a1d9bc8
Compare
This closes apache#259. Signed-off-by: Bin Qiu <benqiu2016@gmail.com>
Thank you for submitting a contribution to Apache NiFi - MiNiFi C++.
In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:
For all changes:
Is there a JIRA ticket associated with this PR? Is it referenced
in the commit message?
Does your PR title start with MINIFI-XXXX where XXXX is the JIRA number you are trying to resolve? Pay particular attention to the hyphen "-" character.
Has your PR been rebased against the latest commit within the target branch (typically master)?
Is your initial contribution a single, squashed commit?
For code changes:
For documentation related changes:
Note:
Please ensure that once the PR is submitted, you check travis-ci for build issues and submit an update to your PR as soon as possible.