You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Dean Hiller <de...@xsoftware.biz> on 2006/03/20 21:23:45 UTC

null pointer in myfaces....PLEASE....how to log?

I am now getting two different exceptions that both do not show up in 
tomcat logs(catalina.2006-03-20.log) at all for some reason.....

Stacktrace:
	org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:504)
	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:393)
	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

*root cause*

java.lang.NullPointerException
	javax.faces.webapp.UIComponentTag.setupResponseWriter(UIComponentTag.java:615)
	javax.faces.webapp.UIComponentTag.doStartTag(UIComponentTag.java:217)
	org.apache.myfaces.taglib.core.ViewTag.doStartTag(ViewTag.java:71)
	org.apache.jsp.tree_jsp._jspx_meth_f_view_0(tree_jsp.java:122)
	org.apache.jsp.tree_jsp._jspService(tree_jsp.java:98)
	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:332)
	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

I am also getting this one....

javax.servlet.ServletException: org.apache.jasper.JasperException
	javax.faces.webapp.FacesServlet.service(FacesServlet.java:109)
	org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122)

*root cause*

javax.faces.FacesException: org.apache.jasper.JasperException
	org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:425)
	org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:234)
	org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:300)
	javax.faces.webapp.FacesServlet.service(FacesServlet.java:95)
	org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122)




Dennis Byrne wrote:

>Explicitly setting the @ids in the page will give a more meaningful error message.  
>
>Dennis Byrne
>
>  
>
>>-----Original Message-----
>>From: Dean Hiller [mailto:dean@xsoftware.biz]
>>Sent: Monday, March 20, 2006 08:43 AM
>>To: 'MyFaces Discussion'
>>Subject: how to debug...another crptic exception
>>
>>I am getting the following error from a jsp but it doesn't say which 
>>property it can't get a value for.  Are there logs I can turn on and how?
>>thanks,
>>dean
>>
>>javax.servlet.ServletException: Could not get property value of component userRegisterForm:_id6
>>	javax.faces.webapp.FacesServlet.service(FacesServlet.java:109)
>>	org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122)
>>
>>*root cause*
>>
>>javax.faces.FacesException: Could not get property value of component userRegisterForm:_id6
>>	org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:421)
>>	org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:234)
>>	org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:300)
>>	javax.faces.webapp.FacesServlet.service(FacesServlet.java:95)
>>	org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122)
>>
>>
>>
>>
>>    
>>
>
>
>  
>


Re: solution to exception(bad error message here)

Posted by Dean Hiller <de...@xsoftware.biz>.
you have no corrupted my mind and I am bound to make the mistake now 
:).  just joking.
dean

Mike Kienenberger wrote:

>On 3/21/06, Dean Hiller <de...@xsoftware.biz> wrote:
>  
>
>>I don't know jsp notation actually, and actually below I was trying to
>>say "The solution was I named the backing bean incorrectly" not that I
>>was using jsp notation.  Sorry as I am sometimes not good at being clear
>>about this.  I was just posting the solution in case someone else ran
>>into it.
>>    
>>
>
>I believe the jsp notation is anything involving <% %> and ${}.
>Jsf notation is #{}.
>
>jsp notation would be handled by the JSP compiler, which could result
>in obscure error messages.
>
>  
>


Re: solution to exception(bad error message here)

Posted by Mike Kienenberger <mk...@gmail.com>.
On 3/21/06, Dean Hiller <de...@xsoftware.biz> wrote:
> I don't know jsp notation actually, and actually below I was trying to
> say "The solution was I named the backing bean incorrectly" not that I
> was using jsp notation.  Sorry as I am sometimes not good at being clear
> about this.  I was just posting the solution in case someone else ran
> into it.

I believe the jsp notation is anything involving <% %> and ${}.
Jsf notation is #{}.

jsp notation would be handled by the JSP compiler, which could result
in obscure error messages.

Re: solution to exception(bad error message here)

Posted by Dean Hiller <de...@xsoftware.biz>.
I don't know jsp notation actually, and actually below I was trying to 
say "The solution was I named the backing bean incorrectly" not that I 
was using jsp notation.  Sorry as I am sometimes not good at being clear 
about this.  I was just posting the solution in case someone else ran 
into it.
dean

Mike Kienenberger wrote:

>Perhaps you were referencing the bean using JSP notation instead of
>JSF notation?
>If that's the case, you'll only get errors from the container's JSP compiler.
>
>On 3/20/06, Dean Hiller <de...@xsoftware.biz> wrote:
>  
>
>>The solution to my earlier exception was I named the backing bean
>>incorrectly.  funny that I did not get bean not exist error(I think I
>>remember getting one from JSF before).  Anyways in this case I had a
>>backing bean misnamed in faces-config.xml and I get the very
>>uninformitive exception of.....(there was nothing in the tomcat logs).
>>
>>
>>javax.servlet.ServletException: org.apache.jasper.JasperException
>>    javax.faces.webapp.FacesServlet.service(FacesServlet.java:109)
>>
>>org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122)
>>
>>
>>*root cause*
>>
>>javax.faces.FacesException: org.apache.jasper.JasperException
>>
>>org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:425)
>>
>>
>>org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:234)
>>
>>
>>org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:300)
>>    javax.faces.webapp.FacesServlet.service(FacesServlet.java:95)
>>
>>org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122)
>>
>>
>>
>>
>>
>>    
>>
>
>  
>


Re: solution to exception(bad error message here)

Posted by Mike Kienenberger <mk...@gmail.com>.
Perhaps you were referencing the bean using JSP notation instead of
JSF notation?
If that's the case, you'll only get errors from the container's JSP compiler.

On 3/20/06, Dean Hiller <de...@xsoftware.biz> wrote:
> The solution to my earlier exception was I named the backing bean
> incorrectly.  funny that I did not get bean not exist error(I think I
> remember getting one from JSF before).  Anyways in this case I had a
> backing bean misnamed in faces-config.xml and I get the very
> uninformitive exception of.....(there was nothing in the tomcat logs).
>
>
> javax.servlet.ServletException: org.apache.jasper.JasperException
>     javax.faces.webapp.FacesServlet.service(FacesServlet.java:109)
>
> org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122)
>
>
> *root cause*
>
> javax.faces.FacesException: org.apache.jasper.JasperException
>
> org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:425)
>
>
> org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:234)
>
>
> org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:300)
>     javax.faces.webapp.FacesServlet.service(FacesServlet.java:95)
>
> org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122)
>
>
>
>
>

solution to exception(bad error message here)

Posted by Dean Hiller <de...@xsoftware.biz>.
The solution to my earlier exception was I named the backing bean 
incorrectly.  funny that I did not get bean not exist error(I think I 
remember getting one from JSF before).  Anyways in this case I had a 
backing bean misnamed in faces-config.xml and I get the very 
uninformitive exception of.....(there was nothing in the tomcat logs).


javax.servlet.ServletException: org.apache.jasper.JasperException
    javax.faces.webapp.FacesServlet.service(FacesServlet.java:109)
    
org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122) 


*root cause*

javax.faces.FacesException: org.apache.jasper.JasperException
    
org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:425) 

    
org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:234) 

    
org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:300)
    javax.faces.webapp.FacesServlet.service(FacesServlet.java:95)
    
org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122) 





sorry, stupid mistake!!!

Posted by Dean Hiller <de...@xsoftware.biz>.
I should have looked closer at the stack trace and the fact is does not 
go through FacesServlet at all.....sorry, stupid mistake of a newb.  I 
now get the second exception below in the FacesServlet itself.
thanks for any tips on that one,
dean


Dean Hiller wrote:

> I am now getting two different exceptions that both do not show up in 
> tomcat logs(catalina.2006-03-20.log) at all for some reason.....
>
> Stacktrace:
>     org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:504) 
>
>     org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:393) 
>
>     org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314) 
>
>     org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
>     javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
>
> *root cause*
>
> java.lang.NullPointerException
>     javax.faces.webapp.UIComponentTag.setupResponseWriter(UIComponentTag.java:615) 
>
>     javax.faces.webapp.UIComponentTag.doStartTag(UIComponentTag.java:217)
>     org.apache.myfaces.taglib.core.ViewTag.doStartTag(ViewTag.java:71)
>     org.apache.jsp.tree_jsp._jspx_meth_f_view_0(tree_jsp.java:122)
>     org.apache.jsp.tree_jsp._jspService(tree_jsp.java:98)
>     org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
>     javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
>     org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:332) 
>
>     org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314) 
>
>     org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
>     javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
>
> I am also getting this one....
>
> javax.servlet.ServletException: org.apache.jasper.JasperException
>     javax.faces.webapp.FacesServlet.service(FacesServlet.java:109)
>     org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122) 
>
>
> *root cause*
>
> javax.faces.FacesException: org.apache.jasper.JasperException
>     org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:425) 
>
>     org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:234) 
>
>     org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:300) 
>
>     javax.faces.webapp.FacesServlet.service(FacesServlet.java:95)
>     org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122) 
>
>
>
>
>
> Dennis Byrne wrote:
>
>> Explicitly setting the @ids in the page will give a more meaningful 
>> error message. 
>> Dennis Byrne
>>
>>  
>>
>>> -----Original Message-----
>>> From: Dean Hiller [mailto:dean@xsoftware.biz]
>>> Sent: Monday, March 20, 2006 08:43 AM
>>> To: 'MyFaces Discussion'
>>> Subject: how to debug...another crptic exception
>>>
>>> I am getting the following error from a jsp but it doesn't say which 
>>> property it can't get a value for.  Are there logs I can turn on and 
>>> how?
>>> thanks,
>>> dean
>>>
>>> javax.servlet.ServletException: Could not get property value of 
>>> component userRegisterForm:_id6
>>>     javax.faces.webapp.FacesServlet.service(FacesServlet.java:109)
>>>     org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122) 
>>>
>>>
>>> *root cause*
>>>
>>> javax.faces.FacesException: Could not get property value of 
>>> component userRegisterForm:_id6
>>>     org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:421) 
>>>
>>>     org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:234) 
>>>
>>>     org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:300) 
>>>
>>>     javax.faces.webapp.FacesServlet.service(FacesServlet.java:95)
>>>     org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122) 
>>>
>>>
>>>
>>>
>>>
>>>   
>>
>>
>>
>>  
>>
>