Announcement Announcement Module
No announcement yet.
Error injecting resource in faces-config Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Error injecting resource in faces-config

    Why doesn't faces-config.xml seem to inject my beans defined in applicationContext.xml when, I think, I have all the configuration set up correctly and Glassfish indicates that Spring is OK and applicationContext is parsed correctly? El-resolver, listener-class, context-param, etc.
    I have checked out many tutorials on JSF + Spring and seen the exact same pattern with my project, so I'm just wondering what went wrong. I'm using NetBeans 6.5, Spring Framework 2.5, and GlassFish v2.

    Exception Details: javax.el.ELException

    Possible Source of Error:
    Class Name: javax.el.BeanELResolver
    File Name:


    I have resorted to simply using JSF's managed-property to inject a managed-bean, which works well.


    Actually the bean being injected is a DAO with an @PersistenceContext EntityManager, and it's being injected into a Controller. I think it might actually be injected fine, just the problem with EntityManager, because when I have tried stripping the class off it and used mock data instead, it worked fine. But then I still don't see anything wrong with the way I created the EntityManager, and I have seen many tutorials on JSF + Spring do the exact same thing. Why would this work differently from DAO as a managed-bean injected via managed-property into Controller in JSF?
    Last edited by Cheerswaya; Dec 4th, 2008, 12:43 AM.