adamdebreceni commented on a change in pull request #943:
URL: https://github.com/apache/nifi-minifi-cpp/pull/943#discussion_r532418781



##########
File path: extensions/standard-processors/processors/GetTCP.h
##########
@@ -212,29 +207,29 @@ class GetTCP : public core::Processor, public 
state::response::MetricsNodeSource
    * @param sessionFactory process session factory that is used when creating
    * ProcessSession objects.
    */
-  virtual void onSchedule(const std::shared_ptr<core::ProcessContext> 
&processContext, const std::shared_ptr<core::ProcessSessionFactory> 
&sessionFactory);
+  void onSchedule(const std::shared_ptr<core::ProcessContext> &processContext, 
const std::shared_ptr<core::ProcessSessionFactory> &sessionFactory) override;
 
-  void onSchedule(core::ProcessContext *processContext, 
core::ProcessSessionFactory *sessionFactory) {
-    throw std::exception();
+  void onSchedule(core::ProcessContext *processContext, 
core::ProcessSessionFactory *sessionFactory) override {
+    throw std::logic_error{"GetTCP::onSchedule(ProcessContext*, 
ProcessSessionFactory*) is unimplemented"};
   }
   /**
    * Execution trigger for the GetTCP Processor
    * @param context processor context
    * @param session processor session reference.
    */
-  virtual void onTrigger(const std::shared_ptr<core::ProcessContext> &context, 
const std::shared_ptr<core::ProcessSession> &session);
+  void onTrigger(const std::shared_ptr<core::ProcessContext> &context, const 
std::shared_ptr<core::ProcessSession> &session) override;
 
-  virtual void onTrigger(core::ProcessContext *context, core::ProcessSession 
*session) {
-    throw std::exception();
+  void onTrigger(core::ProcessContext *context, core::ProcessSession *session) 
override {
+    throw std::logic_error{"GetTCP::onTrigger(ProcessContext*, 
ProcessSession*) is unimplemented"};

Review comment:
       the same reasoning applies here I believe, that we should move the 
`onTrigger` implementation to this method and leave the smart-pointer-taking 
`onTrigger` to its default behavior




----------------------------------------------------------------
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