From ca4ba32f863aae7f229e7c52d9fe98fbeba0669b Mon Sep 17 00:00:00 2001
From: kenneth_suter <kenneth_suter@localhost>
Date: Fri, 31 Aug 2007 21:28:39 +0000
Subject: [PATCH] Allows the upgrader to detect broken replication following an upgrade and improves the error notification.
---
opendj-sdk/opends/src/quicksetup/org/opends/quicksetup/util/ServerHealthChecker.java | 6 +++---
opendj-sdk/opends/src/server/org/opends/server/replication/plugin/ReplicationBroker.java | 5 +++--
opendj-sdk/opends/src/messages/messages/replication.properties | 4 ++--
3 files changed, 8 insertions(+), 7 deletions(-)
diff --git a/opendj-sdk/opends/src/messages/messages/replication.properties b/opendj-sdk/opends/src/messages/messages/replication.properties
index 24b6c78..da6857b 100644
--- a/opendj-sdk/opends/src/messages/messages/replication.properties
+++ b/opendj-sdk/opends/src/messages/messages/replication.properties
@@ -80,8 +80,8 @@
changes that this server has already processed
NOTICE_NEED_MORE_THAN_ONE_CHANGELOG_SERVER_19=More than one replication \
server should be configured
-NOTICE_EXCEPTION_STARTING_SESSION_20=Caught Exception during initial \
- communication with replication server :
+SEVERE_ERR_EXCEPTION_STARTING_SESSION_20=Caught exception during initial \
+ communication with replication server: %s
MILD_ERR_CANNOT_RECOVER_CHANGES_21=Error when searching old changes from the \
database for base DN %s
NOTICE_COULD_NOT_FIND_CHANGELOG_WITH_MY_CHANGES_22=Could not find a \
diff --git a/opendj-sdk/opends/src/quicksetup/org/opends/quicksetup/util/ServerHealthChecker.java b/opendj-sdk/opends/src/quicksetup/org/opends/quicksetup/util/ServerHealthChecker.java
index 2290b3c..7af1b6a 100644
--- a/opendj-sdk/opends/src/quicksetup/org/opends/quicksetup/util/ServerHealthChecker.java
+++ b/opendj-sdk/opends/src/quicksetup/org/opends/quicksetup/util/ServerHealthChecker.java
@@ -28,12 +28,12 @@
package org.opends.quicksetup.util;
import org.opends.messages.Message;
+import org.opends.messages.Severity;
import org.opends.quicksetup.ReturnCode;
import org.opends.quicksetup.Installation;
import org.opends.quicksetup.ApplicationException;
-import org.opends.server.util.ServerConstants;
import static org.opends.messages.QuickSetupMessages.*;
import java.util.List;
@@ -56,9 +56,9 @@
static private final String UNHEALTHY_SERVER_LOG_REGEX =
new StringBuilder()
.append(".*(")
- .append(ServerConstants.ERROR_SEVERITY_FATAL)
+ .append(Severity.FATAL_ERROR.name())
.append("|")
- .append(ServerConstants.ERROR_SEVERITY_SEVERE_ERROR)
+ .append(Severity.SEVERE_ERROR.name())
.append(")+.*").toString();
diff --git a/opendj-sdk/opends/src/server/org/opends/server/replication/plugin/ReplicationBroker.java b/opendj-sdk/opends/src/server/org/opends/server/replication/plugin/ReplicationBroker.java
index 2869023..ed6270d 100644
--- a/opendj-sdk/opends/src/server/org/opends/server/replication/plugin/ReplicationBroker.java
+++ b/opendj-sdk/opends/src/server/org/opends/server/replication/plugin/ReplicationBroker.java
@@ -371,7 +371,8 @@
}
catch (Exception e)
{
- Message message = NOTE_EXCEPTION_STARTING_SESSION.get();
+ Message message =
+ ERR_EXCEPTION_STARTING_SESSION.get(e.getMessage());
logError(message);
}
finally
@@ -497,7 +498,7 @@
} catch (Exception e)
{
MessageBuilder mb = new MessageBuilder();
- mb.append(NOTE_EXCEPTION_STARTING_SESSION.get());
+ mb.append(ERR_EXCEPTION_STARTING_SESSION.get(e.getMessage()));
mb.append(stackTraceToSingleLineString(e));
logError(mb.toMessage());
}
--
Gitblit v1.10.0