java.lang.NoClassDefFoundError

org/springframework/beans/factory/NoUniqueBeanDefinitionException

Samebug tips4

A few things cause this exception: 1) Check if you have all jars and if they're in the correct path when running. 2) Your classpath might be broken, you can define it in the command line with "java -cp yourClassPath" or at your IDE if you're using one.

Needs to add netty-transport-native-epoll with a OS classifier to the classpath, it's not included in netty-all

Don't give up yet. Our experts can help. Paste your full stack trace to get a solution.

Solutions on the web18965

  • org/springframework/beans/factory/NoUniqueBeanDefinitionException
  • org/springframework/beans/factory/NoUniqueBeanDefinitionException
  • org/springframework/beans/factory/NoUniqueBeanDefinitionException
  • Stack trace

    • java.lang.NoClassDefFoundError: org/springframework/beans/factory/NoUniqueBeanDefinitionException at java.lang.Class.getDeclaredMethods0(Native Method) at java.lang.Class.privateGetDeclaredMethods(Class.java:2701) at java.lang.Class.getDeclaredMethods(Class.java:1975) at org.springframework.core.type.StandardAnnotationMetadata.hasAnnotatedMethods(StandardAnnotationMetadata.java:136) at org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.checkConfigurationClassCandidate(ConfigurationClassBeanDefinitionReader.java:318) at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:172) at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:142) at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:599) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:407) at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:139) at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:83) at com.main.engine.StartEngine.main(StartEngine.java:18) Caused by: java.lang.ClassNotFoundException: org.springframework.beans.factory.NoUniqueBeanDefinitionException at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ... 12 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

    Unknown user
    Once, 1 year ago
    Unknown user
    Once, 1 year ago
    364 times, 4 weeks ago
    Unknown user
    Once, 1 month ago
    5 times, 1 month ago
    1519 more bugmates