name
stringlengths
12
178
code_snippet
stringlengths
8
36.5k
score
float64
3.26
3.68
hadoop_YarnServerSecurityUtils_updateAMRMToken_rdh
/** * Update the new AMRMToken into the ugi used for RM proxy. * * @param token * the new AMRMToken sent by RM * @param user * ugi used for RM proxy * @param conf * configuration */ public static void updateAMRMToken(Token token, UserGroupInformation user, Configuration conf) { Token<AMRMTokenIdentif...
3.26
hadoop_YarnServerSecurityUtils_parseCredentials_rdh
/** * Parses the container launch context and returns a Credential instance that * contains all the tokens from the launch context. * * @param launchContext * ContainerLaunchContext. * @return the credential instance * @throws IOException * if there are I/O errors. */ public static Credentials parseCredent...
3.26
hadoop_YarnServerSecurityUtils_selectAMRMTokenIdentifier_rdh
// Obtain the needed AMRMTokenIdentifier from the remote-UGI. RPC layer // currently sets only the required id, but iterate through anyways just to be // sure. private static AMRMTokenIdentifier selectAMRMTokenIdentifier(UserGroupInformation remoteUgi) throws IOException { AMRMTokenIdentifier result = null; Set...
3.26
hadoop_YarnServerSecurityUtils_authorizeRequest_rdh
/** * Authorizes the current request and returns the AMRMTokenIdentifier for the * current application. * * @return the AMRMTokenIdentifier instance for the current user * @throws YarnException * exceptions from yarn servers. */ public static AMRMTokenIdentifier authorizeRequest() throws YarnException { Us...
3.26
hadoop_CopyOutputFormat_getOutputCommitter_rdh
/** * {@inheritDoc } */ @Override public OutputCommitter getOutputCommitter(TaskAttemptContext context) throws IOException { return new CopyCommitter(getOutputPath(context), context); }
3.26
hadoop_CopyOutputFormat_setCommitDirectory_rdh
/** * Setter for the final directory for DistCp (where files copied will be * moved, atomically.) * * @param job * The Job on whose configuration the working-directory is to be set. * @param commitDirectory * The path to use for final commit. */ public static void setCommitDirectory(Job job, Path commitDire...
3.26
hadoop_CopyOutputFormat_getWorkingDirectory_rdh
/** * Getter for the working directory. * * @param job * The Job from whose configuration the working-directory is to * be retrieved. * @return The working-directory Path. */ public static Path getWorkingDirectory(Job job) { return getWorkingDirectory(job.getConfiguration()); }
3.26
hadoop_CopyOutputFormat_getCommitDirectory_rdh
/** * Getter for the final commit-directory. * * @param job * The Job from whose configuration the commit-directory is to be * retrieved. * @return The commit-directory Path. */ public static Path getCommitDirectory(Job job) { return getCommitDirectory(job.getConfiguration()); }
3.26
hadoop_CopyOutputFormat_checkOutputSpecs_rdh
/** * {@inheritDoc } */ @Override public void checkOutputSpecs(JobContext context) throws IOException { Configuration conf = context.getConfiguration(); if (getCommitDirectory(conf) == null) { throw new IllegalStateException("Commit directory not configured"); } Path workingPath = getWorkingDirectory(conf); if (wo...
3.26
hadoop_CopyOutputFormat_setWorkingDirectory_rdh
/** * Setter for the working directory for DistCp (where files will be copied * before they are moved to the final commit-directory.) * * @param job * The Job on whose configuration the working-directory is to be set. * @param workingDirectory * The path to use as the working directory. */ public static vo...
3.26
hadoop_ApplicationACLsManager_checkAccess_rdh
/** * If authorization is enabled, checks whether the user (in the callerUGI) is * authorized to perform the access specified by 'applicationAccessType' on * the application by checking if the user is applicationOwner or part of * application ACL for the specific access-type. * <ul> * <li>The owner of the applica...
3.26
hadoop_ApplicationACLsManager_isAdmin_rdh
/** * Check if the given user in an admin. * * @param calledUGI * UserGroupInformation for the user * @return true if the user is an admin, false otherwise */ public final boolean isAdmin(final UserGroupInformation calledUGI) { return this.adminAclsManager.isAdmin(calledUGI); }
3.26
hadoop_BaseNMTokenSecretManager_createNMToken_rdh
/** * Helper function for creating NMTokens. * * @param applicationAttemptId * application AttemptId. * @param nodeId * node Id. * @param applicationSubmitter * application Submitter. * @return NMToken. */ public Token createNMToken(ApplicationAttemptId applicationAttemptId, NodeId nodeId, String appli...
3.26
hadoop_BaseNMTokenSecretManager_createIdentifier_rdh
/** * It is required for RPC */ @Override public NMTokenIdentifier createIdentifier() { return new NMTokenIdentifier(); }
3.26
hadoop_RecordComparator_define_rdh
/** * Register an optimized comparator for a {@link Record} implementation. * * @param c * record classs for which a raw comparator is provided * @param comparator * Raw comparator instance for class c */ public static synchronized void define(Class c, RecordComparator comparator) { WritableComparator.d...
3.26
hadoop_CurrentJHParser_canParse_rdh
/** * Can this parser parse the input? * * @param input * @return Whether this parser can parse the input. * @throws IOException */public static boolean canParse(InputStream input) throws IOException { final DataInputStream in = new ForkedDataInputStream(input); try { final EventReader reader...
3.26
hadoop_S3ClientFactory_withRegion_rdh
/** * Set region. * * @param value * new value * @return the builder */ public S3ClientCreationParameters withRegion(final String value) { region = value; return this; }
3.26
hadoop_S3ClientFactory_getExecutionInterceptors_rdh
/** * List of execution interceptors to include in the chain * of interceptors in the SDK. * * @return the interceptors list */ public List<ExecutionInterceptor> getExecutionInterceptors() { return executionInterceptors; }
3.26
hadoop_S3ClientFactory_withMetrics_rdh
/** * Metrics binding. This is the S3A-level * statistics interface, which will be wired * up to the AWS callbacks. * * @param statistics * statistics implementation * @return this object */ public S3ClientCreationParameters withMetrics(@Nullable final StatisticsFromAwsSdk statistics) { metrics = statisti...
3.26
hadoop_S3ClientFactory_getRegion_rdh
/** * Get the region. * * @return invoker */public String getRegion() { return region; }
3.26
hadoop_S3ClientFactory_getMinimumPartSize_rdh
/** * Get the minimum part size for transfer parts. * * @return part size */public long getMinimumPartSize() { return minimumPartSize; }
3.26
hadoop_S3ClientFactory_withCredentialSet_rdh
/** * Set credentials. * * @param value * new value * @return the builder */ public S3ClientCreationParameters withCredentialSet(final AwsCredentialsProvider value) { credentialSet = value; return this; }
3.26
hadoop_S3ClientFactory_withPathStyleAccess_rdh
/** * Set path access option. * * @param value * new value * @return the builder */ public S3ClientCreationParameters withPathStyleAccess(final boolean value) { pathStyleAccess = value; retur...
3.26
hadoop_S3ClientFactory_withExecutionInterceptors_rdh
/** * List of execution interceptors. * * @param interceptors * interceptors list. * @return this object */ public S3ClientCreationParameters withExecutionInterceptors(@Nullable final List<ExecutionInterceptor> interceptors) { executionInterceptors = interceptors; return this;}
3.26
hadoop_S3ClientFactory_getMultiPartThreshold_rdh
/** * Get the threshold for multipart operations. * * @return multipart threshold */ public long getMultiPartThreshold() {return multiPartThreshold; }
3.26
hadoop_S3ClientFactory_isMultipartCopy_rdh
/** * Get the multipart flag. * * @return multipart flag */ public boolean isMultipartCopy() { return multipartCopy; }
3.26
hadoop_S3ClientFactory_m1_rdh
/** * Set endpoint. * * @param value * new value * @return the builder */ public S3ClientCreationParameters m1(final String value) { endpoint = value; return this; }
3.26
hadoop_S3ClientFactory_withPathUri_rdh
/** * Set full s3a path. * added in HADOOP-18330 * * @param value * new value * @return the builder */ public S3ClientCreationParameters withPathUri(final URI value) { pathUri = value; return this; }
3.26
hadoop_S3ClientFactory_withUserAgentSuffix_rdh
/** * Set UA suffix. * * @param value * new value * @return the builder */ public S3ClientCreationParameters withUserAgentSuffix(final String value) { userAgentSuffix = value; return this; }
3.26
hadoop_S3ClientFactory_withHeader_rdh
/** * Add a custom header. * * @param header * header name * @param value * new value * @return the builder */ public S3ClientCreationParameters withHeader(String header, String value) { headers.put(header, value); return this; }
3.26
hadoop_S3ClientFactory_getHeaders_rdh
/** * Get the map of headers. * * @return (mutable) header map */public Map<String, String> getHeaders() { return headers; }
3.26
hadoop_S3ClientFactory_getPathUri_rdh
/** * Get the full s3 path. * added in HADOOP-18330 * * @return path URI */ public URI getPathUri() { return pathUri; }
3.26
hadoop_S3ClientFactory_getTransferManagerExecutor_rdh
/** * Get the executor that the transfer manager will use to execute background tasks. * * @return part size */ public Executor getTransferManagerExecutor() { return transferManagerExecutor;}
3.26
hadoop_S3ClientFactory_withMinimumPartSize_rdh
/** * Set the minimum part size for transfer parts. * * @param value * new value * @return the builder */ public S3ClientCreationParameters withMinimumPartSize(final long value) { minimumPartSize = value; return this; }
3.26
hadoop_S3ClientFactory_withTransferManagerExecutor_rdh
/** * Set the executor that the transfer manager will use to execute background tasks. * * @param value * new value * @return the builder */ public S3ClientCreationParameters withTransferManagerExecutor(final Executor value) { transferManagerExecutor = value; return this; }
3.26
hadoop_S3ClientFactory_withMultipartThreshold_rdh
/** * Set the threshold for multipart operations. * * @param value * new value * @return the builder */ public S3ClientCreationParameters withMultipartThreshold(final long value) { multiPartThreshold = value; return this; }
3.26
hadoop_ZoneReencryptionStatus_setZoneName_rdh
/** * Set the zone name. The zone name is resolved from inode id and set during * a listReencryptionStatus call, for the crypto admin to consume. */public void setZoneName(final String name) { Preconditions.checkNotNull(name, "zone name cannot be null"); zoneName = name; }
3.26
hadoop_AvailableSpaceResolver_getSubclusterInfo_rdh
/** * Get the mapping from NamespaceId to subcluster space info. It gets this * mapping from the subclusters through expensive calls (e.g., RPC) and uses * caching to avoid too many calls. The cache might be updated asynchronously * to reduce latency. * * @return NamespaceId to {@link SubclusterAvailableSpace}. ...
3.26
hadoop_ImageLoader_getLoader_rdh
/** * Factory for obtaining version of image loader that can read * a particular image format. */ @InterfaceAudience.Privatepublic class LoaderFactory { // Java doesn't support static methods on interfaces, which necessitates // this factory class /** * Find an image loader capable of interpreting t...
3.26
hadoop_ParserValidator_validate_rdh
/** * Validates the input parameters for the {@link LogParser}. * * @param logs * input log streams to the {@link LogParser}. * @return whether the input parameters are valid or not. */ public final boolean validate(final InputStream logs) { // TODO return true; }
3.26
hadoop_ContainerRollingLogAppender_getContainerLogDir_rdh
/** * Getter/Setter methods for log4j. * * @return containerLogDir. */ public String getContainerLogDir() { return this.containerLogDir; }
3.26
hadoop_RejectPlacementRule_setConfig_rdh
/** * The Reject rule does not use any configuration. Override and ignore all * configuration. * * @param initArg * the config to be set */ @Override public void setConfig(Object initArg) { // This rule ignores all config, just log and return LOG.debug("RejectPlacementRule instantiated"); }
3.26
hadoop_BufferData_getChecksum_rdh
/** * Computes CRC32 checksum of the given buffer's contents. * * @param buffer * the buffer whose content's checksum is to be computed. * @return the computed checksum. */ public static long getChecksum(ByteBuffer buffer) { ByteBuffer tempBuffer = buffer.duplicate(); tempBuffer.rewind(); CRC32 crc3...
3.26
hadoop_BufferData_updateState_rdh
/** * Updates the current state to the specified value. * Asserts that the current state is as expected. * * @param newState * the state to transition to. * @param expectedCurrentState * the collection of states from which * transition to {@code newState} is allowed. * @throws IllegalArgumentException *...
3.26
hadoop_BufferData_setPrefetch_rdh
/** * Indicates that a prefetch operation is in progress. * * @param actionFuture * the {@code Future} of a prefetch action. * @throws IllegalArgumentException * if actionFuture is null. */ public synchronized void setPrefetch(Future<Void> actionFuture) { Validate.checkNotNull(actionFuture, "actionFuture...
3.26
hadoop_BufferData_getBuffer_rdh
/** * Gets the buffer associated with this block. * * @return the buffer associated with this block. */ public ByteBuffer getBuffer() { return this.buffer; }
3.26
hadoop_BufferData_setDone_rdh
/** * Indicates that this block is no longer of use and can be reclaimed. */ public synchronized void setDone() { if (this.checksum != 0) { if (getChecksum(this.buffer) != this.checksum) { throw new IllegalStateException("checksum changed after setReady()"); } } this.f0 = S...
3.26
hadoop_BufferData_setReady_rdh
/** * Marks the completion of reading data into the buffer. * The buffer cannot be modified once in this state. * * @param expectedCurrentState * the collection of states from which transition to READY is allowed. */ public synchronized void setReady(State... expectedCurrentState) { if (this.checksum !=...
3.26
hadoop_BufferData_getBlockNumber_rdh
/** * Gets the id of this block. * * @return the id of this block. */ public int getBlockNumber() { return this.blockNumber; }
3.26
hadoop_BufferData_throwIfStateIncorrect_rdh
/** * Helper that asserts the current state is one of the expected values. * * @param states * the collection of allowed states. * @throws IllegalArgumentException * if states is null. */public void throwIfStateIncorrect(State... states) { Validate.checkNotNull(states, "states"); if (this.stateEquals...
3.26
hadoop_BufferData_getState_rdh
/** * Gets the state of this block. * * @return the state of this block. */ public State getState() { return this.f0; }
3.26
hadoop_BufferData_setCaching_rdh
/** * Indicates that a caching operation is in progress. * * @param actionFuture * the {@code Future} of a caching action. * @throws IllegalArgumentException * if actionFuture is null. */ public synchronized void setCaching(Future<Void> actionFuture) { Validate.checkNotNull(actionFuture, "actionFuture");...
3.26
hadoop_FileSystemMultipartUploader_innerComplete_rdh
/** * The upload complete operation. * * @param multipartUploadId * the ID of the upload * @param filePath * path * @param handleMap * map of handles * @return the path handle * @throws IOException * failure */ private PathHandle innerComplete(UploadHandle multipartUploadId, Path filePath, Map<Integ...
3.26
hadoop_S3ListResult_hasPrefixesOrObjects_rdh
/** * Does this listing have prefixes or objects? * * @return true if the result is non-empty */ public boolean hasPrefixesOrObjects() { return (!getCommonPrefixes().isEmpty()) || (!getS3Objects().isEmpty()); }
3.26
hadoop_S3ListResult_representsEmptyDirectory_rdh
/** * Does this listing represent an empty directory? * * @param dirKey * directory key * @return true if the list is considered empty. */ public boolean representsEmptyDirectory(final String dirKey) { // If looking for an empty directory, the marker must exist but // no children. // So the listing ...
3.26
hadoop_S3ListResult_v1_rdh
/** * Restricted constructors to ensure v1 or v2, not both. * * @param result * v1 result * @return new list result container */ public static S3ListResult v1(ListObjectsResponse result) { return new S3ListResult(requireNonNull(result), null); }
3.26
hadoop_S3ListResult_m0_rdh
/** * Dump the result at debug level. * * @param log * log to use */ public void m0(Logger log) { Collection<CommonPrefix> prefixes = getCommonPrefixes(); Collection<S3Object> v2 = getS3Objects(); log.debug("Prefix count = {}; object count={}", prefixes.size...
3.26
hadoop_S3ListResult_isV1_rdh
/** * Is this a v1 API result or v2? * * @return true if v1, false if v2 */ public boolean isV1() { return v1Result != null; }
3.26
hadoop_S3ListResult_objectKeys_rdh
/** * Get the list of keys in the list result. * * @return a possibly empty list */ private List<String> objectKeys() { return getS3Objects().stream().map(S3Object::key).collect(Collectors.toList()); }
3.26
hadoop_S3ListResult_v2_rdh
/** * Restricted constructors to ensure v1 or v2, not both. * * @param result * v2 result * @return new list result container */ public static S3ListResult v2(ListObjectsV2Response result) { return new S3ListResult(null, requireNonNull(result)); }
3.26
hadoop_ContainerSimulator_createFromTaskContainerDefinition_rdh
/** * Invoked when AM schedules containers to allocate. * * @param def * The task's definition object. * @return ContainerSimulator object */ public static ContainerSimulator createFromTaskContainerDefinition(TaskContainerDefinition def) { return new ContainerSimulator(de...
3.26
hadoop_ResourceCalculatorProcessTree_initialize_rdh
/** * Initialize the object. * * @throws YarnException * Throws an exception on error. */ public void initialize() throws YarnException { }
3.26
hadoop_S3AInMemoryInputStream_ensureCurrentBuffer_rdh
/** * Ensures that a non-empty valid buffer is available for immediate reading. * It returns true when at least one such buffer is available for reading. * It returns false on reaching the end of the stream. * * @return true if at least one such buffer is available for reading, false otherw...
3.26
hadoop_CompressionCodec_createOutputStreamWithCodecPool_rdh
/** * Create an output stream with a codec taken from the global CodecPool. * * @param codec * The codec to use to create the output stream. * @param conf * The configuration to use if we need to create a new codec. * @param out * The output stream to wrap. * @return The new output stream * @throws IOEx...
3.26
hadoop_CompressionCodec_createInputStreamWithCodecPool_rdh
/** * Create an input stream with a codec taken from the global CodecPool. * * @param codec * The codec to use to create the input stream. * @param conf * The configuration to use if we need to create a new codec. * @param in * The input stream to wrap. * @return The new input stream * @throws IOExcepti...
3.26
hadoop_PairedDurationTrackerFactory_asDuration_rdh
/** * * @return the global duration */ @Override public Duration asDuration() { return firstDuration.asDuration(); }
3.26
hadoop_DefaultCodec_createDirectDecompressor_rdh
/** * {@inheritDoc } */@Override public DirectDecompressor createDirectDecompressor() { return ZlibFactory.getZlibDirectDecompressor(conf); }
3.26
hadoop_SequenceFileAsTextRecordReader_nextKeyValue_rdh
/** * Read key/value pair in a line. */ public synchronized boolean nextKeyValue() throws IOException, InterruptedException { if (!sequenceFileRecordReader.nextKeyValue()) { return false; } if (f0 == null) { f0 = new Text(); } if (value == null) { value = new Text(); } ...
3.26
hadoop_GetClusterNodeAttributesRequest_newInstance_rdh
/** * Create new instance of GetClusterNodeAttributesRequest. * * @return GetClusterNodeAttributesRequest is returned. */ public static GetClusterNodeAttributesRequest newInstance() { return Records.newRecord(GetClusterNodeAttributesRequest.class); }
3.26
hadoop_RouterMetricsService_getNamenodeMetrics_rdh
/** * Get the Namenode metrics. * * @return Namenode metrics. */ public NamenodeBeanMetrics getNamenodeMetrics() { return this.nnMetrics; }
3.26
hadoop_RouterMetricsService_m0_rdh
/** * Get the metrics system for the Router Client. * * @return Router Client metrics. */ public RouterClientMetrics m0() { return this.routerClientMetrics; }
3.26
hadoop_RouterMetricsService_getRouterMetrics_rdh
/** * Get the metrics system for the Router. * * @return Router metrics. */ public RouterMetrics getRouterMetrics() { return this.routerMetrics; }
3.26
hadoop_RouterMetricsService_getJvmMetrics_rdh
/** * Get the JVM metrics for the Router. * * @return JVM metrics. */ public JvmMetrics getJvmMetrics() { if (this.routerMetrics == null) { return null; } return this.routerMetrics.getJvmMetrics(); }
3.26
hadoop_RouterMetricsService_getRBFMetrics_rdh
/** * Get the federation metrics. * * @return Federation metrics. */ public RBFMetrics getRBFMetrics() { return this.rbfMetrics; }
3.26
hadoop_DefaultAppReportFetcher_getApplicationReport_rdh
/** * Get an application report for the specified application id from the RM and * fall back to the Application History Server if not found in RM. * * @param appId * id of the application to get. * @return the ApplicationReport for the appId. * @throws YarnException * on any error. * @throws IOException *...
3.26
hadoop_AHSController_logs_rdh
/** * Render the logs page. */ public void logs() { render(AHSLogsPage.class); }
3.26
hadoop_JobBase_getDoubleValue_rdh
/** * * @param name * the counter name * @return return the value of the given counter. */ protected Double getDoubleValue(Object name) { return this.doubleCounters.get(name); }
3.26
hadoop_JobBase_setLongValue_rdh
/** * Set the given counter to the given value * * @param name * the counter name * @param value * the value for the counter */ protected void setLongValue(Object name, long value) { this.longCounters.put(name, Long.valueOf(value)); }
3.26
hadoop_JobBase_addDoubleValue_rdh
/** * Increment the given counter by the given incremental value If the counter * does not exist, one is created with value 0. * * @param name * the counter name * @param inc * the incremental value * @return the updated value. */ protected Double addDoubleValue(Object name, double inc) { Double val =...
3.26
hadoop_JobBase_configure_rdh
/** * Initializes a new instance from a {@link JobConf}. * * @param job * the configuration */ public void configure(JobConf job) { this.longCounters = new TreeMap<Object, Long>(); this.doubleCounters = new TreeMap<Object, Double>(); }
3.26
hadoop_JobBase_addLongValue_rdh
/** * Increment the given counter by the given incremental value If the counter * does not exist, one is created with value 0. * * @param name * the counter name * @param inc * the incremental value * @return the updated value. */ protected Long addLongValue(Object name, long inc) { Long val = this.lon...
3.26
hadoop_JobBase_setDoubleValue_rdh
/** * Set the given counter to the given value * * @param name * the counter name * @param value * the value for the counter */ protected void setDoubleValue(Object name, double value) { this.doubleCounters.put(name, new Double(value)); }
3.26
hadoop_JobBase_getReport_rdh
/** * log the counters */ protected String getReport() {StringBuffer v4 = new StringBuffer(); Iterator iter = this.longCounters.entrySet().iterator(); while (iter.hasNext()) {Entry e = ((Entry) (iter.next()));v4.append(e.getKey().toString()).append("\t").append(e.getValue()).append("\n"); } iter =...
3.26
hadoop_JobBase_report_rdh
/** * log the counters */ protected void report() { LOG.info(getReport()); }
3.26
hadoop_JobBase_getLongValue_rdh
/** * * @param name * the counter name * @return return the value of the given counter. */ protected Long getLongValue(Object name) { return this.longCounters.get(name); }
3.26
hadoop_OSSListRequest_v2_rdh
/** * Restricted constructors to ensure v1 or v2, not both. * * @param request * v2 request * @return new list request container */ public static OSSListRequest v2(ListObjectsV2Request request) { return new OSSListRequest(null, request); }
3.26
hadoop_OSSListRequest_isV1_rdh
/** * Is this a v1 API request or v2? * * @return true if v1, false if v2 */ public boolean isV1() { return v1Request != null; }
3.26
hadoop_FTPInputStream_markSupported_rdh
// Not supported. @Override public boolean markSupported() { return false; }
3.26
hadoop_FTPInputStream_seek_rdh
// We don't support seek. @Override public void seek(long pos) throws IOException { throw new IOException("Seek not supported"); }
3.26
hadoop_GlobExpander_expandLeftmost_rdh
/** * Expand the leftmost outer curly bracket pair containing a * slash character ("/") in <code>filePattern</code>. * * @param filePatternWithOffset * @return expanded file patterns * @throws IOException */ private static List<StringWithOff...
3.26
hadoop_GlobExpander_expand_rdh
/** * Expand globs in the given <code>filePattern</code> into a collection of * file patterns so that in the expanded set no file pattern has a slash * character ("/") in a curly bracket pair. * <p> * Some examples of how the filePattern is expanded:<br> * <pre> * <b> * filePattern - Expanded file patte...
3.26
hadoop_VolumeFailureSummary_getLastVolumeFailureDate_rdh
/** * Returns the date/time of the last volume failure in milliseconds since * epoch. * * @return date/time of last volume failure in milliseconds since epoch */ public long getLastVolumeFailureDate() { return this.lastVolumeFailureDate; }
3.26
hadoop_VolumeFailureSummary_getFailedStorageLocations_rdh
/** * Returns each storage location that has failed, sorted. * * @return each storage location that has failed, sorted */public String[] getFailedStorageLocations() { return this.failedStorageLocations; }
3.26
hadoop_VolumeFailureSummary_getEstimatedCapacityLostTotal_rdh
/** * Returns estimate of capacity lost. This is said to be an estimate, because * in some cases it's impossible to know the capacity of the volume, such as if * we never had a chance to query its capacity before the failure occurred. * * @return estimate of capacity lost in bytes */ public long getEstimatedCapa...
3.26
hadoop_Paths_getRelativePath_rdh
/** * Using {@code URI#relativize()}, build the relative path from the * base path to the full path. * If {@code childPath} is not a child of {@code basePath} the outcome * os undefined. * * @param basePath * base path * @param fullPath * full path under the base path. * @return the relative path */publi...
3.26
hadoop_Paths_getPartitions_rdh
/** * Get the set of partitions from the list of files being staged. * This is all immediate parents of those files. If a file is in the root * dir, the partition is declared to be * {@link StagingCommitterConstants#TABLE_ROOT}. * * @param attemptPath * path for the attempt * @param taskOutput * list of ou...
3.26
hadoop_Paths_getPartition_rdh
/** * Returns the partition of a relative file path, or null if the path is a * file name with no relative directory. * * @param relative * a relative file path * @return the partition of the relative file path */ protected static String getPartition(String relative) { return getParent(relative); }
3.26
hadoop_Paths_getStagingUploadsParentDirectory_rdh
/** * Build a qualified parent path for the temporary multipart upload commit * directory built by {@link #getMultipartUploadCommitsDirectory(Configuration, String)}. * * @param conf * configuration defining default FS. * @param uuid * uuid of job * @return a path which can be used for temporary work * @th...
3.26
hadoop_Paths_path_rdh
/** * Varags constructor of paths. Not very efficient. * * @param parent * parent path * @param child * child entries. "" elements are skipped. * @return the full child path. */ public static Path path(Path parent, String... child) { Path p = parent; for (String c : child) { if (!c.isEmp...
3.26
hadoop_Paths_getLocalTaskAttemptTempDir_rdh
/** * Get the task attempt temporary directory in the local filesystem. * This must be unique to all tasks on all jobs running on all processes * on this host. * It's constructed as uuid+task-attempt-ID, relying on UUID to be unique * for each job. * * @param conf * configuration * @param uuid * some UUID...
3.26