Fire ProxyShutdownEvent before closing the scheduler / event bus

Fixes #322
This commit is contained in:
Luck
2020-06-29 15:48:28 +01:00
parent d24573871d
commit 04ab6ed162

View File

@@ -409,6 +409,8 @@ public class VelocityServer implements ProxyServer {
timedOut = true;
}
eventManager.fireShutdownEvent();
timedOut = !eventManager.shutdown() || timedOut;
timedOut = !scheduler.shutdown() || timedOut;
@@ -420,8 +422,6 @@ public class VelocityServer implements ProxyServer {
Thread.currentThread().interrupt();
}
eventManager.fireShutdownEvent();
shutdown = true;
if (explicitExit) {