Announcement Announcement Module
Collapse
No announcement yet.
class attribute not resolved ! Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • class attribute not resolved !

    I'm getting some strange behaviour when using Spring from an ant task :

    I use this simple code :
    Code:
    ApplicationContext context = new ClassPathXmlApplicationContext(
            "Designer-context.xml");
    I've restricted my context to :
    Code:
    <beans>
        <bean id="reverse" class="java.lang.String"/>
    </beans>
    When I run my code from a "main", everything is ok, I get a bean in context of type String.

    When I run it from a ANT task (minimalist : it only runs this simple code), I get an exception :
    Code:
    java.lang.IllegalStateException&#58; Bean definition does not carry a resolved bean class
            at org.springframework.beans.factory.support.AbstractBeanDefinition.getBeanClass&#40;AbstractBeanDefinition.java&#58;205&#41;
    According to source code, this means beanClass in the BeanDefinition has not been converted to a class Object.

    WHAT'S HAPPENING ???

  • #2
    After testing on a minimalist code, this seems to be a maven problem : my ANT task is used from a maven jelly script.

    Comment

    Working...
    X