-->
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.  [ 2 posts ] 
Author Message
 Post subject: Help me with "Cache is not alive"
PostPosted: Fri Jan 13, 2006 4:16 am 
Newbie

Joined: Tue Aug 30, 2005 12:30 am
Posts: 9
Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp

[b]Hibernate version:[/b]
3.1.0

Hi,

I have problem, hibernate sometimes give me an java.lang.IllegalStateException: Cache is not alive.
Does any body know what state cause that exception in hibernate?

Thank You


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jan 13, 2006 7:36 am 
Newbie

Joined: Tue Aug 30, 2005 12:30 am
Posts: 9
Hi,

I found out that the error occured when i have a user object queried by one user, the other user update or delete the same user table (different records), when i try to get the property of the first user object it gave me Cache is not alive. there is no problems when i test the application using only one user.


here is the stack trace:
java.lang.IllegalStateException: The com.menaraintermedia.dbobject.User Cache is not alive.
at net.sf.ehcache.Cache.checkStatus(Cache.java:713)
at net.sf.ehcache.Cache.get(Cache.java:355)
at org.hibernate.cache.EhCache.get(EhCache.java:110)
at org.hibernate.cache.ReadWriteCache.get(ReadWriteCache.java:80)
at org.hibernate.persister.entity.AbstractEntityPersister.isTransient(AbstractEntityPersis
at org.hibernate.engine.ForeignKeys.isTransient(ForeignKeys.java:181)
at org.hibernate.engine.ForeignKeys.getEntityIdentifierIfNotUnsaved(ForeignKeys.java:215)
at org.hibernate.type.EntityType.getIdentifier(EntityType.java:108)
at org.hibernate.type.ManyToOneType.nullSafeSet(ManyToOneType.java:77)
at org.hibernate.loader.Loader.bindPositionalParameters(Loader.java:1514)
at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1576)
at org.hibernate.loader.Loader.doQuery(Loader.java:661)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224)
at org.hibernate.loader.Loader.doList(Loader.java:2150)
at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2029)
at org.hibernate.loader.Loader.list(Loader.java:2024)
at org.hibernate.loader.criteria.CriteriaLoader.list(CriteriaLoader.java:94)
at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1492)
at org.hibernate.impl.CriteriaImpl.list(CriteriaImpl.java:298)
at com.menaraintermedia.UserBusinessLogic.deleteEnterMeja(Unknown Source)
at com.menaraintermedia.UserBusinessLogic.leaveMeja(Unknown Source)
at com.menaraintermedia.UserBusinessLogic.logoutLogic(Unknown Source)
at com.menaraintermedia.UserBusinessLogic.internalError(Unknown Source)
at com.menaraintermedia.UserBusinessLogic.countCounter(Unknown Source)
at com.menaraintermedia.UserBusinessLogic.calculateWinner(Unknown Source)
at com.menaraintermedia.UserBusinessLogic.throwCard(Unknown Source)
at com.menaraintermedia.UserBusinessLogic.betSteps(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:294)
at sun.rmi.transport.Transport$1.run(Transport.java:153)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:149)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
at java.lang.Thread.run(Thread.java:595)


i also use separate session factories for each user login, does it has anything to do with the error?
Please help.

Thank You


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 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:
cron
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.