public class ConsistencyPolicy extends Object
Constructor and Description |
---|
ConsistencyPolicy() |
Modifier and Type | Method and Description |
---|---|
DefaultConsistencyLevel |
defaultConsistencyLevel()
Get the default consistency level and configuration settings of the Cosmos DB account.
|
Integer |
maxIntervalInSeconds()
Get when used with the Bounded Staleness consistency level, this value represents the time amount of staleness (in seconds) tolerated.
|
Long |
maxStalenessPrefix()
Get when used with the Bounded Staleness consistency level, this value represents the number of stale requests tolerated.
|
ConsistencyPolicy |
withDefaultConsistencyLevel(DefaultConsistencyLevel defaultConsistencyLevel)
Set the default consistency level and configuration settings of the Cosmos DB account.
|
ConsistencyPolicy |
withMaxIntervalInSeconds(Integer maxIntervalInSeconds)
Set when used with the Bounded Staleness consistency level, this value represents the time amount of staleness (in seconds) tolerated.
|
ConsistencyPolicy |
withMaxStalenessPrefix(Long maxStalenessPrefix)
Set when used with the Bounded Staleness consistency level, this value represents the number of stale requests tolerated.
|
public DefaultConsistencyLevel defaultConsistencyLevel()
public ConsistencyPolicy withDefaultConsistencyLevel(DefaultConsistencyLevel defaultConsistencyLevel)
defaultConsistencyLevel
- the defaultConsistencyLevel value to setpublic Long maxStalenessPrefix()
public ConsistencyPolicy withMaxStalenessPrefix(Long maxStalenessPrefix)
maxStalenessPrefix
- the maxStalenessPrefix value to setpublic Integer maxIntervalInSeconds()
public ConsistencyPolicy withMaxIntervalInSeconds(Integer maxIntervalInSeconds)
maxIntervalInSeconds
- the maxIntervalInSeconds value to setCopyright © 2019. All rights reserved.