docs: @Override
      public synchronized void closeLog() throws InternalLogException {
          if (tc.isEntryEnabled())
              Tr.entry(tc, "closeLog", new Object[] { _reservedConn, this });
          boolean connAlreadyClosed = false;
  
          if (tc.isDebugEnabled())
              Tr.debug(tc, "Closes required: " + _closesRequired);
  
          if (_closesRequired > 0) {
              try {
                  // The reserved connection should not be null. Attempt to open a connection now and throw an exception if
                  // that fails.
                  if (_reservedConn == null) {
                      if (tc.isDebugEnabled())
                          Tr.debug(tc, "Reserved Connection is NULL, attempt to get new DataSource connection");
                      if (!_serverStopping)
                          _reservedConn = _theDS.getConnection();
                      else {
                          Tr.audit(tc, "WTRN0100E: " +
                                       "Server stopping but no reserved connection when closing SQL RecoveryLog " + _logName + " for server " + _serverName);
                          InternalLogException ile = new InternalLogException("Server stopping, no reserved connection", null);
                          throw ile;
                      }
                  }
  
                  // Test whether the reserved connection is closed already.
                  if (_reservedConn.isClosed()) {
                      if (tc.isDebugEnabled())
                          Tr.debug(tc, "Reserved Connection is already closed");
                      connAlreadyClosed = true;
                  }
              } catch (Throwable exc) {
                  FFDCFilter.processException(exc, "com.ibm.ws.recoverylog.spi.SQLMultiScopeRecoveryLog.closeLog", "550", this);
                  if (tc.isEventEnabled())
                      Tr.event(tc, "Unexpected exception caught in closeLog", exc);
                  markFailed(exc); // @MD19484C
                  _recoverableUnits = null;
  
                  for (StackTraceElement ste : Thread.currentThread().getStackTrace()) {
                      if (tc.isDebugEnabled())
                          Tr.debug(tc, " " + ste);
                  }
  
                  if (tc.isEntryEnabled())
                      Tr.exit(tc, "closeLog", "InternalLogException");
                  throw new InternalLogException(exc);
              }
  
              if (!connAlreadyClosed) {
                  try {
                      internalKeypoint();
                  } catch (LogClosedException exc) {
                      // The log is already closed so absorb the exception.
                      FFDCFilter.processException(exc, "com.ibm.ws.recoverylog.custom.jdbc.impl.SQLMultiScopeRecoveryLog.closeLog", "944", this);
                  } catch (InternalLogException exc) {
                      FFDCFilter.processException(exc, "com.ibm.ws.recoverylog.custom.jdbc.impl.SQLMultiScopeRecoveryLog.closeLog", "948", this);
                      markFailed(exc); // @MD19484C
                      if (tc.isEntryEnabled())
                          Tr.exit(tc, "closeLog", exc);
                      throw exc;
                  } catch (Throwable exc) {
                      FFDCFilter.processException(exc, "com.ibm.ws.recoverylog.custom.jdbc.impl.SQLMultiScopeRecoveryLog.closeLog", "955", this);
                      markFailed(exc); // @MD19484C
  
                      for (StackTraceElement ste : Thread.currentThread().getStackTrace()) {
                          if (tc.isDebugEnabled())
                              Tr.debug(tc, " " + ste);
                      }
  
                      if (tc.isEntryEnabled())
                          Tr.exit(tc, "closeLog", "InternalLogException");
                      throw new InternalLogException(exc);
                  }
  
                  // Decrement the number of close operations required
                  _closesRequired--;
  
                  if (tc.isDebugEnabled())
                      Tr.debug(tc, "Closes required: " + _closesRequired);
                  try {
                      if (_closesRequired <= 0) {
                          // Reset the internal state so that a subsequent open operation does not
                          // occurs with a "clean" environment.
                          _recoverableUnits = null;
                          _closesRequired = 0;
                          _failed = false;
  
                          _reservedConn.rollback();
  
                      }
                      // Close the reserved connection
                      if (tc.isDebugEnabled())
                          Tr.debug(tc, "Close the Reserved Connection");
  
                      _reservedConn.close();
                  } catch (Throwable exc) {
                      FFDCFilter.processException(exc, "com.ibm.ws.recoverylog.spi.SQLMultiScopeRecoveryLog.closeLog", "550", this);
                      if (tc.isEventEnabled())
                          Tr.event(tc, "Unexpected exception caught in closeLog", exc);
                      markFailed(exc); // @MD19484C
                      _recoverableUnits = null;
  
                      for (StackTraceElement ste : Thread.currentThread().getStackTrace()) {
                          if (tc.isDebugEnabled())
                              Tr.debug(tc, " " + ste);
                      }
  
                      if (tc.isEntryEnabled())
                          Tr.exit(tc, "closeLog", "InternalLogException");
                      throw new InternalLogException(exc);
                  }
  
                  // Set the reserved connection to null
                  _reservedConn = null;
              }
          }
  
          if (tc.isDebugEnabled())
              Tr.debug(tc, "Closes required: " + _closesRequired);
  
          if (tc.isEntryEnabled())
              Tr.exit(tc, "closeLog");
      }