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/11 01:49:00 UTC

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

     [ https://issues.apache.org/jira/browse/SCB-1710?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Haishi Yao resolved SCB-1710.
-----------------------------
    Fix Version/s: java-chassis-2.0.0
       Resolution: Fixed

> 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
>            Priority: Major
>             Fix For: java-chassis-2.0.0
>
>          Time Spent: 20m
>  Remaining Estimate: 0h
>
> 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)