[ 
https://issues.apache.org/jira/browse/OAK-10904?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17860084#comment-17860084
 ] 

Tushar Rana commented on OAK-10904:
-----------------------------------

Using daemon threads in executor service will force us to rely on JMV to kill 
the thread while terminating and the token executor service will keep on 
running even when the token is no longer needed. A better approach will be to 
extract the logic to a concrete class and shutdown the executor service when 
token is no longer needed.

> Use daemon thread for token refresh executor
> --------------------------------------------
>
>                 Key: OAK-10904
>                 URL: https://issues.apache.org/jira/browse/OAK-10904
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>            Reporter: Mohit Kataria
>            Priority: Major
>
> Executor service by default uses non-daemon thread which was prevents JVM 
> from shutting down. Configure the executor with custom thread factory that 
> will use daemon thread to execute the task which will be terminated when the 
> main thread ends.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to