diff options
author | Bernard Normier <bernard@zeroc.com> | 2006-07-07 17:20:13 +0000 |
---|---|---|
committer | Bernard Normier <bernard@zeroc.com> | 2006-07-07 17:20:13 +0000 |
commit | 6539e6164f2fd7fcef7c0541aa35f8b60ceb95a4 (patch) | |
tree | cfe15a24d0d8f0b213b2508ad19c397ec3b6713a /java/src/IceGridGUI/LiveDeployment/Root.java | |
parent | adding note for VB2005 Express (diff) | |
download | ice-6539e6164f2fd7fcef7c0541aa35f8b60ceb95a4.tar.bz2 ice-6539e6164f2fd7fcef7c0541aa35f8b60ceb95a4.tar.xz ice-6539e6164f2fd7fcef7c0541aa35f8b60ceb95a4.zip |
Fixed bug #1192
Diffstat (limited to 'java/src/IceGridGUI/LiveDeployment/Root.java')
-rwxr-xr-x | java/src/IceGridGUI/LiveDeployment/Root.java | 28 |
1 files changed, 26 insertions, 2 deletions
diff --git a/java/src/IceGridGUI/LiveDeployment/Root.java b/java/src/IceGridGUI/LiveDeployment/Root.java index 4b91225f8d8..005cd2857e5 100755 --- a/java/src/IceGridGUI/LiveDeployment/Root.java +++ b/java/src/IceGridGUI/LiveDeployment/Root.java @@ -293,11 +293,35 @@ public class Root extends ListTreeNode if(rgd.id.equals(update.removeReplicaGroups[i]))
{
appDesc.replicaGroups.remove(j);
+ break; // for
}
}
}
- appDesc.replicaGroups.addAll(update.replicaGroups);
-
+
+ for(int i = 0; i < update.replicaGroups.size(); ++i)
+ {
+ ReplicaGroupDescriptor newRgd = (ReplicaGroupDescriptor)update.replicaGroups.get(i);
+
+ boolean replaced = false;
+ int j = 0;
+ while(j < appDesc.replicaGroups.size() && !replaced)
+ {
+ ReplicaGroupDescriptor oldRgd = (ReplicaGroupDescriptor)appDesc.replicaGroups.get(j);
+
+ if(newRgd.id.equals(oldRgd.id))
+ {
+ appDesc.replicaGroups.set(j, newRgd);
+ replaced = true;
+ }
+ j++;
+ }
+
+ if(!replaced)
+ {
+ appDesc.replicaGroups.add(newRgd);
+ }
+ }
+
appDesc.serviceTemplates.keySet().
removeAll(java.util.Arrays.asList(update.removeServiceTemplates));
appDesc.serviceTemplates.putAll(update.serviceTemplates);
|