Package org.apache.storm.hdfs.trident
Class HdfsState.HdfsFileOptions
java.lang.Object
org.apache.storm.hdfs.trident.HdfsState.Options
org.apache.storm.hdfs.trident.HdfsState.HdfsFileOptions
- All Implemented Interfaces:
Serializable
- Enclosing class:
- HdfsState
- See Also:
-
Field Summary
Fields inherited from class org.apache.storm.hdfs.trident.HdfsState.Options
configKey, fileNameFormat, fs, fsUrl, hdfsConfig, rotation, rotationActions, rotationPolicy
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddRotationAction
(RotationAction action) Deprecated.void
void
execute
(List<TridentTuple> tuples) long
withBufferSize
(int sizeInBytes) Set the size of the buffer used for hdfs file copy in case of recovery.withConfigKey
(String configKey) withFileNameFormat
(FileNameFormat fileNameFormat) withRecordFormat
(RecordFormat format) withRotationPolicy
(FileRotationPolicy rotationPolicy) Methods inherited from class org.apache.storm.hdfs.trident.HdfsState.Options
rotateOutputFile, rotateOutputFile
-
Field Details
-
format
-
-
Constructor Details
-
HdfsFileOptions
public HdfsFileOptions()
-
-
Method Details
-
withFsUrl
-
withConfigKey
-
withFileNameFormat
-
withRecordFormat
-
withRotationPolicy
-
withBufferSize
Set the size of the buffer used for hdfs file copy in case of recovery. The default value is 131072.
Note: The lower limit for the parameter is 4096, below which the option is ignored.
- Parameters:
sizeInBytes
- the buffer size in bytes- Returns:
HdfsState.HdfsFileOptions
-
addRotationAction
Deprecated. -
getCurrentOffset
public long getCurrentOffset() -
doCommit
- Throws:
IOException
-
execute
- Throws:
IOException
-