Examples of MkGrouper


Examples of com.alibaba.jstorm.task.group.MkGrouper

      return out_tasks;
    }

    for (Entry<String, MkGrouper> ee : componentCrouping.entrySet()) {
      String targetComponent = ee.getKey();
      MkGrouper g = ee.getValue();

      if (GrouperType.direct.equals(g.gettype())) {
        throw new IllegalArgumentException(
            "Cannot do regular emit to direct stream");
      }

      out_tasks.addAll(g.grouper(tuple));

    }

    if (isDebuging) {
View Full Code Here

Examples of com.alibaba.jstorm.task.group.MkGrouper

        List<Integer> outTasks = topology_context
            .getComponentTasks(component);
        // ATTENTION: If topology set one component parallelism as 0
        // so we don't need send tuple to it
        if (outTasks.size() > 0) {
          MkGrouper grouper = new MkGrouper(topology_context,
              out_fields, tgrouping, outTasks, stream_id,
              workerData);
          componentGrouper.put(component, grouper);
        }
      }
View Full Code Here

Examples of com.alipay.bluewhale.core.task.group.MkGrouper

        String component = cg.getKey();
        Grouping tgrouping = cg.getValue();
        int num_tasks = topology_context.getComponentTasks(component)
            .size();
        if (num_tasks > 0) {
          MkGrouper grouper = new MkGrouper(out_fields, tgrouping,
              num_tasks);
          componentGrouper.put(component, grouper);
        }
      }
      if (componentGrouper.size() > 0) {
View Full Code Here

Examples of com.alipay.bluewhale.core.task.group.MkGrouper

      LOG.info("Emitting direct: " + out_task_id + "; "    + taskReadableName + " " + stream );
  }

  String target_component = topologyContext.getComponentId(out_task_id);
  Map<String, MkGrouper> component_prouping = streamComponentgrouper.get(stream);
  MkGrouper grouping = component_prouping.get(target_component);
  if (grouping != null && !GrouperType.direct.equals(grouping.gettype())) {
      throw new IllegalArgumentException("Cannot emitDirect to a task expecting a regular grouping");
  }

  // ����ͳ��
  if (emitSampler.getResult()) {
View Full Code Here

Examples of com.alipay.bluewhale.core.task.group.MkGrouper

  java.util.Set<Integer> out_tasks = new HashSet<Integer>();

  if(componentCrouping!=null)
  {
          for (Entry<String, MkGrouper> ee : componentCrouping.entrySet()) {
              MkGrouper g = ee.getValue();
              if (GrouperType.direct.equals(g.gettype())) {
            throw new IllegalArgumentException("Cannot do regular emit to direct stream");
              }
       
              List<Integer> tasks = componentTasks.get(ee.getKey());
              List<Integer> indices = g.grouper(tuple);
              for (Integer i : indices) {
            Integer outtask=tasks.get(i);
            if(outtask!=null)
            {
                out_tasks.add(outtask);
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.