[#2434] Correctly shutdown bossExecutor in OioServerSocketChannelFactory
Motivation: At the moment the bossExecutor is not shutdown correctly. So the threads may never exit. Modifications: Correctly shutdown bossExecutor. Result: Threads are correctly stopped.
This commit is contained in:
parent
07266cbd0b
commit
eb4090b904
@ -145,11 +145,13 @@ public class OioServerSocketChannelFactory implements ServerSocketChannelFactory
|
||||
|
||||
public void shutdown() {
|
||||
if (shutdownExecutor) {
|
||||
ExecutorUtil.shutdownNow(bossExecutor);
|
||||
ExecutorUtil.shutdownNow(workerExecutor);
|
||||
}
|
||||
}
|
||||
|
||||
public void releaseExternalResources() {
|
||||
ExecutorUtil.shutdownNow(bossExecutor);
|
||||
ExecutorUtil.shutdownNow(workerExecutor);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user