Open marcinfigiel opened 5 months ago
So I'm not on the Micronaut team, but I was interested in this because I'm setting up the db driver for a project. I see you have autocommit turned off and you're not using @Transactional
. I know postgres has a built-in "autocommit", but I'm wondering if either hikari autocommit or @Transactional
needs to be used here? I'm assuming that @SqlQuery
doesn't do anything with a transaction automatically.
There is @Transactional
annotation in the DatabaseService, it's required for the managed Jdbi
instance to work.
Expected Behavior
When running multiple concurrent DB operations with few transactions each, all of them should end succesfully eventually.
Actual Behaviour
Transactions fail randomly.
Steps To Reproduce
Environment Information
Example Application
https://github.com/marcinfigiel/demo-jdbi-error
Version
4.5.0