org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from file [C:/Rainier/GA/eclipse/workspace/Spring2.5/WebContent/WEB-INF/applicationConte xt.xml]; nested exception is java.lang.NoSuchMethodError: org.springframework.beans.MutablePropertyValues.add(Ljava/lang/String;Ljava/la ng/Object;)Lorg/springframework/beans/MutablePropertyValues;

Spring JIRA | Danny Ju | 7 years ago
  1. 0

    A user project with following context XML <beans xmlns="http://www.springframework.org/schema/beans" xmlns:tx="http://www.springframework.org/schema/tx" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx.xsd"> <!--bean post-processor for JPA annotations--> <bean class="org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor"> </bean> <!--Exception translation bean post processor--> <bean class="org.springframework.dao.annotation.PersistenceExceptionTranslationPostProcessor"> </bean> <!--Transaction manager for a single JPA EntityManager (alternative to JTA)--> <bean class="org.springframework.orm.jpa.LocalEntityManagerFactoryBean" id="entityManagerFactory"> <property name="persistenceUnitName" value="WebRainier"/> </bean> <bean class="org.springframework.orm.jpa.JpaTransactionManager" id="transactionManager"> <property name="entityManagerFactory" ref="entityManagerFactory"/> </bean> <!-- enable the configuration of transactional behavior based on annotations --> <tx:annotation-driven transaction-manager="transactionManager"/> </beans> After upgrading from Spring IDE2.2.6 into 2.3.0, an exception was thrown by SpringIDE while parsing the XML: !ENTRY org.springframework.ide.eclipse.beans.core 4 0 2010-01-07 17:51:20.125 !MESSAGE Internal Error !STACK 0 org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from file [C:/Rainier/GA/eclipse/workspace/Spring2.5/WebContent/WEB-INF/applicationConte xt.xml]; nested exception is java.lang.NoSuchMethodError: org.springframework.beans.MutablePropertyValues.add(Ljava/lang/String;Ljava/la ng/Object;)Lorg/springframework/beans/MutablePropertyValues; at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefini tions(XmlBeanDefinitionReader.java:394) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefiniti ons(XmlBeanDefinitionReader.java:316) at org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$2.loadBe anDefinitions(BeansConfig.java:338) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefiniti ons(XmlBeanDefinitionReader.java:284) at org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$3.call(B eansConfig.java:380) at org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$3.call(B eansConfig.java:1) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source) Caused by: java.lang.NoSuchMethodError: org.springframework.beans.MutablePropertyValues.add(Ljava/lang/String;Ljava/la ng/Object;)Lorg/springframework/beans/MutablePropertyValues; at org.springframework.transaction.config.AnnotationDrivenBeanDefinitionParser.re gisterTransactionManager(AnnotationDrivenBeanDefinitionParser.java:95) at org.springframework.transaction.config.AnnotationDrivenBeanDefinitionParser.ac cess$0(AnnotationDrivenBeanDefinitionParser.java:94) at org.springframework.transaction.config.AnnotationDrivenBeanDefinitionParser$Ao pAutoProxyConfigurer.configureAutoProxyCreator(AnnotationDrivenBeanDefinitionP arser.java:121) at org.springframework.transaction.config.AnnotationDrivenBeanDefinitionParser.pa rse(AnnotationDrivenBeanDefinitionParser.java:79) at org.springframework.beans.factory.xml.NamespaceHandlerSupport.parse(NamespaceH andlerSupport.java:72) at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustom Element(BeanDefinitionParserDelegate.java:1327) at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustom Element(BeanDefinitionParserDelegate.java:1317) at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.pars eBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:135) at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.regi sterBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:92) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.registerBeanDefi nitions(XmlBeanDefinitionReader.java:475) at org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$2.regist erBeanDefinitions(BeansConfig.java:351) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefini tions(XmlBeanDefinitionReader.java:372) ... 13 more The problem is caused by the AnnotationDrivenBeanDefinitionParser while parsing tx:annotation-driven element. Root cause was that the version of org.springframework.beans.MutablePropertyValues loaded by the IDE does not have add() method

    Spring JIRA | 7 years ago | Danny Ju
    org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from file [C:/Rainier/GA/eclipse/workspace/Spring2.5/WebContent/WEB-INF/applicationConte xt.xml]; nested exception is java.lang.NoSuchMethodError: org.springframework.beans.MutablePropertyValues.add(Ljava/lang/String;Ljava/la ng/Object;)Lorg/springframework/beans/MutablePropertyValues;
  2. 0

    A user project with following context XML <beans xmlns="http://www.springframework.org/schema/beans" xmlns:tx="http://www.springframework.org/schema/tx" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx.xsd"> <!--bean post-processor for JPA annotations--> <bean class="org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor"> </bean> <!--Exception translation bean post processor--> <bean class="org.springframework.dao.annotation.PersistenceExceptionTranslationPostProcessor"> </bean> <!--Transaction manager for a single JPA EntityManager (alternative to JTA)--> <bean class="org.springframework.orm.jpa.LocalEntityManagerFactoryBean" id="entityManagerFactory"> <property name="persistenceUnitName" value="WebRainier"/> </bean> <bean class="org.springframework.orm.jpa.JpaTransactionManager" id="transactionManager"> <property name="entityManagerFactory" ref="entityManagerFactory"/> </bean> <!-- enable the configuration of transactional behavior based on annotations --> <tx:annotation-driven transaction-manager="transactionManager"/> </beans> After upgrading from Spring IDE2.2.6 into 2.3.0, an exception was thrown by SpringIDE while parsing the XML: !ENTRY org.springframework.ide.eclipse.beans.core 4 0 2010-01-07 17:51:20.125 !MESSAGE Internal Error !STACK 0 org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from file [C:/Rainier/GA/eclipse/workspace/Spring2.5/WebContent/WEB-INF/applicationConte xt.xml]; nested exception is java.lang.NoSuchMethodError: org.springframework.beans.MutablePropertyValues.add(Ljava/lang/String;Ljava/la ng/Object;)Lorg/springframework/beans/MutablePropertyValues; at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefini tions(XmlBeanDefinitionReader.java:394) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefiniti ons(XmlBeanDefinitionReader.java:316) at org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$2.loadBe anDefinitions(BeansConfig.java:338) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefiniti ons(XmlBeanDefinitionReader.java:284) at org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$3.call(B eansConfig.java:380) at org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$3.call(B eansConfig.java:1) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source) Caused by: java.lang.NoSuchMethodError: org.springframework.beans.MutablePropertyValues.add(Ljava/lang/String;Ljava/la ng/Object;)Lorg/springframework/beans/MutablePropertyValues; at org.springframework.transaction.config.AnnotationDrivenBeanDefinitionParser.re gisterTransactionManager(AnnotationDrivenBeanDefinitionParser.java:95) at org.springframework.transaction.config.AnnotationDrivenBeanDefinitionParser.ac cess$0(AnnotationDrivenBeanDefinitionParser.java:94) at org.springframework.transaction.config.AnnotationDrivenBeanDefinitionParser$Ao pAutoProxyConfigurer.configureAutoProxyCreator(AnnotationDrivenBeanDefinitionP arser.java:121) at org.springframework.transaction.config.AnnotationDrivenBeanDefinitionParser.pa rse(AnnotationDrivenBeanDefinitionParser.java:79) at org.springframework.beans.factory.xml.NamespaceHandlerSupport.parse(NamespaceH andlerSupport.java:72) at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustom Element(BeanDefinitionParserDelegate.java:1327) at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustom Element(BeanDefinitionParserDelegate.java:1317) at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.pars eBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:135) at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.regi sterBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:92) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.registerBeanDefi nitions(XmlBeanDefinitionReader.java:475) at org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$2.regist erBeanDefinitions(BeansConfig.java:351) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefini tions(XmlBeanDefinitionReader.java:372) ... 13 more The problem is caused by the AnnotationDrivenBeanDefinitionParser while parsing tx:annotation-driven element. Root cause was that the version of org.springframework.beans.MutablePropertyValues loaded by the IDE does not have add() method

    Spring JIRA | 7 years ago | Danny Ju
    org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from file [C:/Rainier/GA/eclipse/workspace/Spring2.5/WebContent/WEB-INF/applicationConte xt.xml]; nested exception is java.lang.NoSuchMethodError: org.springframework.beans.MutablePropertyValues.add(Ljava/lang/String;Ljava/la ng/Object;)Lorg/springframework/beans/MutablePropertyValues;
  3. 0

    How to access Spring context from a depending project?

    Stack Overflow | 3 years ago | Edmond
    org.springframework.beans.factory.BeanDefinitionStoreException: IOException parsing XML document from class path resource [context.xml]; nested exception is java.io.FileNotFoundException: class path resource [context.xml] cannot be opened because it does not exist
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    JBoss 4.2 load javax.xml.parsers.DocumentBuilderFactory from xmlparserv2.jar?

    Stack Overflow | 3 years ago | Viv
    org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from ServletContext resource [/WEB-INF/classes/conf/applicationContext.xml]; nested exception is java.lang.ClassCastException: org.apache.xerces.jaxp.DocumentBuilderFactoryImpl cannot be cast to javax.xml.parsers.DocumentBuilderFactory
  6. 0

    Grails deployment to Glassfish and slf4j

    Stack Overflow | 4 years ago | tsure
    org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from ServletContext resource [/WEB-INF/applicationContext.xml]; nested exception is **java.lang.NoSuchMethodError: org.slf4j.spi.LocationAwareLogger.log(Lorg/slf4j/Marker;Ljava/lang/String;ILjava/lang/String;[Ljava/lang/Object;Ljava/lang/Throwable;)V**

    6 unregistered visitors
    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. org.springframework.beans.factory.BeanDefinitionStoreException

      Unexpected exception parsing XML document from file [C:/Rainier/GA/eclipse/workspace/Spring2.5/WebContent/WEB-INF/applicationConte xt.xml]; nested exception is java.lang.NoSuchMethodError: org.springframework.beans.MutablePropertyValues.add(Ljava/lang/String;Ljava/la ng/Object;)Lorg/springframework/beans/MutablePropertyValues;

      at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions()
    2. Spring Beans
      XmlBeanDefinitionReader.loadBeanDefinitions
      1. org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:394)
      2. org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:316)
      2 frames
    3. org.springframework.ide
      BeansConfig$2.loadBeanDefinitions
      1. org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$2.loadBeanDefinitions(BeansConfig.java:338)
      1 frame
    4. Spring Beans
      XmlBeanDefinitionReader.loadBeanDefinitions
      1. org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:284)
      1 frame
    5. org.springframework.ide
      BeansConfig$3.call
      1. org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$3.call(BeansConfig.java:380)
      2. org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$3.call(BeansConfig.java:1)
      2 frames
    6. Java RT
      Thread.run
      1. java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
      2. java.util.concurrent.FutureTask.run(Unknown Source)
      3. java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
      4. java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
      5. java.util.concurrent.FutureTask.run(Unknown Source)
      6. java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
      7. java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      8. java.lang.Thread.run(Unknown Source)
      8 frames