Hibernation Cache Level 1

I have one misunderstanding of cache level 1. So far, I have seen that cache level 1 is used only for deferred sql calls until the transaction is reset.

But what about objects? For example, I use only cache level 1. If I were to load the same object several times during the same transaction, what would happen? Does hibernate use some kind of identification card and cache objects that were downloaded in one transaction?

+3
source share
3 answers

So far, I have seen that cache level 1 is only used to disable sql calls until the transaction is reset.

, - id ( ) , , .

, ( ).

, ?

, (.. ). , 1- .

hibernate - , .

. .

+2

:

1. levlel . , , .

2.It .

:

1. .

+3

. (N) Hibernate (http://martinfowler.com/eaaCatalog/identityMap.html), .

ISession, , ISession, .

, ISession, (N) 2.

+2
source

Source: https://habr.com/ru/post/1774073/


All Articles