インターフェース PreparedStatementCache
- すべての既知の実装クラス:
MapPreparedStatementCache
使用すべきではありません。
3.2 以降、Cassandra ドライバーにはプリペアドステートメントキャッシュが組み込まれており、プリペアドステートメントの外部キャッシュが不要になります。
CQL ステートメントを同期的に準備するためのキャッシュインターフェース。
PreparedStatementCache
の実装クラスには、独自の同期およびキャッシュ実装特性が付属しています。キャッシュ実装は、クラスター、キースペース、CQL テキストに固有の Cassandra キャッシュキーを使用して、準備呼び出しとキャッシュステートメントの削減を最適化する必要があります。
- 導入:
- 2.0
- 作成者:
- Mark Paluch
- 関連事項:
PreparedStatement
メソッドのサマリー
修飾子と型メソッド説明static PreparedStatementCache
create()
使用すべきではありません。ConcurrentHashMap
SE を基盤とするデフォルトのキャッシュを作成します。default com.datastax.oss.driver.api.core.cql.PreparedStatement
getPreparedStatement
(com.datastax.oss.driver.api.core.CqlSession session, com.datastax.oss.driver.api.core.cql.SimpleStatement statement) 使用すべきではありません。CqlSession
とSimpleStatement
によってPreparedStatement
を取得します。com.datastax.oss.driver.api.core.cql.PreparedStatement
getPreparedStatement
(com.datastax.oss.driver.api.core.CqlSession session, com.datastax.oss.driver.api.core.cql.SimpleStatement statement, SupplierSE<com.datastax.oss.driver.api.core.cql.PreparedStatement> preparer) 使用すべきではありません。CqlSession
とSimpleStatement
によってPreparedStatement
を取得します。
メソッドの詳細
create
使用すべきではありません。ConcurrentHashMap
SE を基盤とするデフォルトのキャッシュを作成します。- 戻り値:
- 新しい
MapPreparedStatementCache
。
getPreparedStatement
default com.datastax.oss.driver.api.core.cql.PreparedStatement getPreparedStatement(com.datastax.oss.driver.api.core.CqlSession session, com.datastax.oss.driver.api.core.cql.SimpleStatement statement) 使用すべきではありません。CqlSession
とSimpleStatement
によってPreparedStatement
を取得します。- パラメーター:
session
- null であってはなりません。statement
- null であってはなりません。- 戻り値:
PreparedStatement
getPreparedStatement
com.datastax.oss.driver.api.core.cql.PreparedStatement getPreparedStatement(com.datastax.oss.driver.api.core.CqlSession session, com.datastax.oss.driver.api.core.cql.SimpleStatement statement, SupplierSE<com.datastax.oss.driver.api.core.cql.PreparedStatement> preparer) 使用すべきではありません。CqlSession
とSimpleStatement
によってPreparedStatement
を取得します。- パラメーター:
session
- null であってはなりません。statement
- null であってはなりません。preparer
- null であってはなりません。- 戻り値:
PreparedStatement