Close messaging service before storage

Fixes https://www.spigotmc.org/threads/174259/page-129#post-3302827
This commit is contained in:
Luck 2019-02-07 12:38:24 +00:00
parent 85d2f0b51f
commit 215031a1f3
No known key found for this signature in database
GPG Key ID: EFA9B3EC5FD90F8B

View File

@ -195,6 +195,12 @@ public abstract class AbstractLuckPermsPlugin implements LuckPermsPlugin {
// remove any hooks into the platform // remove any hooks into the platform
removePlatformHooks(); removePlatformHooks();
// close messaging service
if (this.messagingService != null) {
getLogger().info("Closing messaging service...");
this.messagingService.close();
}
// close storage // close storage
getLogger().info("Closing storage..."); getLogger().info("Closing storage...");
this.storage.shutdown(); this.storage.shutdown();
@ -204,12 +210,6 @@ public abstract class AbstractLuckPermsPlugin implements LuckPermsPlugin {
this.fileWatcher.close(); this.fileWatcher.close();
} }
// close messaging service
if (this.messagingService != null) {
getLogger().info("Closing messaging service...");
this.messagingService.close();
}
// unregister api // unregister api
ApiRegistrationUtil.unregisterProvider(); ApiRegistrationUtil.unregisterProvider();