Thursday, March 22, 2012

RichFaces Error: filterStart

RichFaces has recently moved into version 4, providing compatibility with JSF 2.0.  Pretty cool.

The problem is that it can be a bit confusing when upgrading from version 3, or when following some of the slightly outdated documentation on the site.

If you've dutifully followed the getting started instructions for RichFaces when working with version 4, you probably added these lines to your web.xml file:


<filter>
     <display-name>RichFaces Filter</display-name>
     <filter-name>richfaces</filter-name>
     <filter-class>org.ajax4jsf.Filter</filter-class>
</filter>
<filter-mapping>
     <filter-name>richfaces</filter-name>
     <servlet-name>Faces Servlet</servlet-name>
     <dispatcher>REQUEST</dispatcher>
     <dispatcher>FORWARD</dispatcher>
     <dispatcher>INCLUDE</dispatcher>
</filter-mapping>

And yet you're still getting that horrible filterStart error, aren't you?  No problem, my friends.  Here's how to fix it:

Delete those lines from your web.xml.

Seriously.

The JSF 2.0 spec handles those configurations already.  By adding those lines into your web.xml you're just going to confuse the poor thing.

1 comment:

  1. I have read this post. collection of post is a nice one ..that am doing website designing company chennai india and website development company chennai india. That I will inform about your post to my friends and all the best for your future posts..

    ReplyDelete