|
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.FieldPartitioningPolicy org.eclipse.persistence.descriptors.partitioning.RangePartitioningPolicy
public class RangePartitioningPolicy
PUBLIC: RangePartitioningPolicy partitions access to a database cluster by a field value from the object, such as the object's id, location, or tenant. Each server is assigned a range of values. All write or read request for object's with that value are sent to the server. If a query does not include the field as a parameter, then it can either be sent to all server's and unioned, or left to the sesion's default behavior.
Field Summary | |
---|---|
protected java.util.List<RangePartition> |
partitions
|
Fields inherited from class org.eclipse.persistence.descriptors.partitioning.FieldPartitioningPolicy |
---|
partitionField, unionUnpartitionableQueries |
Fields inherited from class org.eclipse.persistence.descriptors.partitioning.PartitioningPolicy |
---|
name |
Constructor Summary | |
---|---|
RangePartitioningPolicy()
|
|
RangePartitioningPolicy(java.lang.String partitionField)
|
|
RangePartitioningPolicy(java.lang.String partitionField,
boolean unionUnpartitionableQueries)
|
|
RangePartitioningPolicy(java.lang.String partitionField,
RangePartition... partitions)
|
Method Summary | |
---|---|
void |
addPartition(RangePartition partition)
PUBLIC: Add the range partition. |
void |
addPartition(java.lang.String connectionPool,
java.lang.Comparable startValue,
java.lang.Comparable endValue)
PUBLIC: Add the range partition. |
void |
convertClassNamesToClasses(java.lang.ClassLoader classLoader)
INTERNAL: Convert all the class-name-based settings to actual class-based settings. |
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 one of the pools in a round robin rotation fashion. |
java.util.List<RangePartition> |
getPartitions()
PUBLIC: Return the range partitions. |
void |
partitionPersist(org.eclipse.persistence.internal.sessions.AbstractSession session,
java.lang.Object object,
ClassDescriptor descriptor)
INTERNAL: Allow for the persist call to assign the partition. |
void |
setPartitions(java.util.List<RangePartition> partitions)
PUBLIC: Set the range partitions. |
Methods inherited from class org.eclipse.persistence.descriptors.partitioning.FieldPartitioningPolicy |
---|
extractPartitionValueForPersist, getPartitionField, getPartitionFieldName, getUnionUnpartitionableQueries, setPartitionField, setPartitionField, setUnionUnpartitionableQueries |
Methods inherited from class org.eclipse.persistence.descriptors.partitioning.PartitioningPolicy |
---|
acquireAccessor, getAccessor, getName, initialize, 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<RangePartition> partitions
Constructor Detail |
---|
public RangePartitioningPolicy()
public RangePartitioningPolicy(java.lang.String partitionField)
public RangePartitioningPolicy(java.lang.String partitionField, boolean unionUnpartitionableQueries)
public RangePartitioningPolicy(java.lang.String partitionField, RangePartition... partitions)
Method Detail |
---|
public void convertClassNamesToClasses(java.lang.ClassLoader classLoader)
convertClassNamesToClasses
in class PartitioningPolicy
public java.util.List<RangePartition> getPartitions()
public void setPartitions(java.util.List<RangePartition> partitions)
public void addPartition(java.lang.String connectionPool, java.lang.Comparable startValue, java.lang.Comparable endValue)
public void addPartition(RangePartition partition)
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
public void partitionPersist(org.eclipse.persistence.internal.sessions.AbstractSession session, java.lang.Object object, ClassDescriptor descriptor)
partitionPersist
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 |