@FunctionalInterface public interface CqlExceptionTranslator extends PersistenceExceptionTranslator
driver exceptionsand Spring's data access strategy-agnostic
|Modifier and Type||Method and Description|
default DataAccessException translate(@Nullable String task, @Nullable String cql, RuntimeException ex)
RuntimeExceptioninto a generic
DataAccessException is supposed to contain the original
DriverException as root cause.
However, client code may not generally rely on this due to
DataAccessExceptions possibly being caused by
other resource APIs as well. That said, a
getRootCause() instanceof DataAccessException check (and
subsequent cast) is considered reliable when expecting Cassandra-based access to have happened.
Copyright © 2011–2021 Pivotal Software, Inc.. All rights reserved.