than_
11/01/2021, 1:23 PMobject TransactionTestTable: LongIdTable(){
val foo = integer("foo").check { it greater 0 }
}
when I do
newSuspendedTransaction {
TransactionTestTable.insert { it[foo] = 1 }
throw IllegalStateException("FAIL")
}
the transaction performs a rollback correctly and nothing gets inserted into the table
but when I do
newSuspendedTransaction {
TransactionTestTable.insert { it[foo] = 1 }
TransactionTestTable.insert { it[foo] = 0 }
}
the transaction still fails, but the first value gets inserted in the database.
Is this intentional or a bug?benkuly
12/16/2021, 7:45 AMnewSuspendedTransaction
always commits at end and don't uses the parent transaction.than_
12/16/2021, 10:01 AMuseLocalTransactionState
set to true
when disabled, this problem dissapearedbenkuly
12/16/2021, 10:24 AMthan_
12/16/2021, 10:56 AM