Examples of StormClusterState


Examples of com.alipay.bluewhale.core.cluster.StormClusterState

     * 3.2 register watcher of zk
     * 3.3 register all kinds of callbacks
     * 3.4 create znode
     */
    //�ɲ���zookeeper��ʵ��
    StormClusterState stormClusterState = Cluster
        .mk_storm_cluster_state(conf);

    /*
     * Step 4, create LocalStat LocalStat is one KV database
     * 4.1 create LocalState instance
View Full Code Here

Examples of com.alipay.bluewhale.core.cluster.StormClusterState

      ArrayList<SolrInfo> newlist=new ArrayList<SolrInfo>();

      try {
        long t1=System.currentTimeMillis();
        LOG.info("sync from zookeeper "+tableName);
        StormClusterState zkCluster = getCluster();
        List<Integer> list = zkCluster.higo_base(tableName,this);
        for (Integer id : list) {
          SolrInfo info = zkCluster.higo_info(tableName, id);
          if (info != null )
          {
            newlist.add(info);
          }
        }
View Full Code Here

Examples of com.alipay.bluewhale.core.cluster.StormClusterState

  private static void runTable(String[] args) throws Exception {
    String tableName = args[1];
    Map stormconf = Utils.readStormConfig();
    ClusterState zkClusterstate = Cluster
        .mk_distributed_cluster_state(stormconf);
    StormClusterState zkCluster = Cluster
        .mk_storm_cluster_state(zkClusterstate);
    zkCluster.higo_remove(tableName);
    zkCluster.disconnect();

    Integer shards = StormUtils
        .parseInt(stormconf.get("higo.shards.count"));
   
    Integer replication = StormUtils.parseInt(stormconf.containsKey("higo.shards.replication")?stormconf.get("higo.shards.replication"):1);
View Full Code Here

Examples of com.alipay.bluewhale.core.cluster.StormClusterState

    }

    Map stormconf = Utils.readStormConfig();
    ClusterState zkClusterstate = Cluster
        .mk_distributed_cluster_state(stormconf);
    StormClusterState zkCluster = Cluster
        .mk_storm_cluster_state(zkClusterstate);
    zkCluster.higo_remove(topologyName);
    for (String s : tableName.split(",")) {
      zkCluster.higo_remove(s);
    }
    zkCluster.disconnect();
    System.exit(0);
  }
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.