Package org.apache.giraph.job

Examples of org.apache.giraph.job.GiraphJob.run()


    } catch (IllegalArgumentException e) {
    }

    GiraphConstants.SPLIT_MASTER_WORKER.set(conf, false);
    try {
      job.run(true);
      fail();
    } catch (IllegalArgumentException e) {
    }

    conf.setWorkerConfiguration(1, 1, 100.0f);
View Full Code Here


      fail();
    } catch (IllegalArgumentException e) {
    }

    conf.setWorkerConfiguration(1, 1, 100.0f);
    job.run(true);
  }

  /**
   * Run a sample BSP job in JobTracker, kill a task, and make sure
   * the job fails (not enough attempts to restart)
View Full Code Here

      setupConfiguration(giraphJob);
      giraphConf.setComputationClass(EdgeNotification.class);
      giraphConf.setVertexInputFormatClass(TableEdgeInputFormat.class);
      giraphConf.setVertexOutputFormatClass(TableEdgeOutputFormat.class);

      assertTrue(giraphJob.run(true));
      if(log.isInfoEnabled())
        log.info("Giraph job successful. Checking output qualifier.");

      // Do a get on row 0002, it should have a parent of 0001
      // if the outputFormat worked.
View Full Code Here

        columnsToFetch.add(new Pair<Text, Text>(FAMILY, CHILDREN));
        AccumuloInputFormat.fetchColumns(job.getConfiguration(), columnsToFetch);

        if(log.isInfoEnabled())
            log.info("Running edge notification job using Accumulo input");
        assertTrue(job.run(true));
        Scanner scanner = c.createScanner(TABLE_NAME, new Authorizations());
        scanner.setRange(new Range("0002", "0002"));
        scanner.fetchColumn(FAMILY, OUTPUT_FIELD);
        boolean foundColumn = false;
View Full Code Here

    GeneratedVertexReader.READER_VERTICES.set(job.getConfiguration(),
        TestComputationStateComputation.NUM_VERTICES);
    // Increase the number of partitions
    GiraphConstants.USER_PARTITION_COUNT.set(job.getConfiguration(),
        TestComputationStateComputation.NUM_PARTITIONS);
    assertTrue(job.run(true));
  }
}
View Full Code Here

    conf.setVertexOutputFormatClass(SimplePageRankVertexOutputFormat.class);
    conf.setWorkerContextClass(
        SimpleMutateGraphComputation.SimpleMutateGraphVertexWorkerContext.class);
    GiraphJob job = prepareJob(getCallingMethodName(), conf,
        getTempPath(getCallingMethodName()));
    assertTrue(job.run(true));
  }
}
View Full Code Here

        unlikelyWorkers,
        100.0f);
    // Only one poll attempt of one second to make failure faster
    job.getConfiguration().setMaxMasterSuperstepWaitMsecs(1000);
    job.getConfiguration().setEventWaitMsecs(1000);
    assertFalse(job.run(false));
  }
}
View Full Code Here

    GiraphConfiguration configuration = job.getConfiguration();
    GiraphConstants.CHECKPOINT_DIRECTORY.set(configuration, checkpointsDir.toString());
    GiraphConstants.CLEANUP_CHECKPOINTS_AFTER_SUCCESS.set(configuration, false);
    configuration.setCheckpointFrequency(2);

    assertTrue(job.run(true));

    long idSum = 0;
    if (!runningInDistributedMode()) {
      FileStatus fileStatus = getSinglePartFileStatus(job.getConfiguration(),
          outputPath);
View Full Code Here

    configuration.setMasterComputeClass(
        SimpleCheckpoint.SimpleCheckpointVertexMasterCompute.class);
    GiraphConstants.CHECKPOINT_DIRECTORY.set(restartedJob.getConfiguration(),
        checkpointsDir.toString());

    assertTrue(restartedJob.run(true));
    if (!runningInDistributedMode()) {
      long idSumRestarted =
          SimpleCheckpoint.SimpleCheckpointVertexWorkerContext
              .getFinalSum();
      System.out.println("testBspCheckpoint: idSumRestarted = " +
View Full Code Here

    // run the job, collect results
    if (LOG.isDebugEnabled()) {
      LOG.debug("Attempting to run Vertex: " + vertexClassName);
    }
    boolean verbose = !cmd.hasOption('q');
    return job.run(verbose) ? 0 : -1;
  }

  /**
   * Populate internal Hadoop Job (and Giraph IO Formats) with Hadoop-specific
   * configuration/setup metadata, propagating exceptions to calling code.
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.