Package org.apache.flink.core.fs
Interface RecoverableFsDataOutputStream.Committer
-
- Enclosing class:
- RecoverableFsDataOutputStream
public static interface RecoverableFsDataOutputStream.CommitterA committer can publish the file of a stream that was closed. The Committer can be recovered via aRecoverableWriter.CommitRecoverable.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidcommit()Commits the file, making it visible.voidcommitAfterRecovery()Commits the file, making it visible.RecoverableWriter.CommitRecoverablegetRecoverable()Gets a recoverable object to recover the committer.
-
-
-
Method Detail
-
commit
void commit() throws IOExceptionCommits the file, making it visible. The file will contain the exact data as when the committer was created.- Throws:
IOException- Thrown if committing fails.
-
commitAfterRecovery
void commitAfterRecovery() throws IOExceptionCommits the file, making it visible. The file will contain the exact data as when the committer was created.This method tolerates situations where the file was already committed and will not raise an exception in that case. This is important for idempotent commit retries as they need to happen after recovery.
- Throws:
IOException- Thrown if committing fails.
-
getRecoverable
RecoverableWriter.CommitRecoverable getRecoverable()
Gets a recoverable object to recover the committer. The recovered committer will commit the file with the exact same data as this committer would commit it.
-
-