Examples of RunnableCallback


Examples of com.alibaba.jstorm.callback.RunnableCallback

   * @return
   */
  public static RollingWindowSet keyed_counter_rolling_window_set(
      int num_buckets, Integer[] bucket_sizes) {

    RunnableCallback updater = new IncValUpdater();
    RunnableCallback merger = new IncValMerger();

    RunnableCallback extractor = new IncValExtractor();
    return RollingWindowSet.rolling_window_set(updater, merger, extractor,
        num_buckets, bucket_sizes);
  }
View Full Code Here

Examples of com.alibaba.jstorm.callback.RunnableCallback

   * @param bucket_sizes
   * @return
   */
  public static RollingWindowSet keyed_avg_rolling_window_set(
      int num_buckets, Integer[] bucket_sizes) {
    RunnableCallback updater = new KeyAvgUpdater();

    RunnableCallback merger = new KeyAvgMerge();

    RunnableCallback extractor = new KeyAvgExtractor();

    return RollingWindowSet.rolling_window_set(updater, merger, extractor,
        num_buckets, bucket_sizes);
  }
View Full Code Here

Examples of com.alipay.bluewhale.core.callback.RunnableCallback

    TaskSendTargets sendTargets = makeSendTargets();
    UnanchoredSend.send(topologyContext, sendTargets, workerTransfer,
        Common.SYSTEM_STREAM_ID, msg);

    // �����̣߳���zeroMq�ж�ȡtuple,����spout��bolt���д���Ȼ���͸�worker
    RunnableCallback componsementExecutor = mkExecutor(puller, sendTargets);
    AsyncLoopThread executor_threads = new AsyncLoopThread(
        componsementExecutor);
    AsyncLoopThread[] all_threads = { executor_threads, heartbeat_thread };

    LOG.info("Finished loading task " + componentid + ":" + taskid);
View Full Code Here

Examples of com.alipay.bluewhale.core.callback.RunnableCallback

   * @param bucket_sizes
   * @return
   */
  public static RollingWindowSet keyed_counter_rolling_window_set(
      int num_buckets, Integer[] bucket_sizes) {
    RunnableCallback updater = new IncValUpdater();
    RunnableCallback merger = new IncValMerger();

    RunnableCallback extractor = new IncValExtractor();
    return RollingWindowSetStat.rolling_window_set(updater, merger,
        extractor, num_buckets, bucket_sizes);
  }
View Full Code Here

Examples of com.alipay.bluewhale.core.callback.RunnableCallback

   * @param bucket_sizes
   * @return
   */
  public static RollingWindowSet keyed_avg_rolling_window_set(
      int num_buckets, Integer[] bucket_sizes) {
    RunnableCallback updater = new KeyAvgUpdater();

    RunnableCallback merger = new KeyAvgMerge();

    RunnableCallback extractor = new KeyAvgExtractor();

    return RollingWindowSetStat.rolling_window_set(updater, merger,
        extractor, num_buckets, bucket_sizes);
  }
View Full Code Here

Examples of com.alipay.bluewhale.core.callback.RunnableCallback

      boolean isScratch) throws IOException {
      LOG.debug("Determining assignment for " + topologyid);
      Map<?, ?> conf = data.getConf();
      StormClusterState stormClusterState = data.getStormClusterState();
      //����zk callback�¼�
      RunnableCallback callback =new TransitionZkCallback(data, topologyid);
      //��ȡ���е�supervisor�ڵ���Ϣ��
      Map<String, SupervisorInfo> supInfos = allSupervisorInfo(stormClusterState, callback);
      //��ȡ<supervisorid,hostname>map���ϣ����磺node->host {"4b83cd41-e863-4bd6-b26d-3e27e5ff7799" "dw-perf-3.alipay.net","b8f1664d-5555-4950-8139-5098fb109a81" "dw-perf-2.alipay.net"}
      Map<String, String> nodeHost = getNodeHost(supInfos);
      //��ȡָ��topologyid��assignment��Ϣ��
View Full Code Here

Examples of com.alipay.bluewhale.core.callback.RunnableCallback

        }
      }
    }
    Map<Integer, Socket> virtual_mapping = new HashMap<Integer, ZMQ.Socket>();

    RunnableCallback loop_fn = new VirtualPortDispatch(context, socket,
        virtual_mapping, url, valid_ports);

    AsyncLoopThread vthread = new AsyncLoopThread(loop_fn, daemon, kill_fn,
        priority, true);
View Full Code Here

Examples of com.alipay.bluewhale.core.callback.RunnableCallback

    RefreshActive refreshZkActive = new RefreshActive(active, conf,
        zkCluster, topologyId, zkActive);
    refreshZkActive.run();

    // ���������߳�
    RunnableCallback heartbeat_fn = new WorkerHeartbeatRunable(conf,
        workerId, port, topologyId, new CopyOnWriteArraySet<Integer>(taskids),
        active);
    heartbeat_fn.run();

    // ����worker����tuple�Ļ�����
    LinkedBlockingQueue<TransferData> transferQueue = new LinkedBlockingQueue<TransferData>();

   
View Full Code Here

Examples of com.alipay.bluewhale.core.callback.RunnableCallback

        this.init(afn, daemon, kill_fn, priority, start);
    }

    public void init(RunnableCallback afn, boolean daemon, int priority,
            boolean start) {
        RunnableCallback kill_fn = new AsyncLoopDefaultKill();
        this.init(afn, daemon, kill_fn, priority, start);
    }
View Full Code Here

Examples of com.alipay.bluewhale.core.callback.RunnableCallback

   * @param sets
   * @return
   */
  public static List<String> getRepeat(List<String> sets) {

    RunnableCallback fn = new RunnableCallback() {
      @Override
      public <T> Object execute(T... args) {
        int num = (Integer) args[0];
        boolean isFilter = false;
        if (num > 1) {
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.