-->
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.  [ 5 posts ] 
Author Message
 Post subject: Hi urgnet AssertionFailure
PostPosted: Wed Nov 09, 2005 1:41 pm 
Newbie

Joined: Wed Nov 09, 2005 1:36 pm
Posts: 3
Hi guys,
I am getting this error, my server is crash, oh its urgent if anybody know pls help for me, its urgent,

error message: BBOO0223I an assertion failure occured (this may indicate a bug in Hibernate, but is more likely due to unsafe use
of the session) org.hibernate.AssertionFailure org.hibernate.AssertionFailure
Trace:

FunctionName: org.hibernate.AssertionFailure
SourceId: org.hibernate.AssertionFailure
Category: ERROR
ExtendedMessage: TRAS0014I: The following exception was logged org.hibernate.AssertionFailure: possible non-threadsafe access to t
he session
at org.hibernate.engine.TwoPhaseLoad.initializeEntity(TwoPhaseLoad.java(Compiled Code))
at org.hibernate.loader.Loader.initializeEntitiesAndCollections(Loader.java(Compiled Code))
at org.hibernate.loader.Loader.doQuery(Loader.java(Compiled Code))
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java(Compiled Code))
at org.hibernate.loader.Loader.loadEntity(Loader.java(Compiled Code))
at org.hibernate.loader.entity.EntityLoader.load(EntityLoader.java(Compiled Code))
at org.hibernate.loader.entity.EntityLoader.load(EntityLoader.java(Compiled Code))
at org.hibernate.persister.entity.BasicEntityPersister.load(BasicEntityPersister.java(Compiled Code))
at org.hibernate.event.def.DefaultLoadEventListener.loadFromDatasource(DefaultLoadEventListener.java(Compiled Code))
at org.hibernate.event.def.DefaultLoadEventListener.doLoad(DefaultLoadEventListener.java(Compiled Code))
at org.hibernate.event.def.DefaultLoadEventListener.load(DefaultLoadEventListener.java(Compiled Code))
at org.hibernate.event.def.DefaultLoadEventListener.onLoad(DefaultLoadEventListener.java(Compiled Code))
at org.hibernate.impl.SessionImpl.immediateLoad(SessionImpl.java(Inlined Compiled Code))
at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java(Compiled Code))
at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java(Inlined Compiled Code))
at org.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java(Compiled Code))
at com.citigroup.rel.adg.persistence.Proposition$$EnhancerByCGLIB$$178da86d.getPropositionName(<generated>(Compiled Code))
at org.apache.jsp._groLeftNav._jspService(_groLeftNav.java(Compiled Code))
at com.ibm.ws.webcontainer.jsp.runtime.HttpJspBase.service(HttpJspBase.java(Compiled Code))
at javax.servlet.http.HttpServlet.service(HttpServlet.java(Compiled Code))
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet$JspServletWrapper.service(JspServlet.java(Compiled Code))
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.serviceJspFile(JspServlet.java(Compiled Code))
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.service(JspServlet.java(Compiled Code))
at javax.servlet.http.HttpServlet.service(HttpServlet.java(Compiled Code))
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java(Compiled Code))
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java(Compiled Code))
at com.ibm.ws.webcontainer.servlet.ServicingServletState.service(StrictLifecycleServlet.java(Compiled Code))
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java(Inlined Compiled Code))
at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java(Compiled Code))
at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java(Compiled Code))
at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java(Inlined Compiled Code))
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java(Compiled Code))
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java(Compiled Code))
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.include(WebAppRequestDispatcher.java(Compiled Code))
at org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java(Inlined Compiled Code))
at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java(Compiled Code))
at org.apache.struts.tiles.TilesUtilImpl.doInclude(TilesUtilImpl.java(Inlined Compiled Code))
at org.apache.struts.tiles.TilesUtil.doInclude(TilesUtil.java(Inlined Compiled Code))
at org.apache.struts.taglib.tiles.InsertTag.do


Top
 Profile  
 
 Post subject: thread safety
PostPosted: Wed Nov 09, 2005 2:41 pm 
Expert
Expert

Joined: Fri Jul 22, 2005 2:42 pm
Posts: 670
Location: Seattle, WA
As the message says: possible non-thread safe access.

Try to make sure that only one thread accessing H session. You can do that by using session-per-request strategy or session-per-business-transaction
http://www.hibernate.org/42.html
http://www.hibernate.org/43.html
http://www.hibernate.org/207.html

_________________
--------------
Konstantin

SourceLabs - dependable OpenSource systems


Top
 Profile  
 
 Post subject: hi assertion failure error
PostPosted: Wed Nov 09, 2005 3:50 pm 
Newbie

Joined: Wed Nov 09, 2005 1:36 pm
Posts: 3
Hi,
I think its not a prob. becoz every and every requesting we r creating the session. we have writtne this code into the web.xml. we have written like this.
<filter>
<filter-name>OpenSeView</filter-name>
<filter-class>org.springframework.orm.hibernate3.support.OpenSessionInViewFilter</filter-class>
</filter>


Top
 Profile  
 
 Post subject: filter
PostPosted: Wed Nov 09, 2005 4:00 pm 
Expert
Expert

Joined: Fri Jul 22, 2005 2:42 pm
Posts: 670
Location: Seattle, WA
This assumes that every request passes through the filter which might not be the case, for example an jsp:include could be handled by webserver via separate thread that will not go through the filter. Therefore I suggest trying more robust session-per-business transaction approach. In this case session handling happens on DAO layer and such issues are eliminated.

http://www.onjava.com/pub/a/onjava/2005 ... tions.html

_________________
--------------
Konstantin

SourceLabs - dependable OpenSource systems


Top
 Profile  
 
 Post subject: Hi urgnet AssertionFailure
PostPosted: Wed Nov 09, 2005 6:36 pm 
Newbie

Joined: Wed Nov 09, 2005 1:36 pm
Posts: 3
Hi
I am Using Transaction Management in Spring, at that time also i m getting the same error, i dont know whats going on.
thx
vyas


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 5 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.