ololo3000 commented on a change in pull request #7647: IGNITE-12879 Refactors 
test configuration of discovery messages interceptors.
URL: https://github.com/apache/ignite/pull/7647#discussion_r409404712
 
 

 ##########
 File path: 
modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TestTcpDiscoverySpi.java
 ##########
 @@ -44,4 +54,24 @@
     @Override public void simulateNodeFailure() {
         super.simulateNodeFailure();
     }
+
+    /** {@inheritDoc} */
+    @SuppressWarnings("ZeroLengthArrayAllocation")
+    @Override public void setListener(@Nullable DiscoverySpiListener lsnr) {
+        super.setListener(lsnr ==  null || discoHooks.isEmpty() ?
 
 Review comment:
   addDiscoveryHook method asserts that it must be called only before 
TcpDiscoverySpi start. So it's impossible to use addDiscoveryHook after 
listener is set.

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to