[jboss-user] [JBoss Seam] - Re: EL-exceptions in email render from async class

Frippe do-not-reply at jboss.com
Wed Aug 15 10:55:33 EDT 2007


sorry...
I pasted the code I was testing. . .

The correct XHTML should have been

<m:message xmlns="http://www.w3.org/1999/xhtml"
  |     xmlns:m="http://jboss.com/products/seam/mail"
  |     xmlns:h="http://java.sun.com/jsf/html">
  |   
  |     <m:from name="Påminnelsemailet" address="admin at two.se" />
  |     <m:to name="#{p.fullName}">#{p.email}</m:to>
  |     <m:subject>Glöm inte. . .</m:subject>
  |     
  |     <m:body>
  |         <p><h:outputText value="Hej #{p.name}"/>,<br/>
  |            Glöm inte att ...
  |         </p>
  |     </m:body>
  |     
  | </m:message>


This code generates EL exceptions on every #{} instance.
I've tried different approaces to get the values, but it's not clear to me how to solve this problem in a appropriate way.

Well, hmm I guess it's an NPE, but I still don't get how to outject the data I need...

  | 16:50:23,812 DEBUG [RaffleProcessor] Email sending failed: null
  | 16:50:23,828 ERROR [STDERR] java.lang.NullPointerException
  | 16:50:23,828 ERROR [STDERR]     at com.sun.faces.el.ImplicitObjectELResolver.getValue(ImplicitObjectELResolver.java:74)
  | 16:50:23,828 ERROR [STDERR]     at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:53)
  | 16:50:23,828 ERROR [STDERR]     at com.sun.faces.el.FacesCompositeELResolver.getValue(FacesCompositeELResolver.java:64)
  | 16:50:23,828 ERROR [STDERR]     at org.jboss.el.parser.AstIdentifier.getValue(AstIdentifier.java:44)
  | 16:50:23,843 ERROR [STDERR]     at org.jboss.el.parser.AstValue.getValue(AstValue.java:63)
  | 16:50:23,843 ERROR [STDERR]     at org.jboss.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:186)
  | 16:50:23,843 ERROR [STDERR]     at com.sun.facelets.el.TagValueExpression.getValue(TagValueExpression.java:71)
  | 16:50:23,859 ERROR [STDERR]     at javax.faces.component.ValueBindingValueExpressionAdapter.getValue(ValueBindingValueExpressionAdapter.java:102)
  | 16:50:23,859 ERROR [STDERR]     at org.jboss.seam.mail.ui.MailComponent.getValue(MailComponent.java:170)
  | 16:50:23,859 ERROR [STDERR]     at org.jboss.seam.mail.ui.MailComponent.getString(MailComponent.java:149)
  | 16:50:23,859 ERROR [STDERR]     at org.jboss.seam.mail.ui.AddressComponent.getName(AddressComponent.java:75)
  | 16:50:23,859 ERROR [STDERR]     at org.jboss.seam.mail.ui.AddressComponent.getInternetAddress(AddressComponent.java:36)
  | 16:50:23,875 ERROR [STDERR]     at org.jboss.seam.mail.ui.RecipientAddressComponent.encodeBegin(RecipientAddressComponent.java:25)
  | 16:50:23,875 ERROR [STDERR]     at org.jboss.seam.ui.util.JSF.renderChild(JSF.java:172)
  | 16:50:23,875 ERROR [STDERR]     at org.jboss.seam.ui.util.JSF.renderChildren(JSF.java:163)
  | 16:50:23,875 ERROR [STDERR]     at org.jboss.seam.mail.ui.UIMessage.encodeChildren(UIMessage.java:165)
  | 16:50:23,890 ERROR [STDERR]     at org.jboss.seam.ui.util.JSF.renderChild(JSF.java:175)
  | 16:50:23,890 ERROR [STDERR]     at org.jboss.seam.ui.util.JSF.renderChildren(JSF.java:163)
  | 16:50:23,890 ERROR [STDERR]     at org.jboss.seam.ui.facelet.FaceletsRenderer.renderFacelet(FaceletsRenderer.java:149)
  | 16:50:23,890 ERROR [STDERR]     at org.jboss.seam.ui.facelet.FaceletsRenderer.render(FaceletsRenderer.java:113)
  | 16:50:23,890 ERROR [STDERR]     at se.two.reminder.actions.EmailProcessor.scheduleSend(EmailProcessor.java:125)
  | 16:50:23,906 ERROR [STDERR]     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  | 16:50:23,906 ERROR [STDERR]     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
  | 16:50:23,906 ERROR [STDERR]     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
  | 16:50:23,906 ERROR [STDERR]     at java.lang.reflect.Method.invoke(Method.java:585)
  | 16:50:23,906 ERROR [STDERR]     at org.jboss.seam.util.Reflections.invoke(Reflections.java:21)
  | 16:50:23,906 ERROR [STDERR]     at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:31)
  | 16:50:23,921 ERROR [STDERR]     at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:56)
  | 16:50:23,921 ERROR [STDERR]     at org.jboss.seam.transaction.RollbackInterceptor.aroundInvoke(RollbackInterceptor.java:31)
  | 16:50:23,921 ERROR [STDERR]     at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)
  | 16:50:23,937 ERROR [STDERR]     at org.jboss.seam.core.BijectionInterceptor.aroundInvoke(BijectionInterceptor.java:46)
  | 16:50:23,937 ERROR [STDERR]     at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)
  | 16:50:23,937 ERROR [STDERR]     at org.jboss.seam.transaction.TransactionInterceptor$1.work(TransactionInterceptor.java:38)
  | 16:50:23,937 ERROR [STDERR]     at org.jboss.seam.util.Work.workInTransaction(Work.java:39)
  | 16:50:23,937 ERROR [STDERR]     at org.jboss.seam.transaction.TransactionInterceptor.aroundInvoke(TransactionInterceptor.java:32)
  | 16:50:23,953 ERROR [STDERR]     at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)
  | 16:50:23,953 ERROR [STDERR]     at org.jboss.seam.core.MethodContextInterceptor.aroundInvoke(MethodContextInterceptor.java:42)
  | 16:50:23,953 ERROR [STDERR]     at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)
  | 16:50:23,953 ERROR [STDERR]     at org.jboss.seam.async.AsynchronousInterceptor.aroundInvoke(AsynchronousInterceptor.java:42)
  | 16:50:23,953 ERROR [STDERR]     at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)
  | 16:50:23,968 ERROR [STDERR]     at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:106)
  | 16:50:23,968 ERROR [STDERR]     at org.jboss.seam.intercept.JavaBeanInterceptor.interceptInvocation(JavaBeanInterceptor.java:155)
  | 16:50:23,968 ERROR [STDERR]     at org.jboss.seam.intercept.JavaBeanInterceptor.invoke(JavaBeanInterceptor.java:91)
  | 16:50:23,968 ERROR [STDERR]     at se.two.reminder.actions.EmailProcessor_$$_javassist_3.scheduleSend(EmailProcessor_$$_javassist_3.java)
  | 16:50:23,968 ERROR [STDERR]     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  | 16:50:23,984 ERROR [STDERR]     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
  | 16:50:23,984 ERROR [STDERR]     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
  | 16:50:23,984 ERROR [STDERR]     at java.lang.reflect.Method.invoke(Method.java:585)
  | 16:50:23,984 ERROR [STDERR]     at org.jboss.seam.util.Reflections.invoke(Reflections.java:21)
  | 16:50:23,984 ERROR [STDERR]     at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:124)
  | 16:50:23,984 ERROR [STDERR]     at org.jboss.seam.async.AsynchronousInvocation.call(AsynchronousInvocation.java:52)
  | 16:50:24,000 ERROR [STDERR]     at org.jboss.seam.async.Asynchronous.executeInContexts(Asynchronous.java:76)
  | 16:50:24,000 ERROR [STDERR]     at org.jboss.seam.async.Asynchronous.execute(Asynchronous.java:45)
  | 16:50:24,000 ERROR [STDERR]     at org.jboss.seam.async.QuartzDispatcher$QuartzJob.execute(QuartzDispatcher.java:289)
  | 16:50:24,000 ERROR [STDERR]     at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
  | 16:50:24,015 ERROR [STDERR]     at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:529)
  | 


Btw...
I am running on Seam 2.0.0 B1 nightly build 111 - which works nicely in all other aspects :-)


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

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




More information about the jboss-user mailing list