org.springframework.context.ApplicationContextException: Failed to start bean 'mailAdapter'; nested exception is java.lang.IllegalArgumentException: 'taskScheduler' must not be null

Stack Overflow | Wojciech | 3 months ago
  1. 0

    Java Spring Integration Mail - IllegalArgumentException: 'taskScheduler' must not be null

    Stack Overflow | 3 months ago | Wojciech
    org.springframework.context.ApplicationContextException: Failed to start bean 'mailAdapter'; nested exception is java.lang.IllegalArgumentException: 'taskScheduler' must not be null
  2. 0

    JMS message listener error

    Stack Overflow | 8 months ago | user3649231
    org.springframework.context.ApplicationContextException: Unable to start embedded container; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'tomcatEmbeddedServletContainerFactory' defined in class path resource [org/springframework/boot/autoconfigure/web/EmbeddedServletContainerAutoConfiguration$EmbeddedTomcat.class]: Initialization of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'appConfig': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: org.apache.activemq.ActiveMQConnectionFactory kr.ac.jbnu.sql.rded.config.AppConfig.amqFactory; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'amqConnectionFactory' defined in class path resource [kr/ac/jbnu/sql/rded/config/AppConfig.class]: Unsatisfied dependency expressed through constructor argument with index 0 of type [javax.jms.ConnectionFactory]: Error creating bean with name 'cachingConnectionFactory' defined in class path resource [kr/ac/jbnu/sql/rded/config/AppConfig.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.jms.connection.CachingConnectionFactory]: Circular reference involving containing bean 'appConfig' - consider declaring the factory method as static for independence from its containing instance. Factory method 'cachingConnectionFactory' threw exception; nested exception is java.lang.IllegalArgumentException: Target ConnectionFactory must not be null; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'cachingConnectionFactory' defined in class path resource [kr/ac/jbnu/sql/rded/config/AppConfig.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.jms.connection.CachingConnectionFactory]: Circular reference involving containing bean 'appConfig' - consider declaring the factory method as static for independence from its containing instance. Factory method 'cachingConnectionFactory' threw exception; nested exception is java.lang.IllegalArgumentException: Target ConnectionFactory must not be null
  3. Speed up your debug routine!

    Automated exception search integrated into your IDE

  4. 0

    GitHub comment 10#249454159

    GitHub | 2 months ago | MelisaLang
    java.lang.IllegalArgumentException: HTTP URL must not be null
  5. 0

    RemoteFileTemplate throws 'remoteDirectoryExpression' is required when using SftpOutboundGateway

    Stack Overflow | 1 year ago | Jimmersons
    java.lang.IllegalArgumentException: 'remoteDirectoryExpression' is required
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. java.lang.IllegalArgumentException

    'taskScheduler' must not be null

    at org.springframework.util.Assert.notNull()
  2. Spring Core
    Assert.notNull
    1. org.springframework.util.Assert.notNull(Assert.java:115)
    1 frame
  3. org.springframework.integration
    ImapIdleChannelAdapter.doStart
    1. org.springframework.integration.mail.ImapIdleChannelAdapter.doStart(ImapIdleChannelAdapter.java:158)
    1 frame
  4. Spring Integration Core
    AbstractEndpoint.start
    1. org.springframework.integration.endpoint.AbstractEndpoint.start(AbstractEndpoint.java:94)
    1 frame
  5. Spring Context
    AnnotationConfigApplicationContext.<init>
    1. org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:173)
    2. org.springframework.context.support.DefaultLifecycleProcessor.access$200(DefaultLifecycleProcessor.java:51)
    3. org.springframework.context.support.DefaultLifecycleProcessor$LifecycleGroup.start(DefaultLifecycleProcessor.java:346)
    4. org.springframework.context.support.DefaultLifecycleProcessor.startBeans(DefaultLifecycleProcessor.java:149)
    5. org.springframework.context.support.DefaultLifecycleProcessor.onRefresh(DefaultLifecycleProcessor.java:112)
    6. org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:874)
    7. org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:544)
    8. org.springframework.context.annotation.AnnotationConfigApplicationContext.<init>(AnnotationConfigApplicationContext.java:84)
    8 frames
  6. Unknown
    Main.main
    1. Main.main(Main.java:13)
    1 frame
  7. Java RT
    Method.invoke
    1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    4. java.lang.reflect.Method.invoke(Method.java:498)
    4 frames
  8. IDEA
    AppMain.main
    1. com.intellij.rt.execution.application.AppMain.main(AppMain.java:147)
    1 frame