@InterfaceAudience.Private public class MagicCommitTracker extends PutTracker
Important
: must not directly or indirectly import a class which uses any datatype in hadoop-mapreduce.| Modifier and Type | Field and Description |
|---|---|
static org.slf4j.Logger |
LOG |
| Constructor and Description |
|---|
MagicCommitTracker(org.apache.hadoop.fs.Path path,
String bucket,
String originalDestKey,
String destKey,
String pendingsetKey,
WriteOperationHelper writer)
Magic commit tracker.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
aboutToComplete(String uploadId,
List<com.amazonaws.services.s3.model.PartETag> parts,
long bytesWritten)
Complete operation: generate the final commit data, put it.
|
boolean |
initialize()
Initialize the tracker.
|
boolean |
outputImmediatelyVisible()
Flag to indicate that output is not visible after the stream
is closed.
|
String |
toString() |
getDestKeypublic MagicCommitTracker(org.apache.hadoop.fs.Path path,
String bucket,
String originalDestKey,
String destKey,
String pendingsetKey,
WriteOperationHelper writer)
path - path nominally being written tobucket - dest bucketoriginalDestKey - the original key, in the magic directory.destKey - key for the destinationpendingsetKey - key of the pendingset filewriter - writer instance to use for operationspublic boolean initialize()
throws IOException
initialize in class PutTrackerIOException - any IO problem.public boolean outputImmediatelyVisible()
outputImmediatelyVisible in class PutTrackerpublic boolean aboutToComplete(String uploadId, List<com.amazonaws.services.s3.model.PartETag> parts, long bytesWritten) throws IOException
aboutToComplete in class PutTrackeruploadId - Upload IDparts - list of partsbytesWritten - bytes writtenIOException - any IO problem.IllegalArgumentException - bad argumentpublic String toString()
toString in class PutTrackerCopyright © 2008–2021 Apache Software Foundation. All rights reserved.