You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@servicecomb.apache.org by "Haishi Yao (Jira)" <ji...@apache.org> on 2020/01/09 07:26:00 UTC

[jira] [Created] (SCB-1710) The scheduled tasks in RemoteServiceRegistry may be interrupted by exception

Haishi Yao created SCB-1710:
-------------------------------

             Summary: The scheduled tasks in RemoteServiceRegistry may be interrupted by exception
                 Key: SCB-1710
                 URL: https://issues.apache.org/jira/browse/SCB-1710
             Project: Apache ServiceComb
          Issue Type: Bug
          Components: Java-Chassis
    Affects Versions: java-chassis-1.3.0
            Reporter: Haishi Yao
            Assignee: Haishi Yao


In org.apache.servicecomb.serviceregistry.registry.RemoteServiceRegistry, the scheduled tasks are executed in a ScheduledThreadPoolExecutor. And in order to ensure the tasks are never interrupted by exceptions, a customed ThreadFactory are specified and the run method of the Threads are overrided to catch all of the Throwables.

But the tasks are added into the ScheduledThreadPoolExecutor in Runnable form. And although the thrown Throwables will not interrupt the threads in the exector, the interrupted tasks are never executed anymore.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)