Skip to content

Commit

Permalink
fix: avoid double stop execution of server
Browse files Browse the repository at this point in the history
  • Loading branch information
tglman committed Jan 19, 2024
1 parent ad20dfa commit e89023d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -519,14 +519,15 @@ public void hazelcastPluginShutdown() {
}
}

if (hazelcastInstance != null)
if (hazelcastInstance != null) {
try {
hazelcastInstance.shutdown();
} catch (Exception e) {
OLogManager.instance().error(this, "Error on shutting down Hazelcast instance", e);
} finally {
hazelcastInstance = null;
}
}

OCallableUtils.executeIgnoringAnyExceptions(
new OCallableNoParamNoReturn() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -562,6 +562,7 @@ public boolean shutdown() {

protected boolean deinit() {
try {
if (!running) return false;
running = false;

OLogManager.instance().info(this, "OrientDB Server is shutting down...");
Expand Down

0 comments on commit e89023d

Please sign in to comment.