NoSuchMethodError: org.springframework.beans.factory.xml.XmlReaderContext.getEnvironment()Lorg/springframework/core/env/Environment; With zkoss

前端 未结 5 1165
囚心锁ツ
囚心锁ツ 2021-01-17 10:13

I am facing following error,

java.lang.NoSuchMethodError: org.springframework.beans.factory.xml.XmlReaderContext.getEnvironment()Lorg/springframework/core/e         


        
5条回答
  •  温柔的废话
    2021-01-17 10:53

    This was for me a dependency compatibility problem between the spring jars and spring data.

    The versions before the error (no errors) :

    4.1.0.RELEASE
    1.6.1.RELEASE 
    

    After updating spring data to 1.10.2.RELEASE the error appends, resolved by upgrading spring version to 4.3.2.RELEASE :

    4.3.2.RELEASE
    1.10.2.RELEASE
    

    To ensure you use the correct spring version you can skip the maven declaration of the spring dependencies and keep only the spring data dependency. Or you can check in the maven repository which spring version is used by your spring data version and update consequentely.

提交回复
热议问题