Class CassandraDatabaseWriter
java.lang.Object
org.jumpmind.symmetric.io.data.writer.AbstractDatabaseWriter
org.jumpmind.symmetric.io.data.writer.DefaultDatabaseWriter
org.jumpmind.symmetric.io.data.writer.DynamicDefaultDatabaseWriter
org.jumpmind.symmetric.io.data.writer.CassandraDatabaseWriter
- All Implemented Interfaces:
IDataResource
,IDataWriter
-
Nested Class Summary
Nested classes/interfaces inherited from class org.jumpmind.symmetric.io.data.writer.AbstractDatabaseWriter
AbstractDatabaseWriter.LoadStatus
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected com.google.gson.Gson
protected com.datastax.driver.core.PreparedStatement
protected com.datastax.driver.core.Session
Fields inherited from class org.jumpmind.symmetric.io.data.writer.DynamicDefaultDatabaseWriter
tablePrefix, targetPlatform, targetTransaction
Fields inherited from class org.jumpmind.symmetric.io.data.writer.DefaultDatabaseWriter
CUR_DATA, currentDmlStatement, currentDmlValues, hasUncommittedDdl, isCteExpression, logSqlBuilder, platform, transaction
Fields inherited from class org.jumpmind.symmetric.io.data.writer.AbstractDatabaseWriter
batch, CONFLICT_ERROR, CONFLICT_IGNORE, conflictResolver, context, isRequiresSavePointsInTransaction, lastApplyChangesOnly, lastData, lastUseConflictDetection, missingTables, sourceTable, statistics, targetColumnSourceReferencesMap, targetTable, targetTables, TRANSACTION_ABORTED, uncommittedCount, writerSettings
-
Constructor Summary
ConstructorsConstructorDescriptionCassandraDatabaseWriter
(IDatabasePlatform symmetricPlatform, IDatabasePlatform targetPlatform, String prefix, IDatabaseWriterConflictResolver conflictResolver, DatabaseWriterSettings settings) -
Method Summary
Modifier and TypeMethodDescriptionprotected void
allowInsertIntoAutoIncrementColumns
(boolean value, Table table) protected void
bindVariables
(com.datastax.driver.core.BoundStatement bstmt, Column[] columns, int[] types, String[] values) protected boolean
protected int
protected boolean
isUserSendSql
(String sql, CsvData data) protected void
logFailureDetails
(Throwable e, CsvData data, boolean logLastDmlDetails) protected Table
lookupTableAtTarget
(Table sourceTable) protected List
protected Map
protected Set
protected void
prepare()
protected void
int
prepareAndExecute
(String sql, CsvData data) Methods inherited from class org.jumpmind.symmetric.io.data.writer.DynamicDefaultDatabaseWriter
close, commit, getPlatform, getPlatform, getPlatform, getTablePrefix, getTargetPlatform, getTargetTransaction, getTransaction, getTransaction, getTransaction, isLoadOnly, isSymmetricTable, isSymmetricTable, open, rollback
Methods inherited from class org.jumpmind.symmetric.io.data.writer.DefaultDatabaseWriter
bindVariables, checkTargetTableHasColumns, commit, containsNullLookupKeyDataSinceLastStatement, create, delete, dmlValuesToString, doesColumnNeedUpdated, end, end, getCurData, getCurrentDmlStatement, getSqlStatements, getTableKey, getWriterSettings, insert, isCteExpression, isDml, logDataTruncation, logFailureDetails, lookupTableFromCache, preprocessSqlStatement, putTableInCache, quoteString, removeGeneratedColumns, replaceCteExpression, replaceCteExpression, requireNewStatement, sql, start, targetTableWasChangedByFilter, update, updateChangedDataIndicator
Methods inherited from class org.jumpmind.symmetric.io.data.writer.AbstractDatabaseWriter
buildTargetColumnReferencesMap, checkForEarlyCommit, clearTargetColumnReferencesMap, filterAfter, filterBefore, filterError, getBatch, getConflictResolver, getContext, getLookupDataMap, getPkDataFor, getRowData, getSourceTable, getStatistics, getTargetColumnReferencesMap, getTargetTable, hasFilterThatHandlesMissingTable, notifyFiltersBatchCommitted, notifyFiltersBatchComplete, notifyFiltersBatchRolledback, notifyFiltersEarlyCommit, refreshTargetColumnReferencesMap, script, setConflictResolver, start, write
-
Field Details
-
gson
protected com.google.gson.Gson gson -
session
protected com.datastax.driver.core.Session session -
metaData
-
pstmt
protected com.datastax.driver.core.PreparedStatement pstmt
-
-
Constructor Details
-
CassandraDatabaseWriter
public CassandraDatabaseWriter(IDatabasePlatform symmetricPlatform, IDatabasePlatform targetPlatform, String prefix, IDatabaseWriterConflictResolver conflictResolver, DatabaseWriterSettings settings)
-
-
Method Details
-
prepare
protected void prepare()- Overrides:
prepare
in classDefaultDatabaseWriter
-
prepare
- Overrides:
prepare
in classDefaultDatabaseWriter
-
isUserSendSql
-
prepareAndExecute
- Overrides:
prepareAndExecute
in classDefaultDatabaseWriter
-
execute
- Overrides:
execute
in classDefaultDatabaseWriter
-
lookupTableAtTarget
- Overrides:
lookupTableAtTarget
in classDefaultDatabaseWriter
-
create
- Overrides:
create
in classDefaultDatabaseWriter
-
logFailureDetails
- Overrides:
logFailureDetails
in classDefaultDatabaseWriter
-
allowInsertIntoAutoIncrementColumns
- Overrides:
allowInsertIntoAutoIncrementColumns
in classDefaultDatabaseWriter
-
bindVariables
-
parseList
-
parseSet
-
parseMap
-