@PublicEvolving public interface RollingPolicy<IN,BucketID> extends Serializable
Bucket
in the Filesystem Sink
rolls its currently
open part file and opens a new one.Modifier and Type | Method and Description |
---|---|
boolean |
shouldRollOnCheckpoint(PartFileInfo<BucketID> partFileState)
Determines if the in-progress part file for a bucket should roll on every checkpoint.
|
boolean |
shouldRollOnEvent(PartFileInfo<BucketID> partFileState,
IN element)
Determines if the in-progress part file for a bucket should roll based on its current state,
e.g.
|
boolean |
shouldRollOnProcessingTime(PartFileInfo<BucketID> partFileState,
long currentTime)
Determines if the in-progress part file for a bucket should roll based on a time condition.
|
boolean shouldRollOnCheckpoint(PartFileInfo<BucketID> partFileState) throws IOException
partFileState
- the state of the currently open part file of the bucket.True
if the part file should roll, false
otherwise.IOException
boolean shouldRollOnEvent(PartFileInfo<BucketID> partFileState, IN element) throws IOException
element
- the element being processed.partFileState
- the state of the currently open part file of the bucket.True
if the part file should roll, false
otherwise.IOException
boolean shouldRollOnProcessingTime(PartFileInfo<BucketID> partFileState, long currentTime) throws IOException
partFileState
- the state of the currently open part file of the bucket.currentTime
- the current processing time.True
if the part file should roll, false
otherwise.IOException
Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.