Next we need JSF to integrate with Spring framework, for that we need to configure SpringBeanFacesELResolver in faces-config.xml file. Next we need is to add Spring Listener and JSF Controller Servlet in the web.xml file as shown below. ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8 `id` int(11) unsigned NOT NULL AUTO_INCREMENT, Now use below script to create the required table in database. We are using MySQL database for our example and Apache DBCP for creating simple database connection pool. Notice the JSF, Spring, Spring ORM and Hibernate dependencies. ![]() Now we must add required dependencies in our pom.xml file. Let’s start now with the project and see how each of the frameworks are glued together to achieve our goal.Ĭreate a Dynamic Web Project in Eclipse and then convert it to Maven project, so that we have basic setup ready. Below image shows our final spring jsf hibernate integration project structure.
0 Comments
Leave a Reply. |