[jboss-user] [JBoss Seam] - No injection on my session bean

ivan.indrawan do-not-reply at jboss.com
Mon May 28 17:34:58 EDT 2007


Hi there,

I got the following problem on my Seam application. Looking at the error, it seems my properties are not injected by Seam. Thanks beforehand for your help.

The application is to register new user before enabling the user to login to the system. 

When clicking "register" on the registration page, debug page appear with the following:

Exception during request processing: javax.servlet.ServletException: /registerUser.xhtml @26,72 value="#{registerUser.verify}": Exception getting value of property verify of base of type : org.javassist.tmp.java.lang.Object_$$_javassist_5

javax.faces.webapp.FacesServlet.service(FacesServlet.java:152)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:63)
org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57)
org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)
org.jboss.seam.debug.hot.HotDeployFilter.doFilter(HotDeployFilter.java:60)
org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)
org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45)
org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)
org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:79)
org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)
org.jboss.seam.web.SeamFilter.doFilter(SeamFilter.java:84)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
org.ajax4jsf.framework.ajax.xmlfilter.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:96)
org.ajax4jsf.framework.ajax.xmlfilter.BaseFilter.doFilter(BaseFilter.java:220)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
java.lang.Thread.run(Thread.java:619)
.......
22:22:53,375 ERROR [ExceptionFilter] exception root cause
javax.faces.el.EvaluationException: /registerUser.xhtml @26,72 value="#{register
User.verify}": Exception getting value of property verify of base of type : org.
javassist.tmp.java.lang.Object_$$_javassist_5
        at com.sun.facelets.el.LegacyValueBinding.getValue(LegacyValueBinding.ja
va:60)
        at javax.faces.component.UIOutput.getValue(UIOutput.java:77)
        at javax.faces.component.UIInput.validate(UIInput.java:357)
        at javax.faces.component.UIInput.processValidators(UIInput.java:183)
        at javax.faces.component.UIComponentBase.processValidators(UIComponentBa
se.java:624)
        at javax.faces.component.UIForm.processValidators(UIForm.java:70)
        at javax.faces.component.UIComponentBase.processValidators(UIComponentBa
se.java:624)
        at javax.faces.component.UIComponentBase.processValidators(UIComponentBa
....

Caused by: javax.faces.el.EvaluationException: Bean: org.javassist.tmp.java.lang
.Object_$$_javassist_5, property: verify
        at org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolv
erImpl.java:442)
        at org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverI
mpl.java:82)
        at com.sun.facelets.el.LegacyELContext$LegacyELResolver.getValue(LegacyE
LContext.java:141)
        at com.sun.el.parser.AstValue.getValue(AstValue.java:125)
        at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:195)

        at com.sun.facelets.el.TagValueExpression.getValue(TagValueExpression.ja
va:71)
        at com.sun.facelets.el.LegacyValueBinding.getValue(LegacyValueBinding.ja
va:56)
        ... 52 more
Caused by: java.lang.reflect.InvocationTargetException
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolv
erImpl.java:438)
        ... 58 more
Caused by: javax.ejb.EJBTransactionRolledbackException: org.jboss.seam.RequiredE
xception: In attribute requires non-null value: registerUser.user
        at org.jboss.ejb3.tx.Ejb3TxPolicy.handleInCallerTx(Ejb3TxPolicy.java:93)

        at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:130)
        at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java
:201)
        at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.
java:101)
        at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInt
....

Caused by: org.jboss.seam.RequiredException: In attribute requires non-null valu
e: registerUser.user
        at org.jboss.seam.Component.getValueToInject(Component.java:1919)
        at org.jboss.seam.Component.injectAttributes(Component.java:1368)
        at org.jboss.seam.Component.inject(Component.java:1195)
        at org.jboss.seam.interceptors.BijectionInterceptor.aroundInvoke(Bijecti
onInterceptor.java:46)
        at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocation
Context.java:69)
        at org.jboss.seam.interceptors.MethodContextInterceptor.aroundInvoke(Met
hodContextInterceptor.java:27)
        at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocation
Context.java:69)
        at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:
103)
        at org.jboss.seam.intercept.SessionBeanInterceptor.aroundInvoke(SessionB
eanInterceptor.java:53)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationCo
ntextImpl.java:118)
        at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3Int
erceptorsInterceptor.java:63)
        at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.
java:101)
        at org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationIntercepto
r.invoke(ExtendedPersistenceContextPropagationInterceptor.java:57)
        at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.
java:101)
        at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invok
e(TransactionScopedEntityManagerInterceptor.java:54)
        at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.
java:101)
        at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsI
nterceptor.java:47)
        at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.
java:101)
        at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:126)
        ... 92 more
22:22:53,406 ERROR [DebugPageHandler] redirecting to debug page
org.jboss.seam.RequiredException: In attribute requires non-null value: register
User.user
        at org.jboss.seam.Component.getValueToInject(Component.java:1919)
        at org.jboss.seam.Component.injectAttributes(Component.java:1368)
        at org.jboss.seam.Component.inject(Component.java:1195)
        at org.jboss.seam.interceptors.BijectionInterceptor.aroundInvoke(Bijecti
onInterceptor.java:46)
        at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocation
Context.java:69)
        at org.jboss.seam.interceptors.MethodContextInterceptor.aroundInvoke(Met
hodContextInterceptor.java:27)
        at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocation
Context.java:69)
        at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:
103)

Looking at the error, it appear to me that there is either EL exception or injection error (no idea why though....) This seems to happen only in session bean... 

I have done the following as well to come up with the above conclusion:
I use seam-gen and tried the authentication (as a managed bean) and the login working properly. But when I migrate the authentication to session bean, it does not work properly and I got the same error as above.

Any help and idea is appreciated.

Cheers.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4049151#4049151

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4049151



More information about the jboss-user mailing list