Managed bean not being created
Hi,
I have a backing bean, PersonBean, that takes a bean called ServiceLocator as a managed property:
<managed-bean>
<managed-bean-name>ServiceLocator</managed-bean-name>
<managed-bean-class>com.ge.lms.service.ServiceLocator</managed-bean-class>
<managed-bean-scope>application</managed-bean-scope>
</managed-bean>
<managed-bean>
<managed-bean-name>PersonBean</managed-bean-name>
<managed-bean-class>com.ge.lms.jsf.backing.PersonBean</managed-bean-class>
<managed-bean-scope>session</managed-bean-scope>
<managed-property>
<property-name>serviceLocator</property-name>
<property-class>com.ge.lms.service.ServiceLocator</property-class>
<value>#{ServiceLocator}</value>
</managed-property>
</managed-bean>
The PersonBean is created, but throws a NullPointerException when it tries to access its ServiceLocator that should have been set by JSF. Putting a breakpoint in the constructor of ServiceLocator shows it is not being instantiated, as it is never called. I've double-checked all the class names and property names, but JSF acts like the ServiceLocator doesn't exist. Can anyone help?
Also, is it possible to have JSF validate all the bean wiring when the application is started, instead of waiting till it blows up when the bean is actually called?
Thanks,
Andrew B

