-
Notifications
You must be signed in to change notification settings - Fork 617
DatabaseSelection is not allways used #2234
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Many thanks for reporting this. There seems to be one code path that does not take the |
There should be now a snapshot be available: |
Thank you very much for the quick solution. |
Thanks @VladoKuruc I'll take care of the 2nd issue: #2236 |
Fixes the problem that certain operations did not take the database selection into consideration when executing queries. Closes #2234
Thanks for your valuable feedback. |
After upgrade to SDN 6.1.0 I have Issue with DatabaseSelection.
I use an existing database for unit tests, so I do not create a database in them. I just need to clean up the data at the beginning of the transaction and with the rollback at the end so that testing does not affect the existing data.
In version 6.0.x, I had to use the .in(databaseName) clause.
neo4jClient.query("MATCH (n) DETACH DELETE n").in("neo4jtest").run();
DatabaseSelectionProvider is now available in version 6.1.x in neo4jClient, so it would be nice not to use it.
In this case, an error occurs.
java.lang.IllegalStateException: There is already an ongoing Spring transaction for 'neo4jtest', but you request the default database
However, the same error occurs in the case of a more complex mapping during repository.save () in a transaction where I cannot influence it.
Take a look at the attached unittest where I use the modified AltHobby class. I added two properties there.
DatabaseSelectionProviderIT.java.txt
Thank for investigation.
The text was updated successfully, but these errors were encountered: