You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by GitBox <gi...@apache.org> on 2021/10/25 07:03:29 UTC

[GitHub] [dubbo] kylixs commented on a change in pull request #8954: [3.0] run timeout task in separate thread to avoid the worker thread blocking

kylixs commented on a change in pull request #8954:
URL: https://github.com/apache/dubbo/pull/8954#discussion_r735309115



##########
File path: dubbo-common/src/main/java/org/apache/dubbo/rpc/model/FrameworkModel.java
##########
@@ -142,7 +148,11 @@ synchronized void removeApplication(ApplicationModel model) {
 
     synchronized void tryDestroy() {
         if (applicationModels.size() == 0) {
-            destroy();
+            synchronized (destroyingLock) {

Review comment:
       `destroyingLock` destroyingLock is redundant, there already have synchronized lock on FrameworkModel instance: 
   ```java
   synchronized void addApplication(ApplicationModel applicationModel) {
   ...
   }
   
   synchronized void tryDestroy() {
   ...
   }
   
   ```




-- 
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: notifications-unsubscribe@dubbo.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org