Examples of ServerDescriptor


Examples of org.vitaliyl.monitoring.server.beans.ServerDescriptor

    List<Entity> entities = preparedQuery.asList(Datastore.DEFAULT_FETCH_OPTIONS);
 
    List<ServerDescriptor> list = new ArrayList<ServerDescriptor>();
 
    Entity entity = null;
    ServerDescriptor sd;
    if (!entities.isEmpty()) {
      for (int i = 0; i < entities.size(); i++) {
        entity = entities.get(i);
 
        String serverUrl = (String) entity.getProperty(Datastore.SERVER_SERVER_URL);
        int maxConnections = ((Long) entity.getProperty(Datastore.SERVER_MAX_CONNECTIONS)).intValue();
 
        sd = new ServerDescriptor(serverUrl, maxConnections);
        sd.setId(KeyFactory.keyToString(entity.getKey()));
        list.add(sd);
      }
    }
 
    return list;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.