Package | Description |
---|---|
com.datastax.driver.core |
The main package for the DataStax Java driver for Cassandra.
|
com.datastax.driver.core.exceptions |
Exceptions thrown by the DataStax Java driver for Cassandra.
|
com.datastax.driver.core.policies |
Policies that allow to control some of the behavior of the DataStax Java driver for Cassandra.
|
Modifier and Type | Field and Description |
---|---|
static ConsistencyLevel |
QueryOptions.DEFAULT_CONSISTENCY_LEVEL
The default consistency level for queries:
LOCAL_ONE . |
static ConsistencyLevel |
QueryOptions.DEFAULT_SERIAL_CONSISTENCY_LEVEL
The default serial consistency level for conditional updates:
SERIAL . |
Modifier and Type | Method and Description |
---|---|
ConsistencyLevel |
ExecutionInfo.getAchievedConsistencyLevel()
If the query returned without achieving the requested consistency level due to the
RetryPolicy , this return the biggest consistency level that
has been actually achieved by the query. |
ConsistencyLevel |
DefaultPreparedStatement.getConsistencyLevel() |
ConsistencyLevel |
QueryOptions.getConsistencyLevel()
The default consistency level used by queries.
|
ConsistencyLevel |
StatementWrapper.getConsistencyLevel() |
ConsistencyLevel |
Statement.getConsistencyLevel()
The consistency level for this query.
|
ConsistencyLevel |
PreparedStatement.getConsistencyLevel()
Returns the default consistency level set through
PreparedStatement.setConsistencyLevel(com.datastax.driver.core.ConsistencyLevel) . |
ConsistencyLevel |
DefaultPreparedStatement.getSerialConsistencyLevel() |
ConsistencyLevel |
QueryOptions.getSerialConsistencyLevel()
The default serial consistency level used by queries.
|
ConsistencyLevel |
StatementWrapper.getSerialConsistencyLevel() |
ConsistencyLevel |
Statement.getSerialConsistencyLevel()
The serial consistency level for this query.
|
ConsistencyLevel |
PreparedStatement.getSerialConsistencyLevel()
Returns the default serial consistency level set through
PreparedStatement.setSerialConsistencyLevel(com.datastax.driver.core.ConsistencyLevel) . |
static ConsistencyLevel |
ConsistencyLevel.valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static ConsistencyLevel[] |
ConsistencyLevel.values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
Modifier and Type | Method and Description |
---|---|
PreparedStatement |
DefaultPreparedStatement.setConsistencyLevel(ConsistencyLevel consistency) |
QueryOptions |
QueryOptions.setConsistencyLevel(ConsistencyLevel consistencyLevel)
Sets the default consistency level to use for queries.
|
Statement |
StatementWrapper.setConsistencyLevel(ConsistencyLevel consistency) |
Statement |
Statement.setConsistencyLevel(ConsistencyLevel consistency)
Sets the consistency level for the query.
|
PreparedStatement |
PreparedStatement.setConsistencyLevel(ConsistencyLevel consistency)
Sets a default consistency level for all bound statements created from this prepared statement.
|
PreparedStatement |
DefaultPreparedStatement.setSerialConsistencyLevel(ConsistencyLevel serialConsistency) |
QueryOptions |
QueryOptions.setSerialConsistencyLevel(ConsistencyLevel serialConsistencyLevel)
Sets the default serial consistency level to use for queries.
|
Statement |
StatementWrapper.setSerialConsistencyLevel(ConsistencyLevel serialConsistency) |
BatchStatement |
BatchStatement.setSerialConsistencyLevel(ConsistencyLevel serialConsistency)
Sets the serial consistency level for the query.
|
Statement |
Statement.setSerialConsistencyLevel(ConsistencyLevel serialConsistency)
Sets the serial consistency level for the query.
|
PreparedStatement |
PreparedStatement.setSerialConsistencyLevel(ConsistencyLevel serialConsistency)
Sets a default serial consistency level for all bound statements created from this prepared
statement.
|
Constructor and Description |
---|
ExecutionInfo(int speculativeExecutions,
int successfulExecutionIndex,
List<Host> triedHosts,
ConsistencyLevel achievedConsistency,
Map<String,ByteBuffer> customPayload) |
Modifier and Type | Method and Description |
---|---|
ConsistencyLevel |
QueryConsistencyException.getConsistencyLevel()
The consistency level of the operation that failed.
|
ConsistencyLevel |
UnavailableException.getConsistencyLevel()
The consistency level of the operation triggering this unavailable exception.
|
Constructor and Description |
---|
QueryConsistencyException(InetSocketAddress address,
String msg,
ConsistencyLevel consistency,
int received,
int required) |
QueryConsistencyException(InetSocketAddress address,
String msg,
Throwable cause,
ConsistencyLevel consistency,
int received,
int required) |
ReadFailureException(ConsistencyLevel consistency,
int received,
int required,
int failed,
boolean dataPresent)
Deprecated.
Legacy constructor for backward compatibility.
|
ReadFailureException(ConsistencyLevel consistency,
int received,
int required,
int failed,
Map<InetAddress,Integer> failuresMap,
boolean dataPresent)
This constructor should only be used internally by the driver when decoding error responses.
|
ReadFailureException(InetSocketAddress address,
ConsistencyLevel consistency,
int received,
int required,
int failed,
boolean dataPresent)
Deprecated.
Legacy constructor for backward compatibility.
|
ReadFailureException(InetSocketAddress address,
ConsistencyLevel consistency,
int received,
int required,
int failed,
Map<InetAddress,Integer> failuresMap,
boolean dataPresent) |
ReadTimeoutException(ConsistencyLevel consistency,
int received,
int required,
boolean dataPresent)
This constructor should only be used internally by the driver when decoding error responses.
|
ReadTimeoutException(InetSocketAddress address,
ConsistencyLevel consistency,
int received,
int required,
boolean dataPresent) |
UnavailableException(ConsistencyLevel consistency,
int required,
int alive)
This constructor should only be used internally by the driver when decoding error responses.
|
UnavailableException(InetSocketAddress address,
ConsistencyLevel consistency,
int required,
int alive) |
WriteFailureException(ConsistencyLevel consistency,
WriteType writeType,
int received,
int required,
int failed)
Deprecated.
Legacy constructor for backward compatibility.
|
WriteFailureException(ConsistencyLevel consistency,
WriteType writeType,
int received,
int required,
int failed,
Map<InetAddress,Integer> failuresMap)
This constructor should only be used internally by the driver when decoding error responses.
|
WriteFailureException(InetSocketAddress address,
ConsistencyLevel consistency,
WriteType writeType,
int received,
int required,
int failed)
Deprecated.
Legacy constructor for backward compatibility.
|
WriteFailureException(InetSocketAddress address,
ConsistencyLevel consistency,
WriteType writeType,
int received,
int required,
int failed,
Map<InetAddress,Integer> failuresMap) |
WriteTimeoutException(ConsistencyLevel consistency,
WriteType writeType,
int received,
int required)
This constructor should only be used internally by the driver when decoding error responses.
|
WriteTimeoutException(InetSocketAddress address,
ConsistencyLevel consistency,
WriteType writeType,
int received,
int required) |
Modifier and Type | Method and Description |
---|---|
ConsistencyLevel |
RetryPolicy.RetryDecision.getRetryConsistencyLevel()
The consistency level for this retry decision.
|
Modifier and Type | Method and Description |
---|---|
RetryPolicy.RetryDecision |
IdempotenceAwareRetryPolicy.onReadTimeout(Statement statement,
ConsistencyLevel cl,
int requiredResponses,
int receivedResponses,
boolean dataRetrieved,
int nbRetry)
Deprecated.
|
RetryPolicy.RetryDecision |
RetryPolicy.onReadTimeout(Statement statement,
ConsistencyLevel cl,
int requiredResponses,
int receivedResponses,
boolean dataRetrieved,
int nbRetry)
Defines whether to retry and at which consistency level on a read timeout.
|
RetryPolicy.RetryDecision |
LoggingRetryPolicy.onReadTimeout(Statement statement,
ConsistencyLevel cl,
int requiredResponses,
int receivedResponses,
boolean dataRetrieved,
int nbRetry) |
RetryPolicy.RetryDecision |
DefaultRetryPolicy.onReadTimeout(Statement statement,
ConsistencyLevel cl,
int requiredResponses,
int receivedResponses,
boolean dataRetrieved,
int nbRetry)
Defines whether to retry and at which consistency level on a read timeout.
|
RetryPolicy.RetryDecision |
DowngradingConsistencyRetryPolicy.onReadTimeout(Statement statement,
ConsistencyLevel cl,
int requiredResponses,
int receivedResponses,
boolean dataRetrieved,
int nbRetry)
Deprecated.
Defines whether to retry and at which consistency level on a read timeout.
|
RetryPolicy.RetryDecision |
FallthroughRetryPolicy.onReadTimeout(Statement statement,
ConsistencyLevel cl,
int requiredResponses,
int receivedResponses,
boolean dataRetrieved,
int nbRetry)
Defines whether to retry and at which consistency level on a read timeout.
|
RetryPolicy.RetryDecision |
IdempotenceAwareRetryPolicy.onRequestError(Statement statement,
ConsistencyLevel cl,
DriverException e,
int nbRetry)
Deprecated.
|
RetryPolicy.RetryDecision |
RetryPolicy.onRequestError(Statement statement,
ConsistencyLevel cl,
DriverException e,
int nbRetry)
Defines whether to retry and at which consistency level on an unexpected error.
|
RetryPolicy.RetryDecision |
LoggingRetryPolicy.onRequestError(Statement statement,
ConsistencyLevel cl,
DriverException e,
int nbRetry) |
RetryPolicy.RetryDecision |
DefaultRetryPolicy.onRequestError(Statement statement,
ConsistencyLevel cl,
DriverException e,
int nbRetry)
Defines whether to retry and at which consistency level on an unexpected error.
|
RetryPolicy.RetryDecision |
DowngradingConsistencyRetryPolicy.onRequestError(Statement statement,
ConsistencyLevel cl,
DriverException e,
int nbRetry)
Deprecated.
Defines whether to retry and at which consistency level on an unexpected error.
|
RetryPolicy.RetryDecision |
FallthroughRetryPolicy.onRequestError(Statement statement,
ConsistencyLevel cl,
DriverException e,
int nbRetry)
Defines whether to retry and at which consistency level on an unexpected error.
|
RetryPolicy.RetryDecision |
IdempotenceAwareRetryPolicy.onUnavailable(Statement statement,
ConsistencyLevel cl,
int requiredReplica,
int aliveReplica,
int nbRetry)
Deprecated.
|
RetryPolicy.RetryDecision |
RetryPolicy.onUnavailable(Statement statement,
ConsistencyLevel cl,
int requiredReplica,
int aliveReplica,
int nbRetry)
Defines whether to retry and at which consistency level on an unavailable exception.
|
RetryPolicy.RetryDecision |
LoggingRetryPolicy.onUnavailable(Statement statement,
ConsistencyLevel cl,
int requiredReplica,
int aliveReplica,
int nbRetry) |
RetryPolicy.RetryDecision |
DefaultRetryPolicy.onUnavailable(Statement statement,
ConsistencyLevel cl,
int requiredReplica,
int aliveReplica,
int nbRetry)
Defines whether to retry and at which consistency level on an unavailable exception.
|
RetryPolicy.RetryDecision |
DowngradingConsistencyRetryPolicy.onUnavailable(Statement statement,
ConsistencyLevel cl,
int requiredReplica,
int aliveReplica,
int nbRetry)
Deprecated.
Defines whether to retry and at which consistency level on an unavailable exception.
|
RetryPolicy.RetryDecision |
FallthroughRetryPolicy.onUnavailable(Statement statement,
ConsistencyLevel cl,
int requiredReplica,
int aliveReplica,
int nbRetry)
Defines whether to retry and at which consistency level on an unavailable exception.
|
RetryPolicy.RetryDecision |
IdempotenceAwareRetryPolicy.onWriteTimeout(Statement statement,
ConsistencyLevel cl,
WriteType writeType,
int requiredAcks,
int receivedAcks,
int nbRetry)
Deprecated.
|
RetryPolicy.RetryDecision |
RetryPolicy.onWriteTimeout(Statement statement,
ConsistencyLevel cl,
WriteType writeType,
int requiredAcks,
int receivedAcks,
int nbRetry)
Defines whether to retry and at which consistency level on a write timeout.
|
RetryPolicy.RetryDecision |
LoggingRetryPolicy.onWriteTimeout(Statement statement,
ConsistencyLevel cl,
WriteType writeType,
int requiredAcks,
int receivedAcks,
int nbRetry) |
RetryPolicy.RetryDecision |
DefaultRetryPolicy.onWriteTimeout(Statement statement,
ConsistencyLevel cl,
WriteType writeType,
int requiredAcks,
int receivedAcks,
int nbRetry)
Defines whether to retry and at which consistency level on a write timeout.
|
RetryPolicy.RetryDecision |
DowngradingConsistencyRetryPolicy.onWriteTimeout(Statement statement,
ConsistencyLevel cl,
WriteType writeType,
int requiredAcks,
int receivedAcks,
int nbRetry)
Deprecated.
Defines whether to retry and at which consistency level on a write timeout.
|
RetryPolicy.RetryDecision |
FallthroughRetryPolicy.onWriteTimeout(Statement statement,
ConsistencyLevel cl,
WriteType writeType,
int requiredAcks,
int receivedAcks,
int nbRetry)
Defines whether to retry and at which consistency level on a write timeout.
|
static RetryPolicy.RetryDecision |
RetryPolicy.RetryDecision.retry(ConsistencyLevel consistency)
Creates a
RetryPolicy.RetryDecision.Type.RETRY retry decision using the same host and the
provided consistency level. |
static RetryPolicy.RetryDecision |
RetryPolicy.RetryDecision.tryNextHost(ConsistencyLevel consistency)
Creates a
RetryPolicy.RetryDecision.Type.RETRY retry decision using the next host in the query
plan, and using the provided consistency level. |
Copyright © 2012–2024. All rights reserved.