- All Implemented Interfaces:
- JournalContext, Closeable, AutoCloseable, java.util.function.Supplier<JournalContext>
@NotThreadSafe
public final class MergeJournalContext
extends Object
implements JournalContext
Context for merging journal entries together for a wrapped journal context.
This is used so that we can combine several journal entries into one using a merge
function. This prevents partial writes of these journal entries causing system to
be left in an inconsistent state. For example, createFile without completing the file.
Note that these journal entries are not persisted and they will only be persisted
when close is called on them. Closing the MergeJournalContext will also not close
the enclosed journal context.