brusdev commented on a change in pull request #2759: ARTEMIS-2408 Too many 
opened FDs after server stops
URL: https://github.com/apache/activemq-artemis/pull/2759#discussion_r305344785
 
 

 ##########
 File path: 
artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ActiveMQServerImpl.java
 ##########
 @@ -1269,6 +1269,8 @@ void stop(boolean failoverOnServerShutdown, final 
boolean criticalIOError, boole
          this.analyzer = null;
       }
 
+      activateCallbacks.clear();
 
 Review comment:
   After start, stop and another start we have two activateCallbacks for 
FileLockNodeManager one from first start and one from second start. During 
second server start nodeManager.start/setUpServerLockFile is called on the new 
FileLockNodeManager but setLive/writeFileLockStatus is also called on previous 
FileLockNodeManager.
   When setLive/writeFileLockStatus is called even on previous 
FileLockNodeManager the channel is closed (this is right, it is closed on the 
previous stop) so setUpServerLockFile is called an this is the file leak cause. 
So I think that who register an activateCallback for FileLockNodeManager on 
start has to unregister that activateCallback on stop, wdyt?

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


With regards,
Apache Git Services

Reply via email to