0 Replies Latest reply on Apr 16, 2007 8:55 AM by Nathaniel Stoddard

    ClassNotFoundException while invoking EL function during ren

    Nathaniel Stoddard Newbie

      I wrote a simple EL function to retrieve the clientId of a UIComponentBase object -- I'm generating some javascript. The first time I load the page (without a submit), the page generates just fine, including the javascript output that successfully invoked my EL function from a h:outputText element.

      However, when I submit the form it throws a ClassNotFoundException (for my EL function class) and generally freaks out after that. Now, obviously it should be able to find the class since it managed to find it on the initial rendering of the page.

      Am I missing something about using EL functions in a JSF tag?

      [#|2007-04-16T08:48:20.964-0400|WARNING|sun-appserver-pe9.0|javax.enterprise.system.stream.err|_ThreadID=13;_ThreadName=httpWorkerThread-8080-0;_RequestID=4b5ea96a-bb72-4f91-b3d8-b6e133212a32;|
      java.lang.ClassNotFoundException: biz.apexsurvey.tags.jsf.functions.ClientIdFunctions
       at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
       at java.security.AccessController.doPrivileged(Native Method)
       at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
       at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
       at com.sun.appserv.server.util.ASURLClassLoader.loadClass(ASURLClassLoader.java:100)
       at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
       at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
       at java.lang.Class.forName0(Native Method)
       at java.lang.Class.forName(Class.java:169)
       at com.sun.el.lang.FunctionMapperImpl$Function.getMethod(FunctionMapperImpl.java:167)
       at com.sun.el.lang.FunctionMapperImpl.resolveFunction(FunctionMapperImpl.java:59)
       at com.sun.el.parser.AstFunction.getValue(AstFunction.java:91)
       at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:192)
       at javax.faces.component.UIOutput.getValue(UIOutput.java:173)
       at com.sun.faces.renderkit.html_basic.HtmlBasicInputRenderer.getValue(HtmlBasicInputRenderer.java:189)
       at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.getCurrentValue(HtmlBasicRenderer.java:320)
       at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeEnd(HtmlBasicRenderer.java:200)
       at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:833)
       at javax.faces.component.UIComponent.encodeAll(UIComponent.java:896)
       at javax.faces.render.Renderer.encodeChildren(Renderer.java:137)
       at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:809)
       at javax.faces.component.UIComponent.encodeAll(UIComponent.java:886)
       at javax.faces.component.UIComponent.encodeAll(UIComponent.java:892)
       at com.sun.faces.application.ViewHandlerImpl.doRenderView(ViewHandlerImpl.java:244)
       at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:175)
       at org.jboss.seam.jsf.SeamViewHandler.renderView(SeamViewHandler.java:59)
       at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:106)
       at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)
       at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:144)
       at javax.faces.webapp.FacesServlet.service(FacesServlet.java:245)
       at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:397)
       at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:278)
       at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
       at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:536)
       at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:240)
       at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:179)
       at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
       at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:73)
       at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:182)
       at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
       at com.sun.enterprise.web.VirtualServerPipeline.invoke(VirtualServerPipeline.java:120)
       at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:939)
       at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:137)
       at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
       at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:536)
       at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:939)
       at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:239)
       at com.sun.enterprise.web.connector.grizzly.ProcessorTask.invokeAdapter(ProcessorTask.java:667)
       at com.sun.enterprise.web.connector.grizzly.ProcessorTask.processNonBlocked(ProcessorTask.java:574)
       at com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:844)
       at com.sun.enterprise.web.connector.grizzly.ReadTask.executeProcessorTask(ReadTask.java:287)
       at com.sun.enterprise.web.connector.grizzly.ReadTask.doTask(ReadTask.java:212)
       at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:252)
       at com.sun.enterprise.web.connector.grizzly.WorkerThread.run(WorkerThread.java:75)
      |#]
      
      [#|2007-04-16T08:48:20.967-0400|WARNING|sun-appserver-pe9.0|javax.enterprise.resource.webcontainer.jsf.lifecycle|_ThreadID=13;_ThreadName=httpWorkerThread-8080-0;_RequestID=4b5ea96a-bb72-4f91-b3d8-b6e133212a32;|executePhase(RENDER_RESPONSE 6,com.sun.faces.context.FacesContextImpl@5ef727) threw exception
      javax.faces.FacesException: javax.el.ELException: Function 'cu:getClientId' not found
       at javax.faces.component.UIOutput.getValue(UIOutput.java:176)
       at com.sun.faces.renderkit.html_basic.HtmlBasicInputRenderer.getValue(HtmlBasicInputRenderer.java:189)
       at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.getCurrentValue(HtmlBasicRenderer.java:320)
       at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeEnd(HtmlBasicRenderer.java:200)
       at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:833)
       at javax.faces.component.UIComponent.encodeAll(UIComponent.java:896)
       at javax.faces.render.Renderer.encodeChildren(Renderer.java:137)
       at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:809)
       at javax.faces.component.UIComponent.encodeAll(UIComponent.java:886)
       at javax.faces.component.UIComponent.encodeAll(UIComponent.java:892)
       at com.sun.faces.application.ViewHandlerImpl.doRenderView(ViewHandlerImpl.java:244)
       at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:175)
       at org.jboss.seam.jsf.SeamViewHandler.renderView(SeamViewHandler.java:59)
       at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:106)
       at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)
       at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:144)
       at javax.faces.webapp.FacesServlet.service(FacesServlet.java:245)
       at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:397)
       at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:278)
       at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
       at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:536)
       at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:240)
       at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:179)
       at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
       at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:73)
       at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:182)
       at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
       at com.sun.enterprise.web.VirtualServerPipeline.invoke(VirtualServerPipeline.java:120)
       at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:939)
       at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:137)
       at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
       at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:536)
       at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:939)
       at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:239)
       at com.sun.enterprise.web.connector.grizzly.ProcessorTask.invokeAdapter(ProcessorTask.java:667)
       at com.sun.enterprise.web.connector.grizzly.ProcessorTask.processNonBlocked(ProcessorTask.java:574)
       at com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:844)
       at com.sun.enterprise.web.connector.grizzly.ReadTask.executeProcessorTask(ReadTask.java:287)
       at com.sun.enterprise.web.connector.grizzly.ReadTask.doTask(ReadTask.java:212)
       at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:252)
       at com.sun.enterprise.web.connector.grizzly.WorkerThread.run(WorkerThread.java:75)
      Caused by: javax.el.ELException: Function 'cu:getClientId' not found
       at com.sun.el.parser.AstFunction.getValue(AstFunction.java:93)
       at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:192)
       at javax.faces.component.UIOutput.getValue(UIOutput.java:173)
       ... 40 more
      |#]
      
      [#|2007-04-16T08:48:20.972-0400|SEVERE|sun-appserver-pe9.0|javax.enterprise.system.container.web|_ThreadID=13;_ThreadName=httpWorkerThread-8080-0;_RequestID=4b5ea96a-bb72-4f91-b3d8-b6e133212a32;|StandardWrapperValve[faces-servlet]: Servlet.service() for servlet faces-servlet threw exception
      javax.el.ELException: Function 'cu:getClientId' not found
       at com.sun.el.parser.AstFunction.getValue(AstFunction.java:93)
       at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:192)
       at javax.faces.component.UIOutput.getValue(UIOutput.java:173)
       at com.sun.faces.renderkit.html_basic.HtmlBasicInputRenderer.getValue(HtmlBasicInputRenderer.java:189)
       at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.getCurrentValue(HtmlBasicRenderer.java:320)
       at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeEnd(HtmlBasicRenderer.java:200)
       at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:833)
       at javax.faces.component.UIComponent.encodeAll(UIComponent.java:896)
       at javax.faces.render.Renderer.encodeChildren(Renderer.java:137)
       at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:809)
       at javax.faces.component.UIComponent.encodeAll(UIComponent.java:886)
       at javax.faces.component.UIComponent.encodeAll(UIComponent.java:892)
       at com.sun.faces.application.ViewHandlerImpl.doRenderView(ViewHandlerImpl.java:244)
       at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:175)
       at org.jboss.seam.jsf.SeamViewHandler.renderView(SeamViewHandler.java:59)
       at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:106)
       at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)
       at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:144)
       at javax.faces.webapp.FacesServlet.service(FacesServlet.java:245)
       at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:397)
       at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:278)
       at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
       at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:536)
       at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:240)
       at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:179)
       at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
       at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:73)
       at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:182)
       at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
       at com.sun.enterprise.web.VirtualServerPipeline.invoke(VirtualServerPipeline.java:120)
       at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:939)
       at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:137)
       at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
       at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:536)
       at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:939)
       at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:239)
       at com.sun.enterprise.web.connector.grizzly.ProcessorTask.invokeAdapter(ProcessorTask.java:667)
       at com.sun.enterprise.web.connector.grizzly.ProcessorTask.processNonBlocked(ProcessorTask.java:574)
       at com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:844)
       at com.sun.enterprise.web.connector.grizzly.ReadTask.executeProcessorTask(ReadTask.java:287)
       at com.sun.enterprise.web.connector.grizzly.ReadTask.doTask(ReadTask.java:212)
       at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:252)
       at com.sun.enterprise.web.connector.grizzly.WorkerThread.run(WorkerThread.java:75)
      |#]