test_class.file: storm/storm-benchmark/src/test/java/storm/benchmark/benchmarks/UniqueVisitorTest.java
test_class.identifier: UniqueVisitorTest
test_case.body: @Test
    public void componentParallelismCouldBeSetThroughConfig() {
      StormBenchmark benchmark = new UniqueVisitor();
      Config config = new Config();
      config.put(UniqueVisitor.SPOUT_NUM, 3);
      config.put(UniqueVisitor.VIEW_NUM, 4);
      config.put(UniqueVisitor.UNIQUER_NUM, 5);
      StormTopology topology = benchmark.getTopology(config);
      assertThat(topology).isNotNull();
      TestUtils.verifyParallelism(Utils.getComponentCommon(topology, UniqueVisitor.SPOUT_ID), 3);
      TestUtils.verifyParallelism(Utils.getComponentCommon(topology, UniqueVisitor.VIEW_ID), 4);
      TestUtils.verifyParallelism(Utils.getComponentCommon(topology, UniqueVisitor.UNIQUER_ID), 5);
    }
test_case.class_method_signature: UniqueVisitorTest.componentParallelismCouldBeSetThroughConfig()
test_case.full_signature: @Test public void componentParallelismCouldBeSetThroughConfig()
test_case.identifier: componentParallelismCouldBeSetThroughConfig
test_case.invocations: put put put getTopology isNotNull assertThat verifyParallelism getComponentCommon verifyParallelism getComponentCommon verifyParallelism getComponentCommon
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void componentParallelismCouldBeSetThroughConfig()
focal_class.declarator: SPOUT_ID = "spout"
focal_class.modifier: public final static
focal_class.original_string: public final static String SPOUT_ID = "spout";
focal_class.type: String
focal_class.var_name: SPOUT_ID
focal_class.declarator: SPOUT_NUM = "component.spout_num"
focal_class.modifier: public final static
focal_class.original_string: public final static String SPOUT_NUM = "component.spout_num";
focal_class.type: String
focal_class.var_name: SPOUT_NUM
focal_class.declarator: VIEW_ID = "view"
focal_class.modifier: public final static
focal_class.original_string: public final static String VIEW_ID = "view";
focal_class.type: String
focal_class.var_name: VIEW_ID
focal_class.declarator: VIEW_NUM = "component.view_bolt_num"
focal_class.modifier: public final static
focal_class.original_string: public final static String VIEW_NUM = "component.view_bolt_num";
focal_class.type: String
focal_class.var_name: VIEW_NUM
focal_class.declarator: UNIQUER_ID = "uniquer"
focal_class.modifier: public final static
focal_class.original_string: public final static String UNIQUER_ID = "uniquer";
focal_class.type: String
focal_class.var_name: UNIQUER_ID
focal_class.declarator: UNIQUER_NUM = "component.uniquer_bolt_num"
focal_class.modifier: public final static
focal_class.original_string: public final static String UNIQUER_NUM = "component.uniquer_bolt_num";
focal_class.type: String
focal_class.var_name: UNIQUER_NUM
focal_class.declarator: WINDOW_LENGTH = "window.length"
focal_class.modifier: public final static
focal_class.original_string: public final static String WINDOW_LENGTH = "window.length";
focal_class.type: String
focal_class.var_name: WINDOW_LENGTH
focal_class.declarator: EMIT_FREQ = "emit.frequency"
focal_class.modifier: public final static
focal_class.original_string: public final static String EMIT_FREQ = "emit.frequency";
focal_class.type: String
focal_class.var_name: EMIT_FREQ
focal_class.declarator: DEFAULT_SPOUT_NUM = 4
focal_class.modifier: public static final
focal_class.original_string: public static final int DEFAULT_SPOUT_NUM = 4;
focal_class.type: int
focal_class.var_name: DEFAULT_SPOUT_NUM
focal_class.declarator: DEFAULT_PV_BOLT_NUM = 4
focal_class.modifier: public static final
focal_class.original_string: public static final int DEFAULT_PV_BOLT_NUM = 4;
focal_class.type: int
focal_class.var_name: DEFAULT_PV_BOLT_NUM
focal_class.declarator: DEFAULT_UV_BOLT_NUM = 4
focal_class.modifier: public static final
focal_class.original_string: public static final int DEFAULT_UV_BOLT_NUM = 4;
focal_class.type: int
focal_class.var_name: DEFAULT_UV_BOLT_NUM
focal_class.declarator: DEFAULT_WINDOW_LENGTH_IN_SEC = 9
focal_class.modifier: public static final
focal_class.original_string: public static final int DEFAULT_WINDOW_LENGTH_IN_SEC = 9;
focal_class.type: int
focal_class.var_name: DEFAULT_WINDOW_LENGTH_IN_SEC
focal_class.declarator: DEFAULT_EMIT_FREQ_IN_SEC = 3
focal_class.modifier: public static final
focal_class.original_string: public static final int DEFAULT_EMIT_FREQ_IN_SEC = 3;
focal_class.type: int
focal_class.var_name: DEFAULT_EMIT_FREQ_IN_SEC
focal_class.declarator: spout
focal_class.modifier: protected
focal_class.original_string: protected IRichSpout spout;
focal_class.type: IRichSpout
focal_class.var_name: spout
focal_class.file: storm/storm-benchmark/src/main/java/storm/benchmark/benchmarks/UniqueVisitor.java
focal_class.identifier: UniqueVisitor
focal_class.class_method_signature: UniqueVisitor.getTopology(Config config)
focal_class.full_signature: @Override public StormTopology getTopology(Config config)
focal_class.identifier: getTopology
focal_class.modifiers: @Override public
focal_class.parameters: (Config config)
focal_class.return: StormTopology
focal_class.signature: StormTopology getTopology(Config config)
focal_class.superclass: extends StormBenchmark
focal_method.body: @Override
    public StormTopology getTopology(Config config) {
  
      final int spoutNum = BenchmarkUtils.getInt(config, SPOUT_NUM, DEFAULT_SPOUT_NUM);
      final int pvBoltNum = BenchmarkUtils.getInt(config, VIEW_NUM, DEFAULT_PV_BOLT_NUM);
      final int uvBoltNum = BenchmarkUtils.getInt(config, UNIQUER_NUM, DEFAULT_UV_BOLT_NUM);
      final int winLen = BenchmarkUtils.getInt(config, WINDOW_LENGTH, DEFAULT_WINDOW_LENGTH_IN_SEC);
      final int emitFreq = BenchmarkUtils.getInt(config, EMIT_FREQ, DEFAULT_EMIT_FREQ_IN_SEC);
      spout = new KafkaSpout(KafkaUtils.getSpoutConfig(
              config, new SchemeAsMultiScheme(new StringScheme())));
  
      TopologyBuilder builder = new TopologyBuilder();
      builder.setSpout(SPOUT_ID, spout, spoutNum);
      builder.setBolt(VIEW_ID, new PageViewBolt(Item.URL, Item.USER), pvBoltNum)
              .localOrShuffleGrouping(SPOUT_ID);
      builder.setBolt(UNIQUER_ID, new UniqueVisitorBolt(winLen, emitFreq), uvBoltNum)
              .fieldsGrouping(VIEW_ID, new Fields(Item.URL.toString()));
      return builder.createTopology();
    }
focal_method.class_method_signature: UniqueVisitor.getTopology(Config config)
focal_method.full_signature: @Override public StormTopology getTopology(Config config)
focal_method.identifier: getTopology
focal_method.invocations: getInt getInt getInt getInt getInt getSpoutConfig setSpout localOrShuffleGrouping setBolt fieldsGrouping setBolt toString createTopology
focal_method.modifiers: @Override public
focal_method.parameters: (Config config)
focal_method.return: StormTopology
focal_method.signature: StormTopology getTopology(Config config)