You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@helix.apache.org by GitBox <gi...@apache.org> on 2021/11/30 14:35:19 UTC

[GitHub] [helix] hmhagberg opened a new issue #1915: GC_THREAD in ZkBucketDataAccessor is not shut down

hmhagberg opened a new issue #1915:
URL: https://github.com/apache/helix/issues/1915


   ### Describe the bug
   `GC_THREAD` (which is actually an `ExecutorService`, not `Thread`) is a static field in `ZkBucketDataAccessor`. The executor is started when `ZkBucketDataAccessor` class is initialized but it is never shut down. Since `ExecutorService` threads are generally not daemon threads, not shutting down `GC_THREAD` prevents JVM from shutting down cleanly.
   
   ### To Reproduce
   Run application which references `ZkBucketDataAccessor` class and then exits. JVM does not shut down but hangs instead.
   
   ### Expected behavior
   Referencing `ZkBucketDataAccessor` class should not prevent clean exit.
   
   ### Additional context
   Workaround is to make `GC_THREAD` field public using reflection and shut it down in application's own shutdown hook.
   


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

To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org


[GitHub] [helix] hmhagberg commented on issue #1915: GC_THREAD in ZkBucketDataAccessor is not shut down

Posted by GitBox <gi...@apache.org>.
hmhagberg commented on issue #1915:
URL: https://github.com/apache/helix/issues/1915#issuecomment-1015203565


   @narendly it took a while but here's PR that aims to solve the issue by daemonizing `GC_THREAD`: https://github.com/apache/helix/pull/1936
   
   Also a small correction to reproduction steps: simply referencing `ZkBucketDataAccessor` is not enough to trigger the issue. `ThreadPoolExecutor` threads are not prestarted by default so it is necessary to schedule some task on `GC_THREAD` to create the thread and trigger the issue.


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

To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org


[GitHub] [helix] narendly commented on issue #1915: GC_THREAD in ZkBucketDataAccessor is not shut down

Posted by GitBox <gi...@apache.org>.
narendly commented on issue #1915:
URL: https://github.com/apache/helix/issues/1915#issuecomment-982763863


   @hmhagberg thanks for the bug report. Feel free to create a Pull Request - we could review this as it seems like a simple fix.


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

To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org


[GitHub] [helix] narendly closed issue #1915: GC_THREAD in ZkBucketDataAccessor is not shut down

Posted by GitBox <gi...@apache.org>.
narendly closed issue #1915:
URL: https://github.com/apache/helix/issues/1915


   


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

To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org