Skip to content
Discussion options

You must be logged in to vote

but when not under a transaction Hibernate's cache doesn't "get in the way" (it fetches what I expect it to fetch from the DB)

I explained that behavior above. When not in a transaction the outer code and the code in f don't use the same session, so they don't use the same cache.

so my guess here is that the fault lies on Hibernate's side.

No, the fact that you use caches in one case and not the other is completely expected behavior.

(My code might be wrong, but the fact that it works under one condition and not the other still makes me point to cache)

Yes it's about (first-level) caches.

Replies: 3 comments 6 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
6 replies
@zanella
Comment options

@yrodiere
Comment options

@zanella
Comment options

@yrodiere
Comment options

Answer selected by zanella
@zanella
Comment options

@yrodiere
Comment options

yrodiere Jun 1, 2023
Collaborator

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
3 participants