public enum ConsistencyLevel extends Enum<ConsistencyLevel>
The requested ConsistencyLevel must match or be weaker than that provisioned for the database account. Consistency levels by order of strength are Strong, BoundedStaleness, Session and Eventual.
Enum Constant and Description |
---|
BoundedStaleness
Bounded Staleness guarantees that reads are not too out-of-date.
|
ConsistentPrefix
ConsistentPrefix Consistency guarantees that reads will return some prefix of all writes with no gaps.
|
Eventual
Eventual Consistency guarantees that reads will return a subset of writes.
|
Session
Session Consistency guarantees monotonic reads (you never read old data, then new, then old again), monotonic
writes (writes are ordered) and read your writes (your writes are immediately visible to your reads) within
any single session.
|
Strong
Strong Consistency guarantees that read operations always return the value that was last written.
|
Modifier and Type | Method and Description |
---|---|
static ConsistencyLevel |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static ConsistencyLevel[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final ConsistencyLevel Strong
public static final ConsistencyLevel BoundedStaleness
public static final ConsistencyLevel Session
public static final ConsistencyLevel Eventual
public static final ConsistencyLevel ConsistentPrefix
public static ConsistencyLevel[] values()
for (ConsistencyLevel c : ConsistencyLevel.values()) System.out.println(c);
public static ConsistencyLevel valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullCopyright © 2018. All rights reserved.