T
- type of transaction identifierK
- type of the actual journal entry which must extend JournalEntry
public abstract class AbstractQueueTransactionJournal<T,K extends JournalEntry<T>> extends Object
Constructor and Description |
---|
AbstractQueueTransactionJournal(String logFilesDirectory,
JournalEntrySerializer journalEntrySerializer,
Integer maximumFileSizeInMegabytes) |
Modifier and Type | Method and Description |
---|---|
void |
clear() |
void |
close() |
protected abstract K |
createCheckpointJournalEntry(T txId,
byte operation)
Creates a checkpoint
JournalEntry . |
protected abstract K |
createUpdateJournalEntry(T txId,
byte operation,
String queueName,
Serializable serialize)
Creates a
JournalEntry for an update operation in the queue. |
com.google.common.collect.Multimap<T,K> |
getAllLogEntries() |
protected TransactionJournal<T,K> |
getJournal() |
Collection<K> |
getLogEntriesForTx(T txId) |
void |
logAdd(T txId,
QueueStore queue,
Serializable value) |
void |
logAddFirst(T txId,
QueueStore queue,
Serializable item) |
void |
logCommit(T txId) |
void |
logRemove(T txId,
QueueStore queue,
Serializable value) |
void |
logRollback(T txId) |
protected transient Log logger
public AbstractQueueTransactionJournal(String logFilesDirectory, JournalEntrySerializer journalEntrySerializer, Integer maximumFileSizeInMegabytes)
public void logAdd(T txId, QueueStore queue, Serializable value)
public void logAddFirst(T txId, QueueStore queue, Serializable item)
public void logRemove(T txId, QueueStore queue, Serializable value)
public void logCommit(T txId)
protected abstract K createUpdateJournalEntry(T txId, byte operation, String queueName, Serializable serialize)
JournalEntry
for an update operation in the queue.txId
- transaction identifieroperation
- operation done over the queuequeueName
- queueName of the queue in which the operation has been doneserialize
- value of the operationJournalEntry
protected abstract K createCheckpointJournalEntry(T txId, byte operation)
JournalEntry
.txId
- transaction identifieroperation
- checkpoint operationJournalEntry
public void logRollback(T txId)
public void close()
public void clear()
public Collection<K> getLogEntriesForTx(T txId)
protected TransactionJournal<T,K> getJournal()
Copyright © 2003–2016 MuleSoft, Inc.. All rights reserved.