/** * Get the maximum number of supersteps of this application. After this * many supersteps are executed, the application will shutdown. * * @return Maximum number of supersteps */ public int getMaxNumberOfSupersteps() { return MAX_NUMBER_OF_SUPERSTEPS.get(this); }
/** * Constructor. * * @param conf Configuration * @param oocEngine Out-of-core engine */ DiskBackedDataStore(ImmutableClassesGiraphConfiguration conf, OutOfCoreEngine oocEngine) { this.minBufferSizeToOffload = MINIMUM_BUFFER_SIZE_TO_FLUSH.get(conf); this.oocEngine = oocEngine; }
/** * Get the checkpoint frequeuncy of how many supersteps to wait * before checkpointing * * @return Checkpoint frequency (0 means never) */ public int getCheckpointFrequency() { return CHECKPOINT_FREQUENCY.get(this); }
/** * Get the maximum timeout (in milliseconds) for waiting for all tasks * to complete after the job is done. * * @return Wait task done timeout in milliseconds. */ public int getWaitTaskDoneTimeoutMs() { return WAIT_TASK_DONE_TIMEOUT_MS.get(this); }
/** * @return Number of retries when creating an HDFS file before failing. */ public int getHdfsFileCreationRetries() { return HDFS_FILE_CREATION_RETRIES.get(this); }
/** * @return Milliseconds to wait before retrying an HDFS file creation * operation. */ public int getHdfsFileCreationRetryWaitMs() { return HDFS_FILE_CREATION_RETRY_WAIT_MS.get(this); } }
/** * Constructor * * @param conf configuration * @param oocEngine out-of-core engine */ public FixedPartitionsOracle(ImmutableClassesGiraphConfiguration conf, OutOfCoreEngine oocEngine) { this.maxPartitionsInMemory = GiraphConstants.MAX_PARTITIONS_IN_MEMORY.get(conf); this.oocEngine = oocEngine; }
/** * Constructor. * * @param conf Giraph configuration */ public RequestEncoder(GiraphConfiguration conf) { bufferStartingSize = GiraphConstants.NETTY_REQUEST_ENCODER_BUFFER_SIZE.get(conf); }
/** * Get heap size (in MB) for each task in our Giraph job run, * assuming this job will run on the "pure YARN" profile. * * @return the heap size for all tasks, in MB */ public int getYarnTaskHeapMb() { return GIRAPH_YARN_TASK_HEAP_MB.get(this); }
/** * Get the max task attempts * * @return Max task attempts or -1, if not set */ public int getMaxTaskAttempts() { return MAX_TASK_ATTEMPTS.get(this); }
/** * Get the number of milliseconds to wait for an event before continuing on * * @return Number of milliseconds to wait for an event before continuing on */ public int getEventWaitMsecs() { return EVENT_WAIT_MSECS.get(this); }
/** * Get the maximum milliseconds to wait before giving up trying to get the * minimum number of workers before a superstep. * * @return Maximum milliseconds to wait before giving up trying to get the * minimum number of workers before a superstep */ public int getMaxMasterSuperstepWaitMsecs() { return MAX_MASTER_SUPERSTEP_WAIT_MSECS.get(this); }
public int getNettyServerThreads() { return NETTY_SERVER_THREADS.get(this); }
public int getNumComputeThreads() { return NUM_COMPUTE_THREADS.get(this); }
/** * Get the number of threads to use for writing output in the end of the * application. If output format is not thread safe, returns 1. * * @return Number of output threads */ public final int getNumOutputThreads() { if (!vertexOutputFormatThreadSafe()) { return 1; } else { return NUM_OUTPUT_THREADS.get(this); } }
/** * Constructor * * @param conf Giraph configuration * @param serviceWorker Service worker */ public SendEdgeCache(ImmutableClassesGiraphConfiguration conf, CentralizedServiceWorker<?, ?, ?> serviceWorker) { super(conf, serviceWorker, MAX_EDGE_REQUEST_SIZE.get(conf), ADDITIONAL_EDGE_REQUEST_SIZE.get(conf)); }
/** * Constructor. * * @param conf Giraph configuration * @param serviceWorker Service worker */ public SendPartitionCache(ImmutableClassesGiraphConfiguration<I, V, E> conf, CentralizedServiceWorker<?, ?, ?> serviceWorker) { super(conf, serviceWorker, MAX_VERTEX_REQUEST_SIZE.get(conf), ADDITIONAL_VERTEX_REQUEST_SIZE.get(conf)); }
/** * Constructor * * @param config configuration */ public ExtendedByteArrayOutputBuffer( ImmutableClassesGiraphConfiguration<?, ?, ?> config) { this.config = config; maxBufSize = CAPACITY_OF_DATAOUT_IN_BUFFER.get(config); threshold = (int) (FILLING_THRESHOLD_OF_DATAOUT_IN_BUFFER.get(config) * maxBufSize); }