Hi there,
I have been working on PersistentTTLNode recipe lately to fix 
https://github.com/apache/curator/issues/1258. I have realized that the recipe 
is leaking threads in a certain scenario.
The recipe allows to be constructed using a provided ScheduledExecutorService  
or using an internally created Executor. The code tries to be generic and when 
closing the recipe is only cancelling recipe touch task, BUT the Executor is 
never shutdown. That means that when the Executor is internally created, the 
Executor Thread will remain there forever. In my view that is leak that should 
solved by distinguishing the case in which Executor is created internally or 
provided externally. In the first the case the Executor MUST be shutdown when 
the recipe is closed.
Let me know if you agree with analysis and I will open a new ticket.
Regards,
/Cheva

Reply via email to