@Override protected void prepareConfiguration(GiraphConfiguration conf, CommandLine cmd) { conf.setComputationClass(ReducersBenchmarkComputation.class); conf.setMasterComputeClass(ReducersBenchmarkMasterCompute.class); conf.setVertexInputFormatClass(PseudoRandomVertexInputFormat.class); conf.setWorkerContextClass(ReducersBenchmarkWorkerContext.class); conf.setLong(PseudoRandomInputFormatConstants.AGGREGATE_VERTICES, BenchmarkOption.VERTICES.getOptionLongValue(cmd)); conf.setLong(PseudoRandomInputFormatConstants.EDGES_PER_VERTEX, 1); conf.setInt(REDUCERS_NUM, REDUCERS.getOptionIntValue(cmd)); conf.setInt("workers", conf.getInt(GiraphConstants.MAX_WORKERS, -1)); }
@Override protected void prepareConfiguration(GiraphConfiguration conf, CommandLine cmd) { conf.setComputationClass(ShortestPathsComputation.class); if (EDGES_CLASS.getOptionIntValue(cmd, 1) == 1) { conf.setOutEdgesClass(ArrayListEdges.class); } else { conf.setOutEdgesClass(HashMapEdges.class); } LOG.info("Using class " + GiraphConstants.COMPUTATION_CLASS.get(conf)); conf.setVertexInputFormatClass(PseudoRandomVertexInputFormat.class); if (!NO_COMBINER.optionTurnedOn(cmd)) { conf.setMessageCombinerClass(MinimumDoubleMessageCombiner.class); } conf.setLong(PseudoRandomInputFormatConstants.AGGREGATE_VERTICES, BenchmarkOption.VERTICES.getOptionLongValue(cmd)); conf.setLong(PseudoRandomInputFormatConstants.EDGES_PER_VERTEX, BenchmarkOption.EDGES_PER_VERTEX.getOptionLongValue(cmd)); }
@Override protected void prepareConfiguration(GiraphConfiguration conf, CommandLine cmd) { conf.setComputationClass(AggregatorsBenchmarkComputation.class); conf.setMasterComputeClass(AggregatorsBenchmarkMasterCompute.class); conf.setVertexInputFormatClass(PseudoRandomVertexInputFormat.class); conf.setWorkerContextClass(AggregatorsBenchmarkWorkerContext.class); conf.setLong(PseudoRandomInputFormatConstants.AGGREGATE_VERTICES, BenchmarkOption.VERTICES.getOptionLongValue(cmd)); conf.setLong(PseudoRandomInputFormatConstants.EDGES_PER_VERTEX, 1); conf.setInt(AGGREGATORS_NUM, AGGREGATORS.getOptionIntValue(cmd)); conf.setInt("workers", conf.getInt(GiraphConstants.MAX_WORKERS, -1)); MasterLoggingAggregator.setUseMasterLoggingAggregator(true, conf); }
@Override protected void prepareConfiguration(GiraphConfiguration conf, CommandLine cmd) { conf.setComputationClass(RandomMessageComputation.class); conf.setVertexInputFormatClass(PseudoRandomVertexInputFormat.class); conf.setWorkerContextClass(RandomMessageBenchmarkWorkerContext.class); conf.setMasterComputeClass(RandomMessageBenchmarkMasterCompute.class); conf.setLong(PseudoRandomInputFormatConstants.AGGREGATE_VERTICES, BenchmarkOption.VERTICES.getOptionLongValue(cmd)); conf.setLong(PseudoRandomInputFormatConstants.EDGES_PER_VERTEX, BenchmarkOption.EDGES_PER_VERTEX.getOptionLongValue(cmd)); conf.setInt(SUPERSTEP_COUNT, BenchmarkOption.SUPERSTEPS.getOptionIntValue(cmd)); conf.setInt(RandomMessageBenchmark.NUM_BYTES_PER_MESSAGE, BYTES_PER_MESSAGE.getOptionIntValue(cmd)); conf.setInt(RandomMessageBenchmark.NUM_MESSAGES_PER_EDGE, MESSAGES_PER_EDGE.getOptionIntValue(cmd)); if (FLUSH_THREADS.optionTurnedOn(cmd)) { conf.setInt(GiraphConstants.MSG_NUM_FLUSH_THREADS, FLUSH_THREADS.getOptionIntValue(cmd)); } }