-
Notifications
You must be signed in to change notification settings - Fork 38.5k
Document LazyConnectionDataSourceProxy for IsolationLevelDataSourceRouter usage with DataSourceTransactionManager #19688
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Comments
Juergen Hoeller commented
Are you trying to optimize the switching overhead there? Why are you using |
springrain commented I used to read and write the database separation,I don't have to use JTA <bean id="dataSource" class="org.springframework.jdbc.datasource.lookup.IsolationLevelDataSourceRouter"> |
I've hit a similar issue, where I'm trying to use the |
is there any chance that moving the prepareSynchronization call before |
I have similar problem to @andrei-ivanov, any updates on this? @jhoeller |
Returning to DataSource setup issues for a bit of a JDBC theme in 6.1.2, including new sharding support and several refinements to Spring's DataSource adapters : see https://github.com/spring-projects/spring-framework/issues?q=is%3Aopen+milestone%3A6.1.2+label%3A%22in%3A+data%22+ I am inclined to address the isolation level scenario here through an extension of As an alternative, |
Experimenting with a few scenarios here, such an extension to As a consequence, I am going to turn this ticket into a documentation ticket for |
springrain opened SPR-15121 and commented
IsolationLevelDataSourceRouter.determineCurrentLookupKey returns the result was null, since AbstractPlatformTransactionManager.getTransaction (TransactionDefinition definition) before calling doBegin(Object transaction, TransactionDefinition definition), setCurrentTransactionIsolationLevel(Integer isolationLevel) is not set, but get a connection, it's bug.
Affects: 4.3.4
Referenced from: pull request #1291
The text was updated successfully, but these errors were encountered: