File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes EJB and other Java EE Technologies and the fly likes How to delete the persisted entity in EJB3.0 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "How to delete the persisted entity in EJB3.0" Watch "How to delete the persisted entity in EJB3.0" New topic
Author

How to delete the persisted entity in EJB3.0

V.N.T.Deepak Solasa
Greenhorn

Joined: May 29, 2007
Posts: 16
I have one application where in I have add button ,when click on that the entity will be added to the database using entitymanager persist();then i have delete button where in i am using entitymanager.remove();
Now my problem is if i am trying to delete the row(lets say entity)that is added earlier,it is working fine but if I am trying to delete the entity that is added just then i am facing the exception as entity in the persistence state cannot be deleted..

---I haven't used any EnityTransactions

Any suggestions are welcome

Thanks in Advance
Nitesh Kant
Bartender

Joined: Feb 25, 2007
Posts: 1638

What is the exception you are getting, can you put the stack trace here.
How do you say that you are not using transactions? I am not sure about ejb 3 but till ejb 2.0 entity beans are always transactional.


apigee, a better way to API!
V.N.T.Deepak Solasa
Greenhorn

Joined: May 29, 2007
Posts: 16
Hi Nitesh

Thanks for the reply,
what i mean is in ejb3.0 we have Transactional Attributes where in I have used
@TransactionAttribute(TransactionAttributeType.REQUIRED) but I havent used EntityTransaction class to begin or commit the database operations.
By the way ,the error stack trace i am getting while trying to delete the entity that was added recently is:::--

javax.persistence.EntityNotFoundException: deleted entity passed to persist: [de.bonprix.orderstarter.model.entity.ArticleSupplier#<null>]

at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:613)

at org.hibernate.ejb.AbstractEntityManagerImpl$1.beforeCompletion(AbstractEntityManagerImpl.java:524)

at com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple.beforeCompletion(SynchronizationImple.java:114)

at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.beforeCompletion(TwoPhaseCoordinator.java:247)

at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.end(TwoPhaseCoordinator.java:86)

at com.arjuna.ats.arjuna.AtomicAction.commit(AtomicAction.java:177)

at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1382)

at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:135)

at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:87)

at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:175)

at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:87)

at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:191)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.stateful.StatefulInstanceInterceptor.invoke(StatefulInstanceInterceptor.java:83)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)

at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:106)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:46)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.stateful.StatefulContainer.localInvoke(StatefulContainer.java:204)

at org.jboss.ejb3.stateful.StatefulLocalProxy.invoke(StatefulLocalProxy.java:100)

at $Proxy124.deleteSupplierDetails(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 org.jboss.seam.util.Reflections.invoke(Reflections.java:20)

at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:31)

at org.jboss.seam.intercept.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:72)

at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:57)

at org.jboss.seam.interceptors.RemoveInterceptor.aroundInvoke(RemoveInterceptor.java:40)

at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:69)

at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:103)

at org.jboss.seam.intercept.ClientSideInterceptor.invoke(ClientSideInterceptor.java:50)

at org.javassist.tmp.java.lang.Object_$$_javassist_13.deleteSupplierDetails(Object_$$_javassist_13.java)

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 org.apache.el.parser.AstValue.invoke(AstValue.java:131)

at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)

at com.sun.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:68)

at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:77)

at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:91)

at javax.faces.component.UICommand.broadcast(UICommand.java:383)

at javax.faces.component.UIData.broadcast(UIData.java:854)

at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:447)

at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:752)

at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:97)

at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)

at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)

at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:63)

at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:79)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.SeamFilter.doFilter(SeamFilter.java:84)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)

at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)

at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)

at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)

at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)

at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)

at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

at java.lang.Thread.run(Thread.java:595)

16:07:37,197 FATAL [application] java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

javax.faces.el.EvaluationException: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:91)

at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:91)

at javax.faces.component.UICommand.broadcast(UICommand.java:383)

at javax.faces.component.UIData.broadcast(UIData.java:854)

at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:447)

at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:752)

at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:97)

at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)

at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)

at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:63)

at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:79)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.SeamFilter.doFilter(SeamFilter.java:84)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)

at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)

at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)

at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)

at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)

at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)

at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

at java.lang.Thread.run(Thread.java:595)

Caused by: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at org.jboss.aspects.tx.TxPolicy.handleEndTransactionException(TxPolicy.java:198)

at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:180)

at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:87)

at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:191)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.stateful.StatefulInstanceInterceptor.invoke(StatefulInstanceInterceptor.java:83)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)

at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:106)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:46)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.stateful.StatefulContainer.localInvoke(StatefulContainer.java:204)

at org.jboss.ejb3.stateful.StatefulLocalProxy.invoke(StatefulLocalProxy.java:100)

at $Proxy124.deleteSupplierDetails(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 org.jboss.seam.util.Reflections.invoke(Reflections.java:20)

at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:31)

at org.jboss.seam.intercept.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:72)

at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:57)

at org.jboss.seam.interceptors.RemoveInterceptor.aroundInvoke(RemoveInterceptor.java:40)

at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:69)

at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:103)

at org.jboss.seam.intercept.ClientSideInterceptor.invoke(ClientSideInterceptor.java:50)

at org.javassist.tmp.java.lang.Object_$$_javassist_13.deleteSupplierDetails(Object_$$_javassist_13.java)

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 org.apache.el.parser.AstValue.invoke(AstValue.java:131)

at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)

at com.sun.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:68)

at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:77)

... 40 more

Caused by: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1394)

at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:135)

at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:87)

at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:175)

... 78 more

Caused by: javax.persistence.EntityNotFoundException: deleted entity passed to persist: [de.bonprix.orderstarter.model.entity.ArticleSupplier#<null>]

at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:613)

at org.hibernate.ejb.AbstractEntityManagerImpl$1.beforeCompletion(AbstractEntityManagerImpl.java:524)

at com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple.beforeCompletion(SynchronizationImple.java:114)

at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.beforeCompletion(TwoPhaseCoordinator.java:247)

at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.end(TwoPhaseCoordinator.java:86)

at com.arjuna.ats.arjuna.AtomicAction.commit(AtomicAction.java:177)

at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1382)

... 81 more

16:07:37,337 WARN [lifecycle] #{manageOrders.deleteSupplierDetails}: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

javax.faces.FacesException: #{manageOrders.deleteSupplierDetails}: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:107)

at javax.faces.component.UICommand.broadcast(UICommand.java:383)

at javax.faces.component.UIData.broadcast(UIData.java:854)

at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:447)

at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:752)

at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:97)

at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)

at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)

at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:63)

at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:79)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.SeamFilter.doFilter(SeamFilter.java:84)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)

at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)

at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)

at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)

at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)

at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)

at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

at java.lang.Thread.run(Thread.java:595)

Caused by: javax.faces.el.EvaluationException: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:91)

at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:91)

... 39 more

Caused by: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at org.jboss.aspects.tx.TxPolicy.handleEndTransactionException(TxPolicy.java:198)

at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:180)

at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:87)

at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:191)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.stateful.StatefulInstanceInterceptor.invoke(StatefulInstanceInterceptor.java:83)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)

at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:106)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:46)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.stateful.StatefulContainer.localInvoke(StatefulContainer.java:204)

at org.jboss.ejb3.stateful.StatefulLocalProxy.invoke(StatefulLocalProxy.java:100)

at $Proxy124.deleteSupplierDetails(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 org.jboss.seam.util.Reflections.invoke(Reflections.java:20)

at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:31)

at org.jboss.seam.intercept.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:72)

at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:57)

at org.jboss.seam.interceptors.RemoveInterceptor.aroundInvoke(RemoveInterceptor.java:40)

at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:69)

at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:103)

at org.jboss.seam.intercept.ClientSideInterceptor.invoke(ClientSideInterceptor.java:50)

at org.javassist.tmp.java.lang.Object_$$_javassist_13.deleteSupplierDetails(Object_$$_javassist_13.java)

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 org.apache.el.parser.AstValue.invoke(AstValue.java:131)

at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)

at com.sun.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:68)

at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:77)

... 40 more

Caused by: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1394)

at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:135)

at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:87)

at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:175)

... 78 more

Caused by: javax.persistence.EntityNotFoundException: deleted entity passed to persist: [de.bonprix.orderstarter.model.entity.ArticleSupplier#<null>]

at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:613)

at org.hibernate.ejb.AbstractEntityManagerImpl$1.beforeCompletion(AbstractEntityManagerImpl.java:524)

at com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple.beforeCompletion(SynchronizationImple.java:114)

at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.beforeCompletion(TwoPhaseCoordinator.java:247)

at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.end(TwoPhaseCoordinator.java:86)

at com.arjuna.ats.arjuna.AtomicAction.commit(AtomicAction.java:177)

at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1382)

... 81 more

16:07:37,400 WARN [lifecycle] executePhase(INVOKE_APPLICATION 5,com.sun.faces.context.FacesContextImpl@1ad453f) threw exception

javax.faces.FacesException: #{manageOrders.deleteSupplierDetails}: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:105)

at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)

at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)

at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:63)

at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:79)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.SeamFilter.doFilter(SeamFilter.java:84)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)

at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)

at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)

at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)

at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)

at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)

at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

at java.lang.Thread.run(Thread.java:595)

Caused by: javax.faces.FacesException: #{manageOrders.deleteSupplierDetails}: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:107)

at javax.faces.component.UICommand.broadcast(UICommand.java:383)

at javax.faces.component.UIData.broadcast(UIData.java:854)

at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:447)

at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:752)

at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:97)

... 34 more

Caused by: javax.faces.el.EvaluationException: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:91)

at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:91)

... 39 more

Caused by: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at org.jboss.aspects.tx.TxPolicy.handleEndTransactionException(TxPolicy.java:198)

at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:180)

at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:87)

at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:191)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.stateful.StatefulInstanceInterceptor.invoke(StatefulInstanceInterceptor.java:83)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)

at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:106)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:46)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.stateful.StatefulContainer.localInvoke(StatefulContainer.java:204)

at org.jboss.ejb3.stateful.StatefulLocalProxy.invoke(StatefulLocalProxy.java:100)

at $Proxy124.deleteSupplierDetails(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 org.jboss.seam.util.Reflections.invoke(Reflections.java:20)

at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:31)

at org.jboss.seam.intercept.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:72)

at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:57)

at org.jboss.seam.interceptors.RemoveInterceptor.aroundInvoke(RemoveInterceptor.java:40)

at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:69)

at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:103)

at org.jboss.seam.intercept.ClientSideInterceptor.invoke(ClientSideInterceptor.java:50)

at org.javassist.tmp.java.lang.Object_$$_javassist_13.deleteSupplierDetails(Object_$$_javassist_13.java)

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 org.apache.el.parser.AstValue.invoke(AstValue.java:131)

at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)

at com.sun.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:68)

at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:77)

... 40 more

Caused by: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1394)

at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:135)

at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:87)

at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:175)

... 78 more

Caused by: javax.persistence.EntityNotFoundException: deleted entity passed to persist: [de.bonprix.orderstarter.model.entity.ArticleSupplier#<null>]

at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:613)

at org.hibernate.ejb.AbstractEntityManagerImpl$1.beforeCompletion(AbstractEntityManagerImpl.java:524)

at com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple.beforeCompletion(SynchronizationImple.java:114)

at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.beforeCompletion(TwoPhaseCoordinator.java:247)

at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.end(TwoPhaseCoordinator.java:86)

at com.arjuna.ats.arjuna.AtomicAction.commit(AtomicAction.java:177)

at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1382)

... 81 more

16:07:37,416 ERROR [ExceptionFilter] uncaught exception

javax.servlet.ServletException: #{manageOrders.deleteSupplierDetails}: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at javax.faces.webapp.FacesServlet.service(FacesServlet.java:256)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:63)

at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:79)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.SeamFilter.doFilter(SeamFilter.java:84)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)

at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)

at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)

at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)

at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)

at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)

at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

at java.lang.Thread.run(Thread.java:595)

Caused by: javax.faces.FacesException: #{manageOrders.deleteSupplierDetails}: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:107)

at javax.faces.component.UICommand.broadcast(UICommand.java:383)

at javax.faces.component.UIData.broadcast(UIData.java:854)

at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:447)

at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:752)

at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:97)

at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)

at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)

at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)

... 31 more

Caused by: javax.faces.el.EvaluationException: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:91)

at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:91)

... 39 more

Caused by: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at org.jboss.aspects.tx.TxPolicy.handleEndTransactionException(TxPolicy.java:198)

at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:180)

at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:87)

at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:191)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.stateful.StatefulInstanceInterceptor.invoke(StatefulInstanceInterceptor.java:83)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)

at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:106)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:46)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.stateful.StatefulContainer.localInvoke(StatefulContainer.java:204)

at org.jboss.ejb3.stateful.StatefulLocalProxy.invoke(StatefulLocalProxy.java:100)

at $Proxy124.deleteSupplierDetails(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 org.jboss.seam.util.Reflections.invoke(Reflections.java:20)

at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:31)

at org.jboss.seam.intercept.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:72)

at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:57)

at org.jboss.seam.interceptors.RemoveInterceptor.aroundInvoke(RemoveInterceptor.java:40)

at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:69)

at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:103)

at org.jboss.seam.intercept.ClientSideInterceptor.invoke(ClientSideInterceptor.java:50)

at org.javassist.tmp.java.lang.Object_$$_javassist_13.deleteSupplierDetails(Object_$$_javassist_13.java)

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 org.apache.el.parser.AstValue.invoke(AstValue.java:131)

at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)

at com.sun.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:68)

at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:77)

... 40 more

Caused by: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1394)

at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:135)

at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:87)

at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:175)

... 78 more

Caused by: javax.persistence.EntityNotFoundException: deleted entity passed to persist: [de.bonprix.orderstarter.model.entity.ArticleSupplier#<null>]

at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:613)

at org.hibernate.ejb.AbstractEntityManagerImpl$1.beforeCompletion(AbstractEntityManagerImpl.java:524)

at com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple.beforeCompletion(SynchronizationImple.java:114)

at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.beforeCompletion(TwoPhaseCoordinator.java:247)

at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.end(TwoPhaseCoordinator.java:86)

at com.arjuna.ats.arjuna.AtomicAction.commit(AtomicAction.java:177)

at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1382)

... 81 more

16:07:37,478 ERROR [ExceptionFilter] exception root cause

javax.faces.FacesException: #{manageOrders.deleteSupplierDetails}: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:107)

at javax.faces.component.UICommand.broadcast(UICommand.java:383)

at javax.faces.component.UIData.broadcast(UIData.java:854)

at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:447)

at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:752)

at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:97)

at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)

at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)

at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:63)

at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:79)

at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)

at org.jboss.seam.web.SeamFilter.doFilter(SeamFilter.java:84)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)

at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)

at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)

at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)

at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)

at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)

at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

at java.lang.Thread.run(Thread.java:595)

Caused by: javax.faces.el.EvaluationException: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:91)

at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:91)

... 39 more

Caused by: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at org.jboss.aspects.tx.TxPolicy.handleEndTransactionException(TxPolicy.java:198)

at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:180)

at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:87)

at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:191)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.stateful.StatefulInstanceInterceptor.invoke(StatefulInstanceInterceptor.java:83)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)

at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:106)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:46)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)

at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)

at org.jboss.ejb3.stateful.StatefulContainer.localInvoke(StatefulContainer.java:204)

at org.jboss.ejb3.stateful.StatefulLocalProxy.invoke(StatefulLocalProxy.java:100)

at $Proxy124.deleteSupplierDetails(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 org.jboss.seam.util.Reflections.invoke(Reflections.java:20)

at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:31)

at org.jboss.seam.intercept.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:72)

at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:57)

at org.jboss.seam.interceptors.RemoveInterceptor.aroundInvoke(RemoveInterceptor.java:40)

at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:69)

at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:103)

at org.jboss.seam.intercept.ClientSideInterceptor.invoke(ClientSideInterceptor.java:50)

at org.javassist.tmp.java.lang.Object_$$_javassist_13.deleteSupplierDetails(Object_$$_javassist_13.java)

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 org.apache.el.parser.AstValue.invoke(AstValue.java:131)

at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)

at com.sun.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:68)

at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:77)

... 40 more

Caused by: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state

at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1394)

at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:135)

at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:87)

at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:175)

... 78 more

Caused by: javax.persistence.EntityNotFoundException: deleted entity passed to persist: [de.bonprix.orderstarter.model.entity.ArticleSupplier#<null>]

at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:613)

at org.hibernate.ejb.AbstractEntityManagerImpl$1.beforeCompletion(AbstractEntityManagerImpl.java:524)

at com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple.beforeCompletion(SynchronizationImple.java:114)

at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.beforeCompletion(TwoPhaseCoordinator.java:247)

at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.end(TwoPhaseCoordinator.java:86)

at com.arjuna.ats.arjuna.AtomicAction.commit(AtomicAction.java:177)

at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1382)

... 81 more
Edvins Reisons
Ranch Hand

Joined: Dec 11, 2006
Posts: 364
Originally posted by V.N.T.Deepak Solasa:


javax.persistence.EntityNotFoundException: deleted entity passed to persist: [de.bonprix.orderstarter.model.entity.ArticleSupplier#<null>]




So, it is the other way round: you are trying to persist a deleted entity.
V.N.T.Deepak Solasa
Greenhorn

Joined: May 29, 2007
Posts: 16
when I am calling entityManager.remove() it is deleting he entity but once if i call entityManager.persist and then delete the entity by calling entityManager.remove() even it is not deleting the entity and giving the above exception..
Fabian Gutierrez
Greenhorn

Joined: Aug 15, 2004
Posts: 22
well, this is an odd behaviour..there shouldn't be any problem trying to persist a removed entity (3.1.1 jpa spec), however the exception is not thrown in the second entityManager.remove(), but in the entityManager.persist().

so, as a work around, you may call a entityManaget.flush() after the first entityManager.remove()...

regards,


SCJP 1.4, SCWCD 1.4, SCBCD 5, SCJD 5
V.N.T.Deepak Solasa
Greenhorn

Joined: May 29, 2007
Posts: 16
Thanks for the response,

Even i call the same after my entityManager.remove() but it is throwing exception in the remove method itself.
V.N.T.Deepak Solasa
Greenhorn

Joined: May 29, 2007
Posts: 16
Thanks for the response,

Even i call the same after my entityManager.remove() but it is throwing exception in the remove method itself.
Anand Kumar Singh
Greenhorn

Joined: Oct 18, 2007
Posts: 22
First you are adding an Entity by calling persist() and then trying to
remove the same Entity, but both are executing in the same transaction.
Since you want to remove the same entity which is added in the same
transaction. It will not work.

Both the call must be in separate Transaction , first commit calling
persist()Transaction, then create a new Transaction and call remove(). Put
annotation on both method @TransactionAttribute
(TransactionAttributeType.REQUIRED). Now it will work.


SCJP 5, SCWCD 5, SCBCD 5,
SCEA 5,
OCUP Fundamental,
OCUP Intermediate,
OCUP Advanced,
IBM Certified Solution Designer - Object Oriented Analysis and Design, vUML 2
V.N.T.Deepak Solasa
Greenhorn

Joined: May 29, 2007
Posts: 16
Hi Anand,
Thanks for your answer.I have already using the same
@TransactionAttribute(TransactionAttributeType.REQUIRED) and tried by commiting the transaction after persistening the data.but it is not working ,i am getting the same error.

-----Deepak
Anand Kumar Singh
Greenhorn

Joined: Oct 18, 2007
Posts: 22
Don't use @TransactionAttribute(TransactionAttributeType.REQUIRED)
Its mean you want to go in the existing transaction,

Use @TransactionAttribute(TransactionAttributeType.REQUIRED_NEW)
Its mean now suspend current transaction and create new.
V.N.T.Deepak Solasa
Greenhorn

Joined: May 29, 2007
Posts: 16
Hi
Even i used the TransactionAttributeType.REQUIRES_NEW.
But I am getting the same error.
Any more suggestions please

Thanks
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to delete the persisted entity in EJB3.0