Hi All,
I am using JSF for the front end and using the Spring Core, DAO and AOP for the BO and DAO layers. When i try to inject the Objects using the DI to the JSF, i am getting the following error and the objects are not getting set from the Spring.
Error Log:
javax.servlet.ServletException: Unable to create managed bean dataUploadControllerBean. The following problems were found:
- Bean or property class #{dataUploadVO} for managed bean dataUploadControllerBean cannot be found.
- Bean or property class #{dataUploadVO} for managed bean dataUploadControllerBean cannot be found.
- Bean or property class #{dataUploadVO} for managed bean dataUploadControllerBean cannot be found.
javax.faces.webapp.FacesServlet.service(FacesServl et.java:325)
org.apache.myfaces.component.html.util.ExtensionsF ilter.doFilter(ExtensionsFilter.java:112)
i have defined the respective entries correctly to integrate the JSF & Spring. But still the JSF&Spreing is not integrated successfully. Please find the configs defined and help to resolve the issue. i am stuck in this for 2 days...
Web.xml
<listener>
<listener-class>org.springframework.web.context.ContextLoade rListener</listener-class>
</listener>
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>WEB-INF/applicationContext.xml</param-value>
</context-param>
Faces-Config.xml
<application>
<el-resolver>org.springframework.web.jsf.el.SpringBean FacesELResolver</el-resolver> <!-- have used this ELResolver to injects objects from Spring-->
</application>
<managed-bean>
<managed-bean-name>dataUploadControllerBean</managed-bean-name>
<managed-bean-class>com.sgspace.model.dataupload.DataUploadContr ollerBean</managed-bean-class>
<managed-bean-scope>session</managed-bean-scope>
<managed-property>
<property-name>dataUploadBean</property-name>
<value>#{dataUploadBean}</value> <!-- Already present in the faces-config.xml--> </managed-property>
<managed-property>
<property-name>dataUploadVO</property-name>
<property-class>#{dataUploadVO}</property-class> <!-- Injected from Spring DI. This is currently not working.--><value></value>
</managed-property>
<managed-property>
<property-name>dataUploadBO</property-name>
<property-class>#{dataUploadBO}</property-class><!-- Injected from Spring DI. This is currently not working.--> <value></value>
</managed-property>
</managed-bean>
applicationContext.xml:
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://www.springframework.org/schema/p"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:tx="http://www.springframework.org/schema/tx"
xmlns:aop="http://www.springframework.org/schema/aop"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schem...ring-beans.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schem...ing-tx-2.0.xsd
http://www.springframework.org/schema/aop http://www.springframework.org/schem...ng-aop-2.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd">
<bean id="dataUploadDAO"
class="com.sgspace.dao.dataupload.DataUploadDAOImp l">
<property name="dataSource" ref="dataSource"></property>
</bean>
<bean id="dataUploadBO"
class="com.sgspace.bo.dataupload.DataUploadBOImpl" >
<property name="dataUploadDAO" ref="dataUploadDAO"></property>
</bean>
<bean id="dataUploadVO" class="com.sgspace.vo.dataupload.DataUploadVO"></bean>
</beans>
Warm Regards,
Praveen S


="http://www.springframework.org/schema/p"
Reply With Quote
