Delen via


ConsistencyLevel Enum

  • java.lang.Object
    • java.lang.Enum
      • com.microsoft.azure.documentdb.ConsistencyLevel

public enum ConsistencyLevel
extends java.lang.Enum<ConsistencyLevel>

Represents the consistency levels supported for Azure Cosmos DB client operations in the Azure Cosmos DB database service.

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.

Fields

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.

Methods inherited from java.lang.Enum

java.lang.Enum.<T>valueOf java.lang.Enum.clone java.lang.Enum.compareTo java.lang.Enum.describeConstable java.lang.Enum.equals java.lang.Enum.finalize java.lang.Enum.getDeclaringClass java.lang.Enum.hashCode java.lang.Enum.name java.lang.Enum.ordinal java.lang.Enum.toString

Methods inherited from java.lang.Object

java.lang.Object.getClass java.lang.Object.notify java.lang.Object.notifyAll java.lang.Object.wait java.lang.Object.wait java.lang.Object.wait

Methods

valueOf(String name)

public static ConsistencyLevel valueOf(String name)

Parameters

name
java.lang.String

Returns

values()

public static ConsistencyLevel[] values()

Returns

Applies to