Examples of MonitorDbo


Examples of org.playorm.monitor.impl.db.MonitorDbo

  private void runOurMonitors(NoSqlEntityManager mgr, int numUpWebNodes, int serverNumber) {
    log.info("num up nodes="+numUpWebNodes+" servernum="+serverNumber);
    Cursor<KeyValue<MonitorDbo>> cursor = MonitorDbo.findAll(mgr);
    while(cursor.next()) {
      KeyValue<MonitorDbo> kv = cursor.getCurrent();
      MonitorDbo val = kv.getValue();
      String id = val.getId();
      int hash = id.hashCode();
      int serverNum = hashGen.generate(hash, numUpWebNodes);
      log.info("monitor="+val.getId()+" target server num="+serverNum+" our servernum="+serverNumber);
      if(serverNum == serverNumber)
        processMonitor(mgr, val);
    }
  }
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.