Package com.alipay.bluewhale.core.cluster

Examples of com.alipay.bluewhale.core.cluster.SolrInfo$ShardCount


    StormClusterState zkCluster = GetShards.getCluster();
    List<Integer> list=zkCluster.higo_ids(tableName);
    Long recordCount=0l;
    for(Integer id:list)
    {
        SolrInfo info=zkCluster.higo_info(tableName, id);
        if(info!=null)
        {
          if(info.stat==ShardsState.SERVICE)
          {
            for(Entry<String, ShardCount> e:info.recorecount.entrySet())
View Full Code Here


      HashMap<String,Long> dayCount = new HashMap<String, Long>();
      HashMap<String,Long> dayAmt = new HashMap<String, Long>();

    for(Integer id:list)
    {
        SolrInfo info=zkCluster.higo_info(tableName, id);
        if(info!=null)
        {
          if(info.stat==ShardsState.SERVICE)
          {
            for(Entry<String, ShardCount> e:info.recorecount.entrySet())
View Full Code Here

        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

    private synchronized void zkHeatbeat() {
    try {
        String hdfsforder = (this.isMergeServer) ? "mergerServer" : IndexUtils.getHdfsForder(taskIndex);
        Integer bindport = this.getBindPort();
        Long hbtime = statcollect.getLastTime();
        SolrInfo info = new SolrInfo(this.params.replication,this.params.replicationindex,this.taskIndex,false,localSolrPath.toString(),
          "solrservice".toString(), hdfsforder, bindport,
          statcollect.getStat(), new HashMap<String, ShardCount>(), new HashMap<String, ShardCount>(), this.statcollect.getSetupTime(),
           hbtime, this.isMergeServer);
        LOG.info("higolog zkHeatbeat " + this.tablename + ",info:"  + info.toShortString());
        Worker.getCluster().higo_heartbeat(this.tablename, this.taskid, info);
    } catch (Exception e) {
        LOG.error(StormUtils.stringify_error(e));
        throw new RuntimeException(e);
    }
View Full Code Here

     
      String tablemode=this.getTableMode();
      boolean isrealtime=this.isrealtime(tablemode);
     
      HashMap<String, ShardCount> daystat=this.partstat.getExtaCount();
      SolrInfo info = new SolrInfo(this.params.replication,this.params.replicationindex,this.taskIndex,isrealtime,localSolrPath.toString(),
          hdfsIndexpath.toString(), hdfsforder, bindport,
          statcollect.getStat(), this.partstat.getPartioncount(),daystat, statcollect.getSetupTime(),
          hbtime, this.isMergeServer);
      LOG.info("higolog zkHeatbeat " + this.tablename + ",info:"
          + info.toShortString());
      Worker.getCluster().higo_heartbeat(this.tablename, this.taskid,
          info);
    } catch (Exception e) {
      LOG.error(StormUtils.stringify_error(e));
      errorCollect.setException(e);
View Full Code Here

TOP

Related Classes of com.alipay.bluewhale.core.cluster.SolrInfo$ShardCount

Copyright © 2018 www.massapicom. 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.