|
EclipseLink 2.4.2, build 'v20130514-5956486' API Reference | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.persistence.descriptors.partitioning.PartitioningPolicy org.eclipse.persistence.descriptors.partitioning.ReplicationPartitioningPolicy
public class ReplicationPartitioningPolicy
PUBLIC: ReplicationPartitioningPolicy sends requests to a set of connection pools. It is for replicating data across a cluster of database machines. Only modification queries are replicated.
Field Summary | |
---|---|
protected java.util.List<java.lang.String> |
connectionPools
|
Fields inherited from class org.eclipse.persistence.descriptors.partitioning.PartitioningPolicy |
---|
name |
Constructor Summary | |
---|---|
ReplicationPartitioningPolicy()
|
|
ReplicationPartitioningPolicy(java.util.List<java.lang.String> pools)
|
|
ReplicationPartitioningPolicy(java.lang.String... pools)
|
Method Summary | |
---|---|
void |
addConnectionPool(java.lang.String connectionPool)
PUBLIC: Add the connection pool name to the list of pools to rotate queries through. |
java.util.List<java.lang.String> |
getConnectionPools()
PUBLIC: Return the list of connection pool names to replicate queries to. |
java.util.List<org.eclipse.persistence.internal.databaseaccess.Accessor> |
getConnectionsForQuery(org.eclipse.persistence.internal.sessions.AbstractSession session,
DatabaseQuery query,
org.eclipse.persistence.internal.sessions.AbstractRecord arguments)
INTERNAL: Get a connection from each pool. |
void |
initialize(org.eclipse.persistence.internal.sessions.AbstractSession session)
INTERNAL: Default the connection pools to all pools if unset. |
void |
setConnectionPools(java.util.List<java.lang.String> connectionPools)
PUBLIC: Set the list of connection pool names to replicate queries to. |
Methods inherited from class org.eclipse.persistence.descriptors.partitioning.PartitioningPolicy |
---|
acquireAccessor, convertClassNamesToClasses, getAccessor, getName, partitionPersist, setName |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected java.util.List<java.lang.String> connectionPools
Constructor Detail |
---|
public ReplicationPartitioningPolicy()
public ReplicationPartitioningPolicy(java.lang.String... pools)
public ReplicationPartitioningPolicy(java.util.List<java.lang.String> pools)
Method Detail |
---|
public void initialize(org.eclipse.persistence.internal.sessions.AbstractSession session)
initialize
in class PartitioningPolicy
public java.util.List<java.lang.String> getConnectionPools()
public void setConnectionPools(java.util.List<java.lang.String> connectionPools)
public void addConnectionPool(java.lang.String connectionPool)
public java.util.List<org.eclipse.persistence.internal.databaseaccess.Accessor> getConnectionsForQuery(org.eclipse.persistence.internal.sessions.AbstractSession session, DatabaseQuery query, org.eclipse.persistence.internal.sessions.AbstractRecord arguments)
getConnectionsForQuery
in class PartitioningPolicy
|
EclipseLink 2.4.2, build 'v20130514-5956486' API Reference | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |