| | |
| | | import static org.opends.server.messages.MessageHandler.getMessage; |
| | | import static org.opends.server.util.ServerConstants.DATE_FORMAT_GMT_TIME; |
| | | import static org.opends.server.loggers.Error.logError; |
| | | import static org.opends.server.util.StaticUtils.stackTraceToSingleLineString; |
| | | import static org.opends.server.util.StaticUtils.*; |
| | | import static org.opends.server.util.ServerConstants. |
| | | BACKUP_DIRECTORY_DESCRIPTOR_FILE; |
| | | |
| | |
| | | import org.opends.server.backends.task.TaskState; |
| | | import org.opends.server.core.DirectoryServer; |
| | | import org.opends.server.core.LockFileManager; |
| | | import org.opends.server.core.Operation; |
| | | import org.opends.server.api.Backend; |
| | | import org.opends.server.api.ClientConnection; |
| | | import org.opends.server.config.ConfigEntry; |
| | |
| | | import org.opends.server.types.Entry; |
| | | import org.opends.server.types.ErrorLogCategory; |
| | | import org.opends.server.types.ErrorLogSeverity; |
| | | import org.opends.server.types.Operation; |
| | | import org.opends.server.types.Privilege; |
| | | import org.opends.server.types.ResultCode; |
| | | |
| | |
| | | { |
| | | int msgID = MSGID_BACKUPDB_CANNOT_CREATE_BACKUP_DIR; |
| | | String message = getMessage(msgID, backupDirectory.getPath(), |
| | | stackTraceToSingleLineString(e)); |
| | | getExceptionMessage(e)); |
| | | System.err.println(message); |
| | | return false; |
| | | } |
| | |
| | | { |
| | | int msgID = MSGID_BACKUPDB_CANNOT_PARSE_BACKUP_DESCRIPTOR; |
| | | String message = getMessage(msgID, descriptorPath, |
| | | stackTraceToSingleLineString(e)); |
| | | getExceptionMessage(e)); |
| | | logError(ErrorLogCategory.BACKEND, ErrorLogSeverity.SEVERE_ERROR, |
| | | message, msgID); |
| | | return false; |
| | |
| | | { |
| | | int msgID = MSGID_BACKUPDB_CANNOT_CREATE_BACKUP_DIR; |
| | | String message = getMessage(msgID, backupLocation.getPath(), |
| | | stackTraceToSingleLineString(e)); |
| | | getExceptionMessage(e)); |
| | | logError(ErrorLogCategory.BACKEND, ErrorLogSeverity.SEVERE_ERROR, |
| | | message, msgID); |
| | | return false; |
| | |
| | | DirectoryServer.notifyBackupEnded(b, backupConfig, false); |
| | | int msgID = MSGID_BACKUPDB_ERROR_DURING_BACKUP; |
| | | String message = getMessage(msgID, b.getBackendID(), |
| | | stackTraceToSingleLineString(e)); |
| | | getExceptionMessage(e)); |
| | | logError(ErrorLogCategory.BACKEND, ErrorLogSeverity.SEVERE_ERROR, |
| | | message, msgID); |
| | | return false; |
| | |
| | | { |
| | | int msgID = MSGID_BACKUPDB_CANNOT_LOCK_BACKEND; |
| | | String message = getMessage(msgID, b.getBackendID(), |
| | | stackTraceToSingleLineString(e)); |
| | | getExceptionMessage(e)); |
| | | logError(ErrorLogCategory.BACKEND, ErrorLogSeverity.SEVERE_ERROR, |
| | | message, msgID); |
| | | return false; |
| | |
| | | { |
| | | int msgID = MSGID_BACKUPDB_CANNOT_UNLOCK_BACKEND; |
| | | String message = getMessage(msgID, b.getBackendID(), |
| | | stackTraceToSingleLineString(e)); |
| | | getExceptionMessage(e)); |
| | | logError(ErrorLogCategory.BACKEND, |
| | | ErrorLogSeverity.SEVERE_WARNING, message, msgID); |
| | | return false; |