|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.continuent.tungsten.replicator.storage.parallel.ParallelQueueApplier
public class ParallelQueueApplier
Implements Applier interface for a parallel queue.
| Constructor Summary | |
|---|---|
ParallelQueueApplier()
Instantiate the adapter. |
|
| Method Summary | |
|---|---|
void |
apply(ReplDBMSEvent event,
boolean doCommit,
boolean doRollback,
boolean syncTHL)
Apply the proffered event to the replication target. |
void |
commit()
This method is meaningless for an in-memory queue, which is non-transactional. |
void |
configure(PluginContext context)
Complete plug-in configuration. |
ReplDBMSHeader |
getLastEvent()
Return the minimum header across all queues to ensure we do not miss events on restart. |
java.lang.String |
getStoreName()
|
void |
prepare(PluginContext context)
Connect to underlying queue. |
void |
release(PluginContext context)
Release all resources used by plug-in. |
void |
rollback()
This method is meaningless for an in-memory queue, which is non-transactional. |
void |
setStoreName(java.lang.String storeName)
|
void |
setTaskId(int id)
Sets the ID of the task using this applier. |
void |
updatePosition(ReplDBMSHeader header,
boolean doCommit,
boolean syncTHL)
Update current recovery position but do not apply an event. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ParallelQueueApplier()
| Method Detail |
|---|
public java.lang.String getStoreName()
public void setStoreName(java.lang.String storeName)
public void configure(PluginContext context)
throws ReplicatorException
configure in interface ReplicatorPluginReplicatorException - Thrown if configuration is incomplete or
failsReplicatorPlugin.configure(com.continuent.tungsten.replicator.plugin.PluginContext)
public void prepare(PluginContext context)
throws ReplicatorException
prepare in interface ReplicatorPluginReplicatorException - Thrown if resource allocation failsReplicatorPlugin.prepare(com.continuent.tungsten.replicator.plugin.PluginContext)
public void release(PluginContext context)
throws ReplicatorException
release in interface ReplicatorPluginReplicatorException - Thrown if resource deallocation failsReplicatorPlugin.release(com.continuent.tungsten.replicator.plugin.PluginContext)
public void apply(ReplDBMSEvent event,
boolean doCommit,
boolean doRollback,
boolean syncTHL)
throws ReplicatorException,
ConsistencyException,
java.lang.InterruptedException
apply in interface Applierevent - Event to be applieddoCommit - Boolean flag indicating whether this is the last part of
multipart eventdoRollback - Boolean flag indicating whether this transaction should
rollbacksyncTHL - Should this applier synchronize the trep_commit_seqno
table? This should be false for slave.
ReplicatorException - Thrown if applier processing fails
ConsistencyException - Thrown if the applier detects that a
consistency check has failed
java.lang.InterruptedException - Thrown if the applier is interruptedApplier.apply(com.continuent.tungsten.replicator.event.ReplDBMSEvent,
boolean, boolean, boolean)
public void updatePosition(ReplDBMSHeader header,
boolean doCommit,
boolean syncTHL)
throws ReplicatorException,
java.lang.InterruptedException
updatePosition in interface Applierheader - Header containing seqno, event ID, etc.doCommit - Boolean flag indicating whether this is the last part of
multipart eventsyncTHL - Should this applier synchronize the trep_commit_seqno
table? This should be false for slave.
ReplicatorException - Thrown if applier processing fails
java.lang.InterruptedException - Thrown if the applier is interruptedApplier.updatePosition(com.continuent.tungsten.replicator.event.ReplDBMSHeader,
boolean, boolean)
public void commit()
throws ReplicatorException,
java.lang.InterruptedException
commit in interface ApplierReplicatorException - Thrown if applier processing fails
java.lang.InterruptedException - Thrown if the applier is interruptedApplier.commit()
public void rollback()
throws java.lang.InterruptedException
rollback in interface Applierjava.lang.InterruptedExceptionApplier.rollback()
public ReplDBMSHeader getLastEvent()
throws ReplicatorException,
java.lang.InterruptedException
getLastEvent in interface ApplierReplicatorException - Thrown if getting sequence number fails
java.lang.InterruptedException - Thrown if the applier is interruptedApplier.getLastEvent()public void setTaskId(int id)
setTaskId in interface ParallelApplierid - Task IDParallelApplier.setTaskId(int)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||