Open evgenyvsmirnov opened 8 months ago
Can you please provide a reproducer as an attached archive or a link to a repository? If a database is needed, please provide a docker-compose.yml
.
gh32115.zip The attached archive contains the aforementioned test. The test employs testcontainers (postgresql 15.5). A short summary in the test's displayname summarizes its logic.
@evgenyvsmirnov @sdeleuze I have same problem. How did you solve this?
I think I'm having this problem because I'm using Propagation.REQUIRES_NEW.
@Transactional(propagation = Propagation.REQUIRES_NEW)
@evgenyvsmirnov @sdeleuze I have same problem. How did you solve this?
I haven't – I've just reported it.
Greetings! Please consider the test below (reactor + r2dbc-postgresql + r2dbc-pool). A reactive chain within the test begins a transaction (outer), inserts a record, begins an autonomous transaction (inner). Inner attempts to insert a record with the same data thus being unable to proceed (outer is still in progress) is cancelled by the reactive chain timeout operator:
Environment:
The outcomes:
Always see the following stacktrace:
the exchange with the database is the following :
Once in a while the test fails: the chain produces «Outer failure» (some concurrency issue?)
The last and the worst: Should the RepeatedTest is used the test hangs after POOL_SIZE repetitions because a connection can’t be gained from the pool. The screenshot with the state of the pool below suggests that one of two connections is not returned into the pool during every test run.