Re: [hibernate-dev] Spring Cache Abstraction

2011-02-24 Thread Max Rydahl Andersen
Is it just me or did they just make a weapon to shoot everyone in their foot ? Caching entities like that is dangerous and really hard to catchweird how neither their docs, blogs or javadocs mentions the problem of accidentally sharing out JPA entities across sessions /max On Feb 23, 2

Re: [hibernate-dev] Spring Cache Abstraction

2011-02-23 Thread Daniele Dellafiore
On Wed, Feb 23, 2011 at 5:19 PM, Sanne Grinovero wrote: > Hi Marc, > do you have a link? sorry but "cache + Spring" in google returns a lot > of crap, most of it quite old. today's blog entry about spring 3.1 http://j.mp/hACxAM -- Daniele Dellafiore http://danieledellafiore.net ___

Re: [hibernate-dev] Spring Cache Abstraction

2011-02-23 Thread Emmanuel Bernard
It kinda like the declarative aspect of it though there are a lot of nasty strings all around :). The rest is not really new so all old school issues apply. As usual for higher level caching you need to manually handle data eviction which is likely be a source of bugs. They also don't say if t

Re: [hibernate-dev] Spring Cache Abstraction

2011-02-23 Thread Gustavo Fernandes
On 02/23/2011 04:19 PM, Sanne Grinovero wrote: > Hi Marc, > do you have a link? sorry but "cache + Spring" in google returns a lot > of crap, most of it quite old. I believe the link is http://static.springsource.org/spring/docs/3.1.0.M1/spring-framework-reference/html/cache.html Gustavo __

Re: [hibernate-dev] Spring Cache Abstraction

2011-02-23 Thread Steve Ebersole
I have not looked at the spring code you mention specifically, however caching entity instances directly as opposed to storing the entity states is never going to work. Going this route requires that you synchronize access to the entities in the application since multiple threads/transactions w

Re: [hibernate-dev] Spring Cache Abstraction

2011-02-23 Thread Sanne Grinovero
Hi Marc, do you have a link? sorry but "cache + Spring" in google returns a lot of crap, most of it quite old. Needless to say, if you cache instances across different sessions / threads, they will have to be immutable or you will get all kinds of issues when you make some change, as it would affe