org.springframework.beans.factory.BeanCreationException

Error creating bean with name 'dataSourceInitializerPostProcessor': Injection of autowired dependencies failed; nested exception is java.lang.NoSuchMethodError: org.springframework.core.annotation.AnnotatedElementUtils.forAnnotations([Ljava/lang/annotation/Annotation;)Ljava/lang/reflect/AnnotatedElement;


Solutions on the web19705

Solution icon of stackoverflow
Error creating bean with name 'dataSourceInitializerPostProcessor': Injection of autowired dependencies failed; nested exception is java.lang.NoSuchMethodError: org.springframework.core.annotation.AnnotatedElementUtils.forAnnotations([Ljava/lang/annotation/Annotation;)Ljava/lang/reflect/AnnotatedElement;

Solution icon of stackoverflow
Error creating bean with name 'org.springframework.data.repository.core.support.RepositoryInterfaceAwareBeanPostProcessor#0': Initialization of bean failed; nested exception is java.lang.NoSuchMethodError: org.springframework.core.annotation.AnnotationUtils.getAnnotation(Ljava/lang/reflect/AnnotatedElement;Ljava/lang/Class;)Ljava/lang/annotation/Annotation;

Solution icon of web
Error creating bean with name 'org.springframework.data.repository.core.support.RepositoryInterfaceAwareBeanPostProcessor#0': Initialization of bean failed; nested exception is java.lang.NoSuchMethodError: org.springframework.core.annotation.AnnotationUtils.getAnnotation(Ljava/lang/reflect/AnnotatedElement;Ljava/lang/Class;)Ljava/lang/annotation/Annotation;

Solution icon of stackoverflow
Error creating bean with name 'org.springframework.transaction.annotation.AnnotationTransactionAttributeSource#0': Initialization of bean failed; nested exception is java.lang.NoSuchMethodError: org.springframework.core.annotation.AnnotationUtils.getAnnotation(Ljava/lang/reflect/AnnotatedElement;Ljava/lang/Class;)Ljava/lang/annotation/Annotation;

Solution icon of web
Error creating bean with name 'org.springframework.data.repository.core.support.RepositoryInterfaceAwareBeanPostProcessor#0': Initialization of bean failed; nested exception is java.lang.NoSuchMethodError: org.springframework.core.annotation.AnnotationUtils.getAnnotation(Ljava/lang/reflect/AnnotatedElement;Ljava/lang/Class;)Ljava/lang/annotation/Annotation;

Solution icon of web
Error creating bean with name 'org.springframework.data.repository.core.support.RepositoryInterfaceAwareBeanPostProcessor#0': Initialization of bean failed; nested exception is java.lang.NoSuchMethodError: org.springframework.core.annotation.AnnotationUtils.getAnnotation(Ljava/lang/reflect/AnnotatedElement;Ljava/lang/Class;)Ljava/lang/annotation/Annotation;

Solution icon of stackoverflow
Error creating bean with name 'jpaMappingContext': Invocation of init method failed; nested exception is java.lang.NoSuchMethodError: org.springframework.core.annotation.AnnotatedElementUtils.findMergedAnnotation(Ljava/lang/reflect/AnnotatedElement;Ljava/lang/Class;)Ljava/lang/annotation/Annotation;

Solution icon of stackoverflow
Error creating bean with name 'messageSource' defined in ServletContext resource [/WEB-INF/spring-servlet.xml]: Initialization of bean failed; nested exception is java.lang.NoSuchMethodError: org.springframework.core.annotation.AnnotationUtils.getAnnotation(Ljava/lang/reflect/AnnotatedElement;Ljava/lang/Class;)Ljava/lang/annotation/Annotation;

Solution icon of web
Error creating bean with name 'messageSource' defined in ServletContext resource [/WEB-INF/spring-servlet.xml]: Initialization of bean failed; nested exception is java.lang.NoSuchMethodError: org.springframework.core.annotation.AnnotationUtils.getAnnotation(Ljava/lang/reflect/AnnotatedElement;Ljava/lang/Class;)Ljava/lang/annotation/Annotation;

Solution icon of stackoverflow
Error creating bean with name 'requestMappingHandlerMapping' defined in class org.springframework.web.servlet.config.annotation.DelegatingWebMvcConfiguration: Invocation of init method failed; nested exception is java.lang.NoSuchMethodError: org.springframework.core.annotation.AnnotatedElementUtils.findMergedAnnotation(Ljava/lang/reflect/AnnotatedElement;Ljava/lang/Class;)Ljava/lang/annotation/Annotation;

Stack trace

  • org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSourceInitializerPostProcessor': Injection of autowired dependencies failed; nested exception is java.lang.NoSuchMethodError: org.springframework.core.annotation.AnnotatedElementUtils.forAnnotations([Ljava/lang/annotation/Annotation;)Ljava/lang/reflect/AnnotatedElement; at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:372)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1225)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:552)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:483)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.context.support.PostProcessorRegistrationDelegate.registerBeanPostProcessors(PostProcessorRegistrationDelegate.java:228)[spring-context-4.2.5.RELEASE.jar:4.2.5.RELEASE] at org.springframework.context.support.AbstractApplicationContext.registerBeanPostProcessors(AbstractApplicationContext.java:687)[spring-context-4.2.5.RELEASE.jar:4.2.5.RELEASE] at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:523)[spring-context-4.2.5.RELEASE.jar:4.2.5.RELEASE] at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:122)[spring-boot-1.4.3.RELEASE.jar:1.4.3.RELEASE] at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:761)[spring-boot-1.4.3.RELEASE.jar:1.4.3.RELEASE] at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:371)[spring-boot-1.4.3.RELEASE.jar:1.4.3.RELEASE] at org.springframework.boot.SpringApplication.run(SpringApplication.java:315)[spring-boot-1.4.3.RELEASE.jar:1.4.3.RELEASE] at org.springframework.boot.SpringApplication.run(SpringApplication.java:1186)[spring-boot-1.4.3.RELEASE.jar:1.4.3.RELEASE] at org.springframework.boot.SpringApplication.run(SpringApplication.java:1175)[spring-boot-1.4.3.RELEASE.jar:1.4.3.RELEASE] at org.resttest.hello.Application.main(Application.java:12)[classes/:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[na:1.8.0_60] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)[na:1.8.0_60] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[na:1.8.0_60] at java.lang.reflect.Method.invoke(Method.java:497)[na:1.8.0_60] at com.intellij.rt.execution.application.AppMain.main(AppMain.java:147)[idea_rt.jar:na] Caused by: java.lang.NoSuchMethodError: org.springframework.core.annotation.AnnotatedElementUtils.forAnnotations([Ljava/lang/annotation/Annotation;)Ljava/lang/reflect/AnnotatedElement; at org.springframework.beans.factory.annotation.QualifierAnnotationAutowireCandidateResolver.findValue(QualifierAnnotationAutowireCandidateResolver.java:332)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.beans.factory.annotation.QualifierAnnotationAutowireCandidateResolver.getSuggestedValue(QualifierAnnotationAutowireCandidateResolver.java:317)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1081)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1064)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:585)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:88)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:366)[spring-beans-4.3.5.RELEASE.jar:4.3.5.RELEASE] ... 22 more

Write tip

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

Users with the same issue

Samebug visitor profile picture
Unknown user
Once, 1 year ago