6 Replies Latest reply on Nov 18, 2009 5:26 PM by Mark Durant

    Serialization issue running Booking example on Weblogic 10.3 and Seam 2.1.1.GA

    Paul Tisca Newbie

      I've got the Booking example up and running on Weblogic 10.3. I'm hitting an issue when I log into the booking app and I confirm a hotel booking. When I hit confirm, I get the following stack trace dumped in Weblogic. The application continues to work fine except that I can't see my confirmed bookings unless I log out and log back in.


      I'm assuming that the error has something to do when the following is called in the HotelBookingAction confirm method
            events.raiseTransactionSuccessEvent(bookingConfirmed);


      In BookingListAction on the getBookings method, If I comment out the @Oberver(bookingconfirmed) annotation, I do not receive an error. If comment out the @Factory method I don't receive the EJBException but I still receive the Exception processing transaction Synchronization after completion error.


      Here is the stacktrace:



      Hibernate: select user_.username, user_.name as name8_, user_.password as password8_ from Customer user_ where user_.username=?
      Hibernate: insert into Booking (id, beds, checkinDate, checkoutDate, creditCard, creditCardExpiryMonth, creditCardExpiryYear, creditCardName, hotel_id, smoking, user_username) values (null, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
      Hibernate: call identity()
      Feb 24, 2009 5:00:16 PM org.jboss.seam.example.booking.HotelBookingAction confirm
      INFO: New booking: 1 for demo
      <Feb 24, 2009 5:00:16 PM EST> <Error> <HTTP Session> <BEA-100028> <Could not deserialize session data.
      javax.ejb.EJBException: Attempt to pass a reference to an EJBLocalObject to a remote client.  A local EJB component may only be accessed by clients co-located in the same ear or standalone jar file.
              at org.jboss.seam.example.booking.BookingListAction_1qiie8_BookingListImpl.writeObject(BookingListAction_1qiie8_BookingListImpl.java:359)
              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:597)
              Truncated. see log file for complete stacktrace
      >
      Feb 24, 2009 2:06:53 PM org.jboss.seam.transaction.SynchronizationRegistry afterTransactionCompletion
      SEVERE: Exception processing transaction Synchronization after completion
      org.jboss.seam.InstantiationException: Could not instantiate Seam component: bookingList
              at org.jboss.seam.Component.newInstance(Component.java:2106)
              at org.jboss.seam.Component.getInstance(Component.java:1988)
              at org.jboss.seam.Component.getInstance(Component.java:1950)
              at org.jboss.seam.core.Events.raiseEvent(Events.java:77)
              at org.jboss.seam.async.AsynchronousEvent$1.process(AsynchronousEvent.java:33)
              at org.jboss.seam.async.Asynchronous$ContextualAsynchronousRequest.run(Asynchronous.java:80)
              at org.jboss.seam.async.AsynchronousEvent.execute(AsynchronousEvent.java:27)
              at org.jboss.seam.async.TransactionSuccessEvent.afterCompletion(TransactionSuccessEvent.java:24)
              at org.jboss.seam.transaction.SynchronizationRegistry.afterTransactionCompletion(SynchronizationRegistry.java:42)
              at org.jboss.seam.transaction.EjbSynchronizations.afterCompletion(EjbSynchronizations.java:80)
              at org.jboss.seam.transaction.EjbSynchronizations_4yfxmo_Impl.afterCompletion(EjbSynchronizations_4yfxmo_Impl.java:126)
              at sun.reflect.GeneratedMethodAccessor128.invoke(Unknown Source)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
              at java.lang.reflect.Method.invoke(Method.java:597)
              at com.bea.core.repackaged.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:281)
              at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:187)
              at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:154)
              at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:126)
              at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:114)
              at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:176)
              at com.bea.core.repackaged.springframework.jee.spi.MethodInvocationVisitorImpl.visit(MethodInvocationVisitorImpl.java:15)
              at weblogic.ejb.container.injection.EnvironmentInterceptorCallbackImpl.callback(EnvironmentInterceptorCallbackImpl.java:54)
              at com.bea.core.repackaged.springframework.jee.spi.EnvironmentInterceptor.invoke(EnvironmentInterceptor.java:30)
              at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:176)
              at com.bea.core.repackaged.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
              at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:176)
              at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:126)
              at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:114)
              at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:176)
              at com.bea.core.repackaged.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:210)
              at $Proxy160.afterCompletion(Unknown Source)
              at weblogic.ejb.container.manager.StatefulSessionManager.afterCompletion(StatefulSessionManager.java:875)
              at weblogic.ejb.container.internal.TxManager$TxListener.afterCompletion(TxManager.java:995)
              at weblogic.transaction.internal.ServerSCInfo.doAfterCompletion(ServerSCInfo.java:1032)
              at weblogic.transaction.internal.ServerSCInfo.callAfterCompletions(ServerSCInfo.java:1011)
              at weblogic.transaction.internal.ServerTransactionImpl.callAfterCompletions(ServerTransactionImpl.java:2990)
              at weblogic.transaction.internal.ServerTransactionImpl.afterCommittedStateHousekeeping(ServerTransactionImpl.java:2890)
              at weblogic.transaction.internal.ServerTransactionImpl.setCommitted(ServerTransactionImpl.java:2935)
              at weblogic.transaction.internal.ServerTransactionImpl.globalRetryCommit(ServerTransactionImpl.java:2725)
              at weblogic.transaction.internal.ServerTransactionImpl.globalCommit(ServerTransactionImpl.java:2645)
              at weblogic.transaction.internal.ServerTransactionImpl.internalCommit(ServerTransactionImpl.java:282)
              at weblogic.transaction.internal.ServerTransactionImpl.commit(ServerTransactionImpl.java:230)
              at weblogic.transaction.internal.TransactionManagerImpl.commit(TransactionManagerImpl.java:283)
              at weblogic.transaction.internal.TransactionManagerImpl.commit(TransactionManagerImpl.java:277)
              at org.jboss.seam.transaction.UTTransaction.commit(UTTransaction.java:52)
              at org.jboss.seam.jsf.SeamPhaseListener.commitOrRollback(SeamPhaseListener.java:614)
              at org.jboss.seam.jsf.SeamPhaseListener.commitOrRollback(SeamPhaseListener.java:605)
              at org.jboss.seam.jsf.SeamPhaseListener.handleTransactionsAfterPhase(SeamPhaseListener.java:343)
              at org.jboss.seam.jsf.SeamPhaseListener.afterServletPhase(SeamPhaseListener.java:243)
              at org.jboss.seam.jsf.SeamPhaseListener.afterPhase(SeamPhaseListener.java:194)
              at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:278)
              at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)
              at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)
              at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
              at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
              at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:292)
              at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
              at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
              at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:83)
              at org.jboss.seam.web.IdentityFilter.doFilter(IdentityFilter.java:40)
              at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
              at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:90)
              at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
              at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:64)
              at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
              at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45)
              at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
              at org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:177)
              at org.ajax4jsf.webapp.BaseFilter.handleRequest(BaseFilter.java:267)
              at org.ajax4jsf.webapp.BaseFilter.processUploadsAndHandleRequest(BaseFilter.java:380)
              at org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:507)
              at org.jboss.seam.web.Ajax4jsfFilter.doFilter(Ajax4jsfFilter.java:56)
              at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
              at org.jboss.seam.web.HotDeployFilter.doFilter(HotDeployFilter.java:53)
              at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
              at org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:158)
              at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
              at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
              at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
              at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3496)
              at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
              at weblogic.security.service.SecurityManager.runAs(Unknown Source)
              at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2180)
              at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2086)
              at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1406)
              at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
              at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
      Caused by: javax.naming.NameNotFoundException: While trying to look up comp/env/\BookingListAction in /app/ejb/jboss-seam.jar#EjbSynchronizations.; remaining name 'comp/env/\BookingListAction'
              at weblogic.jndi.internal.BasicNamingNode.newNameNotFoundException(BasicNamingNode.java:1139)
              at weblogic.jndi.internal.ApplicationNamingNode.lookup(ApplicationNamingNode.java:144)
              at weblogic.jndi.internal.WLEventContextImpl.lookup(WLEventContextImpl.java:254)
              at weblogic.jndi.internal.WLContextImpl.lookup(WLContextImpl.java:380)
              at weblogic.jndi.factories.java.ReadOnlyContextWrapper.lookup(ReadOnlyContextWrapper.java:45)
              at weblogic.jndi.internal.AbstractURLContext.lookup(AbstractURLContext.java:130)
              at javax.naming.InitialContext.lookup(InitialContext.java:392)
              at org.jboss.seam.Component.instantiateSessionBean(Component.java:1367)
              at org.jboss.seam.Component.instantiate(Component.java:1331)
              at org.jboss.seam.Component.newInstance(Component.java:2084)
              ... 86 more





      I'm new to Seam so any assistance or insight would be most appreciated!