[GitHub] nifi-minifi-cpp pull request #269: MINIFICPP-411: Resolve issues with comman...

2018-02-28 Thread asfgit
Github user asfgit closed the pull request at:

https://github.com/apache/nifi-minifi-cpp/pull/269


---


[GitHub] nifi-minifi-cpp pull request #269: MINIFICPP-411: Resolve issues with comman...

2018-02-28 Thread phrocker
Github user phrocker commented on a diff in the pull request:

https://github.com/apache/nifi-minifi-cpp/pull/269#discussion_r171185379
  
--- Diff: controller/MiNiFiController.cpp ---
@@ -178,7 +177,7 @@ int main(int argc, char **argv) {
   auto& components = result["stop"].as();
   for (const auto& component : components) {
 auto socket = secure_context != nullptr ? 
stream_factory_->createSecureSocket(host, port, secure_context) : 
stream_factory_->createSocket(host, port);
-if (!stopComponent(std::move(socket), component))
+if (stopComponent(std::move(socket), component))
--- End diff --

The intent was to actually return false when writes failed. This is an 
oversight. Thanks 


---


[GitHub] nifi-minifi-cpp pull request #269: MINIFICPP-411: Resolve issues with comman...

2018-02-27 Thread apiri
Github user apiri commented on a diff in the pull request:

https://github.com/apache/nifi-minifi-cpp/pull/269#discussion_r171160623
  
--- Diff: README.md ---
@@ -712,6 +712,7 @@ These are defined by default to the above values. If 
the port option is left und
 will be disabled in your deployment.
 
  The executable is stored in the bin directory and is titled 
minificontroller. Available commands are listed below.
+ Note that with all commands and immediate response by the agent isn't 
guaranteed. In all cases the agent assumes the role of validating that a 
response was received, but execution of said command may take some time 
depending on a number of factors to include persistent storage type, size of 
queues, and speed of hardware. 
--- End diff --

minor: and -> an


---


[GitHub] nifi-minifi-cpp pull request #269: MINIFICPP-411: Resolve issues with comman...

2018-02-27 Thread apiri
Github user apiri commented on a diff in the pull request:

https://github.com/apache/nifi-minifi-cpp/pull/269#discussion_r171160556
  
--- Diff: controller/MiNiFiController.cpp ---
@@ -178,7 +177,7 @@ int main(int argc, char **argv) {
   auto& components = result["stop"].as();
   for (const auto& component : components) {
 auto socket = secure_context != nullptr ? 
stream_factory_->createSecureSocket(host, port, secure_context) : 
stream_factory_->createSocket(host, port);
-if (!stopComponent(std::move(socket), component))
+if (stopComponent(std::move(socket), component))
--- End diff --

I agree this is definitely the right intent, but it appears as though we 
are not handling/propagating the returned value for writeData in 
sendSingleCommand which always returns true.


---