From 40483c36210b8a0682a9dd400f0419d11b76483e Mon Sep 17 00:00:00 2001
From: gbellato <gbellato@localhost>
Date: Tue, 10 Mar 2009 08:56:32 +0000
Subject: [PATCH] fix for 3804 : improve replication monitoring

---
 opendj-sdk/opends/src/server/org/opends/server/replication/server/ServerHandler.java |   17 +++++++++--------
 1 files changed, 9 insertions(+), 8 deletions(-)

diff --git a/opendj-sdk/opends/src/server/org/opends/server/replication/server/ServerHandler.java b/opendj-sdk/opends/src/server/org/opends/server/replication/server/ServerHandler.java
index 32f48b3..a6d898c 100644
--- a/opendj-sdk/opends/src/server/org/opends/server/replication/server/ServerHandler.java
+++ b/opendj-sdk/opends/src/server/org/opends/server/replication/server/ServerHandler.java
@@ -1968,13 +1968,14 @@
   @Override
   public String getMonitorInstanceName()
   {
-    String str = baseDn.toString() +
-      " " + serverURL + " " + String.valueOf(serverId);
+    String str = serverURL + " " + String.valueOf(serverId);
 
     if (serverIsLDAPserver)
-      return "Directory Server " + str;
+      return "Connected Replica " + str +
+                ",cn=" + replicationServerDomain.getMonitorInstanceName();
     else
-      return "Remote Replication Server " + str;
+      return "Connected Replication Server " + str +
+                ",cn=" + replicationServerDomain.getMonitorInstanceName();
   }
 
   /**
@@ -2020,7 +2021,7 @@
     ArrayList<Attribute> attributes = new ArrayList<Attribute>();
     if (serverIsLDAPserver)
     {
-      attributes.add(Attributes.create("LDAP-Server", serverURL));
+      attributes.add(Attributes.create("replica", serverURL));
       attributes.add(Attributes.create("connected-to",
           this.replicationServerDomain.getReplicationServer()
               .getMonitorInstanceName()));
@@ -2028,17 +2029,17 @@
     }
     else
     {
-      attributes.add(Attributes.create("ReplicationServer-Server",
+      attributes.add(Attributes.create("Replication-Server",
           serverURL));
     }
     attributes.add(Attributes.create("server-id", String
         .valueOf(serverId)));
-    attributes.add(Attributes.create("base-dn", baseDn.toString()));
+    attributes.add(Attributes.create("domain-name", baseDn.toString()));
 
     try
     {
       MonitorData md;
-      md = replicationServerDomain.getMonitorData();
+      md = replicationServerDomain.computeMonitorData();
 
       if (serverIsLDAPserver)
       {

--
Gitblit v1.10.0