Open jonSeetrue opened 1 year ago
Hi @banesullivan This pr fixes the memory issues of the open workers, could you review it, please?
Hi @jonSeetrue, I'm not an active developer or maintainer of this software nor am I familiar with the exact issue referred to here, so I don't think I'm the right person to review this.
Though, as a member of the user community, I think I can speak for everyone in saying thank you for this contribution and likely impactful fix!
@thewtex do you mean to collect all the workers into an array on the viewer object and when loading a new image call terminateWorkers()?
@jonSeetrue a cleanup()
function on the viewer that calls terminateWorkers()
on the worker pools when called. Loading a new image will not need a call. I am not sure if an array on the viewer object is needed.
@thewtex the worker-pool is not exported, so should the cleanup() function be part of each worker-pool implementation?
@jonSeetrue yes, that could work :+1:
Fix the memory leak issue. close all workers when done processing.