java.lang.IllegalStateException: Lifecycle Manager 'source-fail-on-start.stage1' phase 'start' does not support phase 'dispose'

MuleSoft JIRA | Esteban Wasinger | 12 months ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    *Mule throws a LifecycleException when disposing an Extension Source* * When working with Mule Extension Sources, a way to fail at start time is to to throw an exception inside {{start()}} of a Source, this exception inside the SDK is analysed and if it could not be handled, is propagated to Mule. Mule when detect this exception starts to dispose the Source, when this occur a exceptions is thrown. Stack trace: {code}ERROR 2016-02-23 14:09:35,670 [Thread-4] org.mule.construct.AbstractFlowConstruct: Exception found trying to dispose object. Shutdown will continue java.lang.IllegalStateException: Lifecycle Manager 'source-fail-on-start.stage1' phase 'start' does not support phase 'dispose' at org.mule.lifecycle.AbstractLifecycleManager.checkPhase(AbstractLifecycleManager.java:116) ~[classes/:?] at org.mule.processor.SedaStageLifecycleManager.fireDisposePhase(SedaStageLifecycleManager.java:117) ~[classes/:?] at org.mule.processor.SedaStageInterceptingMessageProcessor.dispose(SedaStageInterceptingMessageProcessor.java:429) ~[classes/:?] at org.mule.processor.chain.AbstractMessageProcessorChain.dispose(AbstractMessageProcessorChain.java:133) ~[classes/:?] at org.mule.api.lifecycle.LifecycleUtils.disposeIfNeeded(LifecycleUtils.java:252) ~[classes/:?] at org.mule.construct.AbstractFlowConstruct.disposeIfDisposable(AbstractFlowConstruct.java:330) ~[classes/:?] at org.mule.construct.AbstractPipeline.doDispose(AbstractPipeline.java:438) ~[classes/:?] at org.mule.construct.AbstractFlowConstruct$4.onTransition(AbstractFlowConstruct.java:166) ~[classes/:?] at org.mule.construct.AbstractFlowConstruct$4.onTransition(AbstractFlowConstruct.java:163) ~[classes/:?] at org.mule.lifecycle.AbstractLifecycleManager.invokePhase(AbstractLifecycleManager.java:136) ~[classes/:?] at org.mule.construct.FlowConstructLifecycleManager.fireDisposePhase(FlowConstructLifecycleManager.java:144) ~[classes/:?] at org.mule.construct.AbstractFlowConstruct.dispose(AbstractFlowConstruct.java:162) ~[classes/:?] at sun.reflect.GeneratedMethodAccessor20.invoke(Unknown Source) ~[?:?] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_66] at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_66] at org.mule.lifecycle.phases.DefaultLifecyclePhase.applyLifecycle(DefaultLifecyclePhase.java:237) ~[classes/:?] at org.mule.lifecycle.phases.MuleContextDisposePhase.applyLifecycle(MuleContextDisposePhase.java:99) ~[classes/:?] at org.mule.config.spring.SpringRegistryLifecycleManager$SpringContextDisposePhase.applyLifecycle(SpringRegistryLifecycleManager.java:132) ~[classes/:?] at org.mule.lifecycle.RegistryLifecycleCallback.doApplyLifecycle(RegistryLifecycleCallback.java:91) ~[classes/:?] at org.mule.lifecycle.RegistryLifecycleCallback.onTransition(RegistryLifecycleCallback.java:67) ~[classes/:?] at org.mule.lifecycle.RegistryLifecycleManager.invokePhase(RegistryLifecycleManager.java:138) ~[classes/:?] at org.mule.lifecycle.RegistryLifecycleManager.fireLifecycle(RegistryLifecycleManager.java:109) ~[classes/:?] at org.mule.registry.AbstractRegistry.dispose(AbstractRegistry.java:71) ~[classes/:?] at org.mule.registry.AbstractRegistryBroker$2.onTransition(AbstractRegistryBroker.java:69) ~[classes/:?] at org.mule.registry.AbstractRegistryBroker$2.onTransition(AbstractRegistryBroker.java:64) ~[classes/:?] at org.mule.lifecycle.RegistryLifecycleManager.invokePhase(RegistryLifecycleManager.java:138) ~[classes/:?] at org.mule.lifecycle.RegistryBrokerLifecycleManager.fireDisposePhase(RegistryBrokerLifecycleManager.java:82) ~[classes/:?] at org.mule.registry.AbstractRegistryBroker.dispose(AbstractRegistryBroker.java:63) ~[classes/:?] at org.mule.registry.MuleRegistryHelper.fireLifecycle(MuleRegistryHelper.java:121) ~[classes/:?] at org.mule.lifecycle.MuleContextLifecycleManager$MuleContextLifecycleCallback.onTransition(MuleContextLifecycleManager.java:91) ~[classes/:?] at org.mule.lifecycle.MuleContextLifecycleManager$MuleContextLifecycleCallback.onTransition(MuleContextLifecycleManager.java:87) ~[classes/:?] at org.mule.lifecycle.MuleContextLifecycleManager.invokePhase(MuleContextLifecycleManager.java:69) ~[classes/:?] at org.mule.lifecycle.MuleContextLifecycleManager.fireLifecycle(MuleContextLifecycleManager.java:61) ~[classes/:?] at org.mule.DefaultMuleContext.dispose(DefaultMuleContext.java:371) ~[classes/:?] at org.mule.tck.junit4.AbstractMuleContextTestCase.disposeContext(AbstractMuleContextTestCase.java:306) ~[classes/:?] at org.mule.tck.junit4.AbstractMuleContextTestCase.disposeContextPerTest(AbstractMuleContextTestCase.java:287) ~[classes/:?] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_66] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_66] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_66] at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_66] at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47) ~[junit-4.11.jar:?] at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12) ~[junit-4.11.jar:?] at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44) ~[junit-4.11.jar:?] at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:33) ~[junit-4.11.jar:?] at org.junit.rules.ExpectedException$ExpectedExceptionStatement.evaluate(ExpectedException.java:168) ~[junit-4.11.jar:?] at org.junit.rules.TestWatcher$1.evaluate(TestWatcher.java:55) ~[junit-4.11.jar:?] at org.junit.internal.runners.statements.FailOnTimeout$StatementThread.run(FailOnTimeout.java:74) ~[junit-4.11.jar:?]{code}

    MuleSoft JIRA | 12 months ago | Esteban Wasinger
    java.lang.IllegalStateException: Lifecycle Manager 'source-fail-on-start.stage1' phase 'start' does not support phase 'dispose'
  2. 0

    *Mule throws a LifecycleException when disposing an Extension Source* * When working with Mule Extension Sources, a way to fail at start time is to to throw an exception inside {{start()}} of a Source, this exception inside the SDK is analysed and if it could not be handled, is propagated to Mule. Mule when detect this exception starts to dispose the Source, when this occur a exceptions is thrown. Stack trace: {code}ERROR 2016-02-23 14:09:35,670 [Thread-4] org.mule.construct.AbstractFlowConstruct: Exception found trying to dispose object. Shutdown will continue java.lang.IllegalStateException: Lifecycle Manager 'source-fail-on-start.stage1' phase 'start' does not support phase 'dispose' at org.mule.lifecycle.AbstractLifecycleManager.checkPhase(AbstractLifecycleManager.java:116) ~[classes/:?] at org.mule.processor.SedaStageLifecycleManager.fireDisposePhase(SedaStageLifecycleManager.java:117) ~[classes/:?] at org.mule.processor.SedaStageInterceptingMessageProcessor.dispose(SedaStageInterceptingMessageProcessor.java:429) ~[classes/:?] at org.mule.processor.chain.AbstractMessageProcessorChain.dispose(AbstractMessageProcessorChain.java:133) ~[classes/:?] at org.mule.api.lifecycle.LifecycleUtils.disposeIfNeeded(LifecycleUtils.java:252) ~[classes/:?] at org.mule.construct.AbstractFlowConstruct.disposeIfDisposable(AbstractFlowConstruct.java:330) ~[classes/:?] at org.mule.construct.AbstractPipeline.doDispose(AbstractPipeline.java:438) ~[classes/:?] at org.mule.construct.AbstractFlowConstruct$4.onTransition(AbstractFlowConstruct.java:166) ~[classes/:?] at org.mule.construct.AbstractFlowConstruct$4.onTransition(AbstractFlowConstruct.java:163) ~[classes/:?] at org.mule.lifecycle.AbstractLifecycleManager.invokePhase(AbstractLifecycleManager.java:136) ~[classes/:?] at org.mule.construct.FlowConstructLifecycleManager.fireDisposePhase(FlowConstructLifecycleManager.java:144) ~[classes/:?] at org.mule.construct.AbstractFlowConstruct.dispose(AbstractFlowConstruct.java:162) ~[classes/:?] at sun.reflect.GeneratedMethodAccessor20.invoke(Unknown Source) ~[?:?] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_66] at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_66] at org.mule.lifecycle.phases.DefaultLifecyclePhase.applyLifecycle(DefaultLifecyclePhase.java:237) ~[classes/:?] at org.mule.lifecycle.phases.MuleContextDisposePhase.applyLifecycle(MuleContextDisposePhase.java:99) ~[classes/:?] at org.mule.config.spring.SpringRegistryLifecycleManager$SpringContextDisposePhase.applyLifecycle(SpringRegistryLifecycleManager.java:132) ~[classes/:?] at org.mule.lifecycle.RegistryLifecycleCallback.doApplyLifecycle(RegistryLifecycleCallback.java:91) ~[classes/:?] at org.mule.lifecycle.RegistryLifecycleCallback.onTransition(RegistryLifecycleCallback.java:67) ~[classes/:?] at org.mule.lifecycle.RegistryLifecycleManager.invokePhase(RegistryLifecycleManager.java:138) ~[classes/:?] at org.mule.lifecycle.RegistryLifecycleManager.fireLifecycle(RegistryLifecycleManager.java:109) ~[classes/:?] at org.mule.registry.AbstractRegistry.dispose(AbstractRegistry.java:71) ~[classes/:?] at org.mule.registry.AbstractRegistryBroker$2.onTransition(AbstractRegistryBroker.java:69) ~[classes/:?] at org.mule.registry.AbstractRegistryBroker$2.onTransition(AbstractRegistryBroker.java:64) ~[classes/:?] at org.mule.lifecycle.RegistryLifecycleManager.invokePhase(RegistryLifecycleManager.java:138) ~[classes/:?] at org.mule.lifecycle.RegistryBrokerLifecycleManager.fireDisposePhase(RegistryBrokerLifecycleManager.java:82) ~[classes/:?] at org.mule.registry.AbstractRegistryBroker.dispose(AbstractRegistryBroker.java:63) ~[classes/:?] at org.mule.registry.MuleRegistryHelper.fireLifecycle(MuleRegistryHelper.java:121) ~[classes/:?] at org.mule.lifecycle.MuleContextLifecycleManager$MuleContextLifecycleCallback.onTransition(MuleContextLifecycleManager.java:91) ~[classes/:?] at org.mule.lifecycle.MuleContextLifecycleManager$MuleContextLifecycleCallback.onTransition(MuleContextLifecycleManager.java:87) ~[classes/:?] at org.mule.lifecycle.MuleContextLifecycleManager.invokePhase(MuleContextLifecycleManager.java:69) ~[classes/:?] at org.mule.lifecycle.MuleContextLifecycleManager.fireLifecycle(MuleContextLifecycleManager.java:61) ~[classes/:?] at org.mule.DefaultMuleContext.dispose(DefaultMuleContext.java:371) ~[classes/:?] at org.mule.tck.junit4.AbstractMuleContextTestCase.disposeContext(AbstractMuleContextTestCase.java:306) ~[classes/:?] at org.mule.tck.junit4.AbstractMuleContextTestCase.disposeContextPerTest(AbstractMuleContextTestCase.java:287) ~[classes/:?] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_66] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_66] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_66] at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_66] at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47) ~[junit-4.11.jar:?] at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12) ~[junit-4.11.jar:?] at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44) ~[junit-4.11.jar:?] at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:33) ~[junit-4.11.jar:?] at org.junit.rules.ExpectedException$ExpectedExceptionStatement.evaluate(ExpectedException.java:168) ~[junit-4.11.jar:?] at org.junit.rules.TestWatcher$1.evaluate(TestWatcher.java:55) ~[junit-4.11.jar:?] at org.junit.internal.runners.statements.FailOnTimeout$StatementThread.run(FailOnTimeout.java:74) ~[junit-4.11.jar:?]{code}

    MuleSoft JIRA | 12 months ago | Esteban Wasinger
    java.lang.IllegalStateException: Lifecycle Manager 'source-fail-on-start.stage1' phase 'start' does not support phase 'dispose'

    Root Cause Analysis

    1. java.lang.IllegalStateException

      Lifecycle Manager 'source-fail-on-start.stage1' phase 'start' does not support phase 'dispose'

      at org.mule.lifecycle.AbstractLifecycleManager.checkPhase()
    2. Mule Core
      AbstractFlowConstruct.dispose
      1. org.mule.lifecycle.AbstractLifecycleManager.checkPhase(AbstractLifecycleManager.java:116)[classes/:?]
      2. org.mule.processor.SedaStageLifecycleManager.fireDisposePhase(SedaStageLifecycleManager.java:117)[classes/:?]
      3. org.mule.processor.SedaStageInterceptingMessageProcessor.dispose(SedaStageInterceptingMessageProcessor.java:429)[classes/:?]
      4. org.mule.processor.chain.AbstractMessageProcessorChain.dispose(AbstractMessageProcessorChain.java:133)[classes/:?]
      5. org.mule.api.lifecycle.LifecycleUtils.disposeIfNeeded(LifecycleUtils.java:252)[classes/:?]
      6. org.mule.construct.AbstractFlowConstruct.disposeIfDisposable(AbstractFlowConstruct.java:330)[classes/:?]
      7. org.mule.construct.AbstractPipeline.doDispose(AbstractPipeline.java:438)[classes/:?]
      8. org.mule.construct.AbstractFlowConstruct$4.onTransition(AbstractFlowConstruct.java:166)[classes/:?]
      9. org.mule.construct.AbstractFlowConstruct$4.onTransition(AbstractFlowConstruct.java:163)[classes/:?]
      10. org.mule.lifecycle.AbstractLifecycleManager.invokePhase(AbstractLifecycleManager.java:136)[classes/:?]
      11. org.mule.construct.FlowConstructLifecycleManager.fireDisposePhase(FlowConstructLifecycleManager.java:144)[classes/:?]
      12. org.mule.construct.AbstractFlowConstruct.dispose(AbstractFlowConstruct.java:162)[classes/:?]
      12 frames
    3. Java RT
      Method.invoke
      1. sun.reflect.GeneratedMethodAccessor20.invoke(Unknown Source)[?:?]
      2. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[?:1.8.0_66]
      3. java.lang.reflect.Method.invoke(Method.java:497)[?:1.8.0_66]
      3 frames
    4. Mule Core
      MuleContextDisposePhase.applyLifecycle
      1. org.mule.lifecycle.phases.DefaultLifecyclePhase.applyLifecycle(DefaultLifecyclePhase.java:237)[classes/:?]
      2. org.mule.lifecycle.phases.MuleContextDisposePhase.applyLifecycle(MuleContextDisposePhase.java:99)[classes/:?]
      2 frames
    5. Spring Config
      SpringRegistryLifecycleManager$SpringContextDisposePhase.applyLifecycle
      1. org.mule.config.spring.SpringRegistryLifecycleManager$SpringContextDisposePhase.applyLifecycle(SpringRegistryLifecycleManager.java:132)[classes/:?]
      1 frame
    6. Mule Core
      DefaultMuleContext.dispose
      1. org.mule.lifecycle.RegistryLifecycleCallback.doApplyLifecycle(RegistryLifecycleCallback.java:91)[classes/:?]
      2. org.mule.lifecycle.RegistryLifecycleCallback.onTransition(RegistryLifecycleCallback.java:67)[classes/:?]
      3. org.mule.lifecycle.RegistryLifecycleManager.invokePhase(RegistryLifecycleManager.java:138)[classes/:?]
      4. org.mule.lifecycle.RegistryLifecycleManager.fireLifecycle(RegistryLifecycleManager.java:109)[classes/:?]
      5. org.mule.registry.AbstractRegistry.dispose(AbstractRegistry.java:71)[classes/:?]
      6. org.mule.registry.AbstractRegistryBroker$2.onTransition(AbstractRegistryBroker.java:69)[classes/:?]
      7. org.mule.registry.AbstractRegistryBroker$2.onTransition(AbstractRegistryBroker.java:64)[classes/:?]
      8. org.mule.lifecycle.RegistryLifecycleManager.invokePhase(RegistryLifecycleManager.java:138)[classes/:?]
      9. org.mule.lifecycle.RegistryBrokerLifecycleManager.fireDisposePhase(RegistryBrokerLifecycleManager.java:82)[classes/:?]
      10. org.mule.registry.AbstractRegistryBroker.dispose(AbstractRegistryBroker.java:63)[classes/:?]
      11. org.mule.registry.MuleRegistryHelper.fireLifecycle(MuleRegistryHelper.java:121)[classes/:?]
      12. org.mule.lifecycle.MuleContextLifecycleManager$MuleContextLifecycleCallback.onTransition(MuleContextLifecycleManager.java:91)[classes/:?]
      13. org.mule.lifecycle.MuleContextLifecycleManager$MuleContextLifecycleCallback.onTransition(MuleContextLifecycleManager.java:87)[classes/:?]
      14. org.mule.lifecycle.MuleContextLifecycleManager.invokePhase(MuleContextLifecycleManager.java:69)[classes/:?]
      15. org.mule.lifecycle.MuleContextLifecycleManager.fireLifecycle(MuleContextLifecycleManager.java:61)[classes/:?]
      16. org.mule.DefaultMuleContext.dispose(DefaultMuleContext.java:371)[classes/:?]
      16 frames
    7. Mule Functional Test Framework (TCK)
      AbstractMuleContextTestCase.disposeContextPerTest
      1. org.mule.tck.junit4.AbstractMuleContextTestCase.disposeContext(AbstractMuleContextTestCase.java:306)[classes/:?]
      2. org.mule.tck.junit4.AbstractMuleContextTestCase.disposeContextPerTest(AbstractMuleContextTestCase.java:287)[classes/:?]
      2 frames
    8. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[?:1.8.0_66]
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)[?:1.8.0_66]
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[?:1.8.0_66]
      4. java.lang.reflect.Method.invoke(Method.java:497)[?:1.8.0_66]
      4 frames
    9. JUnit
      FailOnTimeout$StatementThread.run
      1. org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)[junit-4.11.jar:?]
      2. org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)[junit-4.11.jar:?]
      3. org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)[junit-4.11.jar:?]
      4. org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:33)[junit-4.11.jar:?]
      5. org.junit.rules.ExpectedException$ExpectedExceptionStatement.evaluate(ExpectedException.java:168)[junit-4.11.jar:?]
      6. org.junit.rules.TestWatcher$1.evaluate(TestWatcher.java:55)[junit-4.11.jar:?]
      7. org.junit.internal.runners.statements.FailOnTimeout$StatementThread.run(FailOnTimeout.java:74)[junit-4.11.jar:?]
      7 frames