org.infinispan.remoting
Interface ReplicationQueue

All Superinterfaces:
Lifecycle
All Known Implementing Classes:
ReplicationQueueImpl

public interface ReplicationQueue
extends Lifecycle

Periodically (or when certain size is exceeded) takes elements and replicates them.

Since:
4.0
Author:
Bela Ban, Mircea.Markus@jboss.com

Method Summary
 void add(ReplicableCommand job)
          Adds a new command to the replication queue.
 void flush()
          Flushes existing jobs in the replication queue.
 int getElementsCount()
           
 boolean isEnabled()
           
 void reset()
          Resets the replication queue, typically used when a cache is restarted.
 
Methods inherited from interface org.infinispan.lifecycle.Lifecycle
start, stop
 

Method Detail

isEnabled

boolean isEnabled()
Returns:
true if this replication queue is enabled, false otherwise.

add

void add(ReplicableCommand job)
Adds a new command to the replication queue.

Parameters:
job - command to add to the queue

flush

void flush()
Flushes existing jobs in the replication queue.


getElementsCount

int getElementsCount()
Returns:
the number of elements in the replication queue.

reset

void reset()
Resets the replication queue, typically used when a cache is restarted.


Google Analytics

Copyright © 2010 JBoss, a division of Red Hat. All Rights Reserved.