我正在使用 ScalarDB 在Cassandra应用程序中添加 ACID 支持。如果我开始 aTransaction但不提交会发生什么。会不会有什么不良影响?
例如。
def somefunction= {
//Create the transaction
val transaction: DistributedTransaction = transactionService.start
if(all OK){
... //go ahead with DB operations
commitTransaction(transaction) //OK
(user: User, profileAndPortfolio: ExternalUserProfile, emailToken: UserToken)
} else {
//miss commiting the transaction here
}
}