Dubbo: [Discussion] There are so much threadpool, can we merge some threadpool into one threadpool ?

Created on 8 Mar 2019  路  2Comments  路  Source: apache/dubbo

There are so much threadpool that manage only one thread , and this thread is idle. The threadpool as follow:

  • org.apache.dubbo.metadata.support.AbstractMetadataReport#reportCacheExecutor for asyn write metadata.
  • The HashedWheelTimer is used in Registry retry task.
  • Configcenter listen the config changed, and the callback will excuted by a dependency Executor.
  • ....

There are so much situation that we will use threadpool. I think can we merge this threadpool to make the threadpool is used by much more situation.

Also we should move some timer task to HashedWheelTimer?

typquestion & discussion

Most helpful comment

By the way, I will bring this topic to mailing list.
A very worthwhile issue.

All 2 comments

good suggestion.
But what I need to remind is

  1. hashedwheeltimer only have one thread executes the task.
  2. If the previous task takes a long time to execute, it will affect the execution of subsequent tasks.

I suggest that we can first consider the transformation of the hashedWheelTimer, such as using the thread pool internally to perform tasks.

By the way, I will bring this topic to mailing list.
A very worthwhile issue.

Was this page helpful?
0 / 5 - 0 ratings