Fix for Issue #4546 : Exception during Replication causes Deadlock When some failure happen in the dbHandler cleaner trimming thread the db shutdown can be called from this thread and should therefore not wait for the trimming thread to complete. This is fixed by setting the done flag before calling the shutdown.
| | |
| | | mb.append(ERR_EXCEPTION_CHANGELOG_TRIM_FLUSH.get()); |
| | | mb.append(stackTraceToSingleLineString(end)); |
| | | logError(mb.toMessage()); |
| | | synchronized (this) |
| | | { |
| | | // set the done variable to true so that this thread don't |
| | | // get stuck in this dbHandler.shutdown() when it get called |
| | | // by replicationServer.shutdown(); |
| | | done = true; |
| | | } |
| | | if (replicationServer != null) |
| | | replicationServer.shutdown(); |
| | | break; |