Damans227 commented on code in PR #13552:
URL: https://github.com/apache/cloudstack/pull/13552#discussion_r3590463164
##########
engine/orchestration/src/main/java/com/cloud/agent/manager/AgentManagerImpl.java:
##########
@@ -423,7 +427,7 @@ public void onManagementServerCancelMaintenance() {
}
private void initConnectExecutor() {
- _connectExecutor = new ThreadPoolExecutor(100, 500, 60L,
TimeUnit.SECONDS, new LinkedBlockingQueue<>(), new
NamedThreadFactory("AgentConnectTaskPool"));
+ _connectExecutor = new
ThreadPoolExecutor(AgentConnectExecutorCorePoolSize.value(),
AgentConnectExecutorMaxPoolSize.value(), 60L, TimeUnit.SECONDS, new
LinkedBlockingQueue<>(), new NamedThreadFactory("AgentConnectTaskPool"));
Review Comment:
Thanks @nvazquez, looks good. One question: should the max check be
`agentConnectMaxSize <= 0`? `ThreadPoolExecutor` requires max to be strictly
positive, so setting both keys to 0 passes validation but still throws at
startup.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]