public int compare(Server s1, Server s2) {
          int l;
          l = s1.getHostname().compareTo(s2.getHostname());
          if (l != 0) return l;

          l = ((Integer) s1.getPort()).compareTo(s2.getPort());
          return l;
        }
 public void promoteServerInGroup(String groupName, String hostname, int port)
     throws FabricCommunicationException {
   ServerGroup serverGroup = getServerGroup(groupName);
   for (Server s : serverGroup.getServers()) {
     if (s.getHostname().equals(hostname) && s.getPort() == port) {
       errorSafeCallMethod(METHOD_GROUP_PROMOTE, new Object[] {groupName, s.getUuid()});
       break;
     }
   }
 }