Announcement Announcement Module
Collapse
No announcement yet.
org.springframework.beans.FatalBeanException: Could not instantiate class Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • org.springframework.beans.FatalBeanException: Could not instantiate class

    I am experiencing a strange error with Spring as following:

    org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'securityServiceTarget' defined in class path resource [serviceContext.xml]: Can't resolve reference to bean 'userAccessServiceTarget' while setting property 'userAccessService'; nested exception is org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'serviceBeforeAdvisorGos' defined in class path resource [serviceContext.xml]: Can't resolve reference to bean 'serviceMethodBeforeAdviceGos' while setting property 'advice'; nested exception is org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'serviceMethodBeforeAdviceGos' defined in class path resource [serviceContext.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.FatalBeanException: Could not instantiate class [com.xx.xxx.service.ServiceMethodBeforeAdviceGos]; constructor threw exception; nested exception is java.lang.NoClassDefFoundError: com/xx/xxx/service/security/EditRightsValidatorFactory

    It's very strange because EditRightsValidatorFactory.java does exist in the package of com.xx.xxx.service.security, and is a Singleton class.

    I am new with Spring. Please help. Thanks a lot in advance.

    Winifred

  • #2
    Your setters are not available. Send context.xml and bean file.

    Comment


    • #3
      java.lang.ExceptionInInitializerError: null

      Thanks for reply. I have created a setter in the bean class, and that error is gone. Now I am experiencing another error, java.lang.ExceptionInInitializerError: null

      org.springframework.beans.FatalBeanException: Could not instantiate class [com.xx.yyy.service.zz.impl.ZzzzzzzTypeCurrDenLoade rImpl]; constructor threw exception; nested exception is java.lang.ExceptionInInitializerError: null
      java.lang.ExceptionInInitializerError

      How do I fix this error? Thanks a lot.

      Winifred

      Comment


      • #4
        This has been fixed as well. I have added setter in the bean, then the error is gone.

        Thanks again.

        Winifred

        Comment

        Working...
        X