-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: composite-id + cache
PostPosted: Tue Jul 13, 2004 5:55 am 
Newbie

Joined: Mon May 10, 2004 7:58 am
Posts: 15
hi,
i had to create a composite pk for read-only data.
when loading such a bean, the logs give those strange things:

11:25:24,079 DEBUG SessionImpl:1975 - loading [eg.Foo#eg.FooPK@5c1592c0]
11:25:24,080 DEBUG SessionImpl:2072 - attempting to resolve [eg.Foo#eg.FooPK@5c1592c0]
11:25:24,082 DEBUG ReadOnlyCache:27 - Cache hit: eg.FooPK@5c1592c0

The reference of the FootPK instance seems to be used as the cache key!?
Is it normal or did i go wrong somewhere?

thanks


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jul 13, 2004 8:53 am 
Hibernate Team
Hibernate Team

Joined: Mon Aug 25, 2003 9:11 pm
Posts: 4592
Location: Switzerland
What is wrong with that?

_________________
JAVA PERSISTENCE WITH HIBERNATE
http://jpwh.org
Get the book, training, and consulting for your Hibernate team.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jul 13, 2004 11:00 am 
Newbie

Joined: Mon May 10, 2004 7:58 am
Posts: 15
so, later in another session, i may build a new FooPK instance (with a fresh reference) and expect the associated data to be read from the 2nd level cache, right?
In the case of a composite-id, does the cache key really depend on the composite pk object reference?


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.