Enlightensoft's Blog

Helping in your each step

  • Categories

  • Authors

  • Advertisements

How to integrate JSF with Spring

Posted by Pankil Patel on September 17, 2010

Step 1: Add required jars into your project

Here in this example we required:

  • commons-beanutils.jar
  • commons-collections.jar
  • commons-digester.jar
  • commons-el-1.0.jar
  • jboss-faces.jar
  • jsf-api.jar
  • jsf-impl.jar
  • standard.jar

If want to add richfaces support into your application then add below jar also:

  • richfaces-api-3.2.1.GA.jar
  • richfaces-impl-3.2.1.GA.jar
  • richfaces-ui-3.2.1.GA.jar

Step 2: Edit your web.xml for jsf support

  • Add entry of context-param


  • Add FacesServlet and it’s servlet-mapping in last for their appropriate section.

<servlet-name>Faces Servlet</servlet-name>

<servlet-name>Faces Servlet</servlet-name>

If you are using Richfaces add also below filter and it’s mapping section into web.xml

<display-name>RichFaces Filter</display-name>
<servlet-name>Faces Servlet</servlet-name>

Step 3: Add faces-config.xml, faces-managed-beans.xml and faces-navigation.xml files under WEB-INF folder

For Demo and more detail download


You can use same faces-managed-beans.xml and faces-navigation.xml in this example as per your customization.

Best of luck………………………..


One Response to “How to integrate JSF with Spring”

  1. If you are using JBoss for deployment and you are getting Error:

    com.sun.faces.config.ConfigurationException: CONFIGURATION FAILED! com.sun.faces.lifecycle.LifecycleFactoryImpl cannot be cast to javax.faces.lifecycle.LifecycleFactory

    Remove your libs (jboss-faces.jar, jsf-api.jar, jsf-impl.jar) from your project and use libs from (\jboss-5.1.0.GA\server\default\deploy\jbossweb.sar\jsf-libs\) into your project

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: