Examples of ImmutableClassesGiraphConfiguration


Examples of org.apache.giraph.conf.ImmutableClassesGiraphConfiguration

  @Before
  public void setUp() {
    GiraphConfiguration tmpConfig = new GiraphConfiguration();
    tmpConfig.setComputationClass(IntNoOpComputation.class);
    conf = new ImmutableClassesGiraphConfiguration(tmpConfig);
  }
View Full Code Here

Examples of org.apache.giraph.conf.ImmutableClassesGiraphConfiguration

  private void testRange(int numWorkers, int keySpaceSize, int allowedWorkerDiff, boolean emptyWorkers) {
    Configuration conf = new Configuration();
    conf.setLong(GiraphConstants.PARTITION_VERTEX_KEY_SPACE_SIZE, keySpaceSize);
    SimpleLongRangePartitionerFactory<Writable, Writable> factory =
        new SimpleLongRangePartitionerFactory<Writable, Writable>();
    factory.setConf(new ImmutableClassesGiraphConfiguration(conf));

    ArrayList<WorkerInfo> infos = new ArrayList<WorkerInfo>();
    for (int i = 0; i < numWorkers; i++) {
      WorkerInfo info = new WorkerInfo();
      info.setInetSocketAddress(new InetSocketAddress(8080));
View Full Code Here

Examples of org.apache.giraph.conf.ImmutableClassesGiraphConfiguration

      GiraphConfiguration giraphConfiguration = new GiraphConfiguration();
      giraphConfiguration.setComputationClass(TestComputation.class);
      giraphConfiguration.setOutEdgesClass(edgesClass);
      giraphConfiguration.setVertexClass(ByteValueVertex.class);

      ImmutableClassesGiraphConfiguration immutableClassesGiraphConfiguration =
                new ImmutableClassesGiraphConfiguration(giraphConfiguration);
      Vertex bv = immutableClassesGiraphConfiguration.createVertex();
      assertTrue(bv instanceof ByteValueVertex);
      return bv;
    }
View Full Code Here

Examples of org.apache.giraph.conf.ImmutableClassesGiraphConfiguration

  /**
   * Initialize the MiniYARNCluster for the integration test.
   */
  private void initYarnCluster() {
    cluster = new MiniYARNCluster(TestYarnJob.class.getName(), 1, 1, 1);
    cluster.init(new ImmutableClassesGiraphConfiguration(conf));
    cluster.start();
  }
View Full Code Here

Examples of org.apache.giraph.conf.ImmutableClassesGiraphConfiguration

  protected Vertex<LongWritable, FloatWritable, DoubleWritable>
  instantiateVertex(Class<? extends OutEdges> edgesClass) {
    GiraphConfiguration giraphConfiguration = new GiraphConfiguration();
    giraphConfiguration.setComputationClass(TestComputation.class);
    giraphConfiguration.setOutEdgesClass(edgesClass);
    ImmutableClassesGiraphConfiguration immutableClassesGiraphConfiguration =
        new ImmutableClassesGiraphConfiguration(giraphConfiguration);
    return immutableClassesGiraphConfiguration.createVertex();
  }
View Full Code Here

Examples of org.apache.giraph.conf.ImmutableClassesGiraphConfiguration

  instantiateOutEdges(Class<? extends OutEdges> edgesClass) {
    GiraphConfiguration giraphConfiguration = new GiraphConfiguration();
    // Needed to extract type arguments in ReflectionUtils.
    giraphConfiguration.setComputationClass(TestComputation.class);
    giraphConfiguration.setOutEdgesClass(edgesClass);
    ImmutableClassesGiraphConfiguration immutableClassesGiraphConfiguration =
        new ImmutableClassesGiraphConfiguration(giraphConfiguration);
    return immutableClassesGiraphConfiguration.createOutEdges();
  }
View Full Code Here

Examples of org.apache.giraph.conf.ImmutableClassesGiraphConfiguration

  @Before
  public void setUp() {
    GiraphConfiguration tmpConfig = new GiraphConfiguration();
    tmpConfig.setComputationClass(IntNoOpComputation.class);
    GiraphConstants.AUTHENTICATE.set(tmpConfig, true);
    conf = new ImmutableClassesGiraphConfiguration(tmpConfig);
  }
View Full Code Here

Examples of org.apache.giraph.conf.ImmutableClassesGiraphConfiguration

   * Constructor requiring classes
   *
   * @param conf Should have vertex and edge classes set.
   */
  public TestGraph(GiraphConfiguration conf) {
    this.conf = new ImmutableClassesGiraphConfiguration(conf);
  }
View Full Code Here

Examples of org.apache.giraph.conf.ImmutableClassesGiraphConfiguration

    throws IOException {
    containerId = cId; // future good stuff will need me to operate.
    appAttemptId = aId;
    lastResponseId = new AtomicInteger(0);
    giraphConf =
      new ImmutableClassesGiraphConfiguration(new GiraphConfiguration());
    yarnConf = new YarnConfiguration(giraphConf);
    completedCount = new AtomicInteger(0);
    failedCount = new AtomicInteger(0);
    allocatedCount = new AtomicInteger(0);
    successfulCount = new AtomicInteger(0);
View Full Code Here

Examples of org.apache.giraph.conf.ImmutableClassesGiraphConfiguration

   * unchecked exception to end job run on failure.
   *
   * @param conf the Configuration for this run.
   */
  public GiraphConfigurationValidator(Configuration conf) {
    this.conf = new ImmutableClassesGiraphConfiguration(conf);
  }
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.