[JBoss Seam] - Re: Contexts.getApplicationContext() loses Components
by Lundegaard
anonymous wrote : I'm not sure I'm following your problem - you're saying *your* components are starting up in the wrong order, so that a component your component depends on isn't available during startup? Use @Startup(depends=) to make sure the components are started before yours.
My components don't depend on each other so the order shouldn't matter. I'd also guess I don't need to set any dependencies to startup components since I only inject the usual suspects (entityManager, facesMessages, log) into my components. The number of my my components just changed the startup order of all components which causes problems.
Depending on the entries in my META-INF/components.xml file the startup order of the components in Lifecycle#endInitialization() differs.
If the org.jboss.seam.core.ejb.component is started before the entityManagerFactory all works fine.
If the org.jboss.seam.core.ejb.component is started after the entityManagerFactory the complete startup fails with:
javax.naming.NamingException: Local server is not initialized
I fixed the problem by starting org.jboss.seam.core.ejb.component as the first component in Lifecycle#endInitialization().
Is my configuration broken or is there any other way to fix this problem?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4034266#4034266
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4034266
19 years
[JBoss Seam] - Re: clarification about propagation=
by codelion
Pete, I think you're thinking of uses of s:link with action="some.action", while...
I'm thinking of uses of s:link with view="/some.xhtml".
There is no action involved. I don't think there is a redirect. Right off to the target page with a GET from a URL, render it, done.
I want to use s:link, with all its functionality, benefits, etc. Just, please, kill that old conversation.
That said, I don't think "beforeRedirect on s:conversationPropagation" would be the answer. Right or wrong? Just trying to be correct.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4034262#4034262
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4034262
19 years
[JBoss Seam] - Gracefully Handling Timeouts
by gzoller
Hello,
My application header has a welcome message like this (where "session" is a session-scoped component).
| Welcome, #{session.loggedInUser}
|
Usually works fine, but my problem is if the session times out I either see (depending on the phases of the moon) "Welcome," (no name at all) or an exception like below.
What can I do to gracefully handle timeouts of sessions (or conversations for that matter)? Do I have control of what happens (i.e. callbacks) when timeouts occur? I'd prefer session timeouts to log out my Identity and conversation callbacks to redirect to a "conversation-neutral" page I define.
Any ideas greatly appreciated.
Greg
| javax.faces.el.EvaluationException: /layout/header.xhtml @38,94 value="Welcome, #{session.loggedInUser}": Exception getting value of property loggedInUser of base of type : org.javassist.tmp.java.lang.Object_$$_javassist_5
| at com.sun.facelets.el.LegacyValueBinding.getValue(LegacyValueBinding.java:60)
| at javax.faces.component.UIOutput.getValue(UIOutput.java:77)
| at org.apache.myfaces.shared_impl.renderkit.RendererUtils.getStringValue(RendererUtils.java:217)
| at org.apache.myfaces.shared_impl.renderkit.html.HtmlTextRendererBase.renderOutput(HtmlTextRendererBase.java:69)
| at org.apache.myfaces.shared_impl.renderkit.html.HtmlTextRendererBase.encodeEnd(HtmlTextRendererBase.java:57)
| at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:536)
| at com.sun.facelets.tag.jsf.ComponentSupport.encodeRecursive(ComponentSupport.java:252)
| at com.sun.facelets.tag.jsf.ComponentSupport.encodeRecursive(ComponentSupport.java:249)
| at com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:573)
| at org.ajax4jsf.framework.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:108)
| at org.ajax4jsf.framework.ajax.AjaxViewHandler.renderView(AjaxViewHandler.java:229)
| at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:384)
| at javax.faces.webapp.FacesServlet.service(FacesServlet.java:138)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:63)
| 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.debug.hot.HotDeployFilter.doFilter(HotDeployFilter.java:60)
| at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)
| 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.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:202)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.ajax4jsf.framework.ajax.xmlfilter.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:96)
| at org.ajax4jsf.framework.ajax.xmlfilter.BaseFilter.doFilter(BaseFilter.java:220)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
| at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
| at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
| at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
| at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
| at org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
| at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
| at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
| at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
| at java.lang.Thread.run(Unknown Source)
| Caused by: javax.faces.el.EvaluationException: Bean: org.javassist.tmp.java.lang.Object_$$_javassist_5, property: loggedInUser
| at org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolverImpl.java:442)
| at org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:82)
| at com.sun.facelets.el.LegacyELContext$LegacyELResolver.getValue(LegacyELContext.java:141)
| at com.sun.el.parser.AstValue.getValue(AstValue.java:125)
| at com.sun.el.parser.AstDeferredExpression.getValue(AstDeferredExpression.java:46)
| at com.sun.el.parser.AstCompositeExpression.getValue(AstCompositeExpression.java:51)
| at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:195)
| at com.sun.facelets.el.TagValueExpression.getValue(TagValueExpression.java:71)
| at com.sun.facelets.el.LegacyValueBinding.getValue(LegacyValueBinding.java:56)
| ... 48 more
| Caused by: java.lang.reflect.InvocationTargetException
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
| at java.lang.reflect.Method.invoke(Unknown Source)
| at org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolverImpl.java:438)
| ... 56 more
| Caused by: java.lang.RuntimeException: org.jboss.serial.exception.SerializationException: Could not create instance of com.paragon.spurs.ButtonMap - com.paragon.spurs.ButtonMap
| at org.jboss.ejb3.stateful.StatefulBeanContext.extractBeanAndInterceptors(StatefulBeanContext.java:367)
| at org.jboss.ejb3.stateful.StatefulBeanContext.getInstance(StatefulBeanContext.java:309)
| at org.jboss.injection.JndiFieldInjector.inject(JndiFieldInjector.java:61)
| at org.jboss.ejb3.stateful.StatefulContainer.invokePostActivate(StatefulContainer.java:373)
| at org.jboss.ejb3.stateful.StatefulBeanContext.postActivate(StatefulBeanContext.java:183)
| at org.jboss.ejb3.cache.simple.StatefulSessionFilePersistenceManager.activateSession(StatefulSessionFilePersistenceManager.java:312)
| at org.jboss.ejb3.cache.simple.SimpleStatefulCache.get(SimpleStatefulCache.java:265)
| at org.jboss.ejb3.stateful.StatefulInstanceInterceptor.invoke(StatefulInstanceInterceptor.java:61)
| 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:131)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:47)
| 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:203)
| at org.jboss.ejb3.stateful.StatefulLocalProxy.invoke(StatefulLocalProxy.java:98)
| at $Proxy98.getLoggedInUser(Unknown Source)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
| at java.lang.reflect.Method.invoke(Unknown Source)
| at org.jboss.seam.util.Reflections.invoke(Reflections.java:20)
| at org.jboss.seam.intercept.RootInvocationContext.proce
| 13:43:04,769 ERROR [STDERR] ed(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.interceptors.SynchronizationInterceptor.aroundInvoke(SynchronizationInterceptor.java:31)
| 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_5.getLoggedInUser(Object_$$_javassist_5.java)
| ... 61 more
| Caused by: org.jboss.serial.exception.SerializationException: Could not create instance of com.paragon.spurs.ButtonMap - com.paragon.spurs.ButtonMap
| at org.jboss.serial.classmetamodel.ClassMetaData.newInstance(ClassMetaData.java:342)
| at org.jboss.serial.persister.RegularObjectPersister.readData(RegularObjectPersister.java:239)
| at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.readObjectDescriptionFromStreaming(ObjectDescriptorFactory.java:412)
| at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.objectFromDescription(ObjectDescriptorFactory.java:82)
| at org.jboss.serial.objectmetamodel.DataContainer$DataContainerDirectInput.readObject(DataContainer.java:643)
| at org.jboss.serial.persister.RegularObjectPersister.readSlotWithFields(RegularObjectPersister.java:353)
| at org.jboss.serial.persister.RegularObjectPersister.defaultRead(RegularObjectPersister.java:273)
| at org.jboss.serial.persister.RegularObjectPersister.readData(RegularObjectPersister.java:241)
| at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.readObjectDescriptionFromStreaming(ObjectDescriptorFactory.java:412)
| at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.objectFromDescription(ObjectDescriptorFactory.java:82)
| at org.jboss.serial.objectmetamodel.DataContainer$DataContainerDirectInput.readObject(DataContainer.java:643)
| at org.jboss.serial.persister.ArrayPersister.readObjectArray(ArrayPersister.java:196)
| at org.jboss.serial.persister.ArrayPersister.readData(ArrayPersister.java:172)
| at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.readObjectDescriptionFromStreaming(ObjectDescriptorFactory.java:412)
| at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.objectFromDescription(ObjectDescriptorFactory.java:82)
| at org.jboss.serial.objectmetamodel.DataContainer$DataContainerDirectInput.readObject(DataContainer.java:643)
| at org.jboss.serial.io.JBossObjectInputStream.readObjectOverride(JBossObjectInputStream.java:163)
| at java.io.ObjectInputStream.readObject(Unknown Source)
| at org.jboss.serial.io.MarshalledObject.get(MarshalledObject.java:68)
| at org.jboss.ejb3.stateful.StatefulBeanContext.extractBeanAndInterceptors(StatefulBeanContext.java:342)
| ... 94 more
| Caused by: java.lang.InstantiationException: com.paragon.spurs.ButtonMap
| at java.lang.Class.newInstance0(Unknown Source)
| at java.lang.Class.newInstance(Unknown Source)
| at org.jboss.serial.classmetamodel.ClassMetaData.newInstance(ClassMetaData.java:334)
| ... 113 more
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4034255#4034255
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4034255
19 years