Skip to content
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

Change semantic of userObjects in nested transaction #3289

Merged
merged 1 commit into from
Feb 15, 2024

Conversation

rPraml
Copy link
Contributor

@rPraml rPraml commented Dec 8, 2023

Hello Rob,
I want to discuss, if this change makes sense.

We often use Transaction.putUserObject to store some context information and use it in TransactionCallbacks
With the last PR, we discovered, that this does not work how we thought, when nested transactions are use.

We expected that user objects are stored at the current scope. So after a try/finally block, the information is gone, but it seems, if there is a transaction open, that the objects are stored at the upper most transaction.

Please take a look at this PR, which will change the behaviour, how userObjects are stored.

Roland

@rbygrave
Copy link
Member

Yes, makes good sense to me. Given the behaviour change we could include this in 14.x.

My thought is that 14.x would be:

  • this change
  • the ebean-migration change to JdbcMigrations
  • switch javax and jakarta so that 14.x is jakarta and 14.x-javax is javax

@rbygrave rbygrave added this to the 14.0.0 milestone Dec 21, 2023
@rbygrave rbygrave merged commit ea11b0c into ebean-orm:master Feb 15, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants