org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'confluencePluginEnabler' defined in URL [bundle://80.0:0/META-INF/spring/atlassian-plugins-components.xml]: Invocation of init method failed; nested exception is java.lang.IllegalStateException: Could not enable plugincom.atlassian.studio.confluence

Atlassian JIRA | Fabian Krämer | 5 years ago
  1. 0

    Confluence theme plugin can fail to come up. Seen in build: https://bamboo.extranet.atlassian.com/browse/JST-JST-JOBE-787 Confluence log shows: {noformat} 2011-08-30 20:12:25,573 ERROR [Spring executor 9] [plugin.osgi.factory.OsgiPlugin] onSpringContextFailed Unable to start the Spring context for plugin com.atlassian.studio.confluence.common org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'confluencePluginEnabler' defined in URL [bundle://80.0:0/META-INF/spring/atlassian-plugins-components.xml]: Invocation of init method failed; nested exception is java.lang.IllegalStateException: Could not enable plugincom.atlassian.studio.confluence at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1338) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:473) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:409) at java.security.AccessController.doPrivileged(Native Method) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:380) at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:264) at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222) at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:261) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:185) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:164) at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:429) at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:728) at org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.access$1600(AbstractDelegatedExecutionApplicationContext.java:69) at org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext$4.run(AbstractDelegatedExecutionApplicationContext.java:355) at org.springframework.osgi.util.internal.PrivilegedUtils.executeWithCustomTCCL(PrivilegedUtils.java:85) at org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.completeRefresh(AbstractDelegatedExecutionApplicationContext.java:320) at org.springframework.osgi.extender.internal.dependencies.startup.DependencyWaiterApplicationContextExecutor$CompleteRefreshTask.run(DependencyWaiterApplicationContextExecutor.java:132) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.IllegalStateException: Could not enable plugincom.atlassian.studio.confluence at com.atlassian.studio.confluence.common.ConfluencePluginEnabler.enablePlugin(ConfluencePluginEnabler.java:61) at com.atlassian.studio.confluence.common.ConfluencePluginEnabler.enableCorrectConfluencePlugin(ConfluencePluginEnabler.java:52) at com.atlassian.studio.confluence.common.ConfluencePluginEnabler.afterPropertiesSet(ConfluencePluginEnabler.java:37) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1369) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1335) ... 19 more {noformat} Immediately after calling pluginController.enablePlugins(), ConfluencePluginEnabler checks pluginAccessor.isPluginEnabled(): {code:java} private void enablePlugin(String pluginKey) { pluginController.enablePlugins(pluginKey); if (!pluginAccessor.isPluginEnabled(pluginKey)) { throw new IllegalStateException("Could not enable plugin" + pluginKey); } log.info("Enabled plugin " + pluginKey); } {code} This check verifies the plugin state, which seems to be set synchronously via the enablePlugins() call. Therefore, a theory is that another thread is disabling the plugin at the same time. There is no evidence of this in the logs, and there appears to be no logging at the Felix level for the events of interest (in {{org.apache.felix.framework.Felix.stopBundle(BundleImpl, boolean)}}). If this re-occurs: * Verify that the enablePlugins() call, when running in conjunction with {{ConfluencePluginManager}}, does indeed behave synchronously. Note that {{ConfluencePluginManager}} does not set the plugin state directly, but listens for an {{ApplicationEvent}} (see {{com.atlassian.confluence.event.ConfluenceEventPublisherManager.publish(Object)}}), which delegates to org.springframework.context.ApplicationContext. From the [Spring doc|http://static.springsource.org/spring/docs/3.1.0.M2/spring-framework-reference/html/beans.html#context-functionality-events]: "You may register as many event listeners as you wish, but note that *by default event listeners receive events synchronously*." - so it *could* be asynchronous. * Consider implementing a {{BundleListener}} that logs for OSGi events to give us more information about who could be disabling the plugin and why. This logging {{BundleListener}} will not be enabled in time if registerd via Spring DM - it must be enabled via {{BundleActivator}}.

    Atlassian JIRA | 5 years ago | Fabian Krämer
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'confluencePluginEnabler' defined in URL [bundle://80.0:0/META-INF/spring/atlassian-plugins-components.xml]: Invocation of init method failed; nested exception is java.lang.IllegalStateException: Could not enable plugincom.atlassian.studio.confluence
  2. 0

    Confluence theme plugin can fail to come up. Seen in build: https://bamboo.extranet.atlassian.com/browse/JST-JST-JOBE-787 Confluence log shows: {noformat} 2011-08-30 20:12:25,573 ERROR [Spring executor 9] [plugin.osgi.factory.OsgiPlugin] onSpringContextFailed Unable to start the Spring context for plugin com.atlassian.studio.confluence.common org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'confluencePluginEnabler' defined in URL [bundle://80.0:0/META-INF/spring/atlassian-plugins-components.xml]: Invocation of init method failed; nested exception is java.lang.IllegalStateException: Could not enable plugincom.atlassian.studio.confluence at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1338) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:473) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:409) at java.security.AccessController.doPrivileged(Native Method) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:380) at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:264) at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222) at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:261) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:185) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:164) at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:429) at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:728) at org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.access$1600(AbstractDelegatedExecutionApplicationContext.java:69) at org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext$4.run(AbstractDelegatedExecutionApplicationContext.java:355) at org.springframework.osgi.util.internal.PrivilegedUtils.executeWithCustomTCCL(PrivilegedUtils.java:85) at org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.completeRefresh(AbstractDelegatedExecutionApplicationContext.java:320) at org.springframework.osgi.extender.internal.dependencies.startup.DependencyWaiterApplicationContextExecutor$CompleteRefreshTask.run(DependencyWaiterApplicationContextExecutor.java:132) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.IllegalStateException: Could not enable plugincom.atlassian.studio.confluence at com.atlassian.studio.confluence.common.ConfluencePluginEnabler.enablePlugin(ConfluencePluginEnabler.java:61) at com.atlassian.studio.confluence.common.ConfluencePluginEnabler.enableCorrectConfluencePlugin(ConfluencePluginEnabler.java:52) at com.atlassian.studio.confluence.common.ConfluencePluginEnabler.afterPropertiesSet(ConfluencePluginEnabler.java:37) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1369) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1335) ... 19 more {noformat} Immediately after calling pluginController.enablePlugins(), ConfluencePluginEnabler checks pluginAccessor.isPluginEnabled(): {code:java} private void enablePlugin(String pluginKey) { pluginController.enablePlugins(pluginKey); if (!pluginAccessor.isPluginEnabled(pluginKey)) { throw new IllegalStateException("Could not enable plugin" + pluginKey); } log.info("Enabled plugin " + pluginKey); } {code} This check verifies the plugin state, which seems to be set synchronously via the enablePlugins() call. Therefore, a theory is that another thread is disabling the plugin at the same time. There is no evidence of this in the logs, and there appears to be no logging at the Felix level for the events of interest (in {{org.apache.felix.framework.Felix.stopBundle(BundleImpl, boolean)}}). If this re-occurs: * Verify that the enablePlugins() call, when running in conjunction with {{ConfluencePluginManager}}, does indeed behave synchronously. Note that {{ConfluencePluginManager}} does not set the plugin state directly, but listens for an {{ApplicationEvent}} (see {{com.atlassian.confluence.event.ConfluenceEventPublisherManager.publish(Object)}}), which delegates to org.springframework.context.ApplicationContext. From the [Spring doc|http://static.springsource.org/spring/docs/3.1.0.M2/spring-framework-reference/html/beans.html#context-functionality-events]: "You may register as many event listeners as you wish, but note that *by default event listeners receive events synchronously*." - so it *could* be asynchronous. * Consider implementing a {{BundleListener}} that logs for OSGi events to give us more information about who could be disabling the plugin and why. This logging {{BundleListener}} will not be enabled in time if registerd via Spring DM - it must be enabled via {{BundleActivator}}.

    Atlassian JIRA | 5 years ago | Fabian Krämer
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'confluencePluginEnabler' defined in URL [bundle://80.0:0/META-INF/spring/atlassian-plugins-components.xml]: Invocation of init method failed; nested exception is java.lang.IllegalStateException: Could not enable plugincom.atlassian.studio.confluence
  3. 0

    WebLogic + JMS + HTTP(s) tunneling | Oracle Community

    oracle.com | 1 year ago
    java.lang.IllegalStateException: Not enough cryptography available to enable a cipher suite!
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Weblogic 8.1 SSL Client Communication Problem - weblogic.developer.interest.security

    developer-works.com | 1 year ago
    java.lang.IllegalStateException: Not enough cryptography available to enable a cipher suite!
  6. 0

    Security issue connecting to weblogic 11g t3 protocol

    Stack Overflow | 1 year ago | gio10245
    java.lang.IllegalStateException: Not enough cryptography available to enable a cipher suite!

    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.IllegalStateException

      Could not enable plugincom.atlassian.studio.confluence

      at com.atlassian.studio.confluence.common.ConfluencePluginEnabler.enablePlugin()
    2. com.atlassian.studio
      ConfluencePluginEnabler.afterPropertiesSet
      1. com.atlassian.studio.confluence.common.ConfluencePluginEnabler.enablePlugin(ConfluencePluginEnabler.java:61)
      2. com.atlassian.studio.confluence.common.ConfluencePluginEnabler.enableCorrectConfluencePlugin(ConfluencePluginEnabler.java:52)
      3. com.atlassian.studio.confluence.common.ConfluencePluginEnabler.afterPropertiesSet(ConfluencePluginEnabler.java:37)
      3 frames
    3. Spring Beans
      AbstractAutowireCapableBeanFactory$1.run
      1. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1369)
      2. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1335)
      3. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:473)
      4. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:409)
      4 frames
    4. Java RT
      AccessController.doPrivileged
      1. java.security.AccessController.doPrivileged(Native Method)
      1 frame
    5. Spring Beans
      DefaultListableBeanFactory.preInstantiateSingletons
      1. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:380)
      2. org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:264)
      3. org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
      4. org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:261)
      5. org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:185)
      6. org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:164)
      7. org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:429)
      7 frames
    6. Spring Context
      AbstractApplicationContext.finishBeanFactoryInitialization
      1. org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:728)
      1 frame
    7. Spring OSGi Core
      AbstractDelegatedExecutionApplicationContext.completeRefresh
      1. org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.access$1600(AbstractDelegatedExecutionApplicationContext.java:69)
      2. org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext$4.run(AbstractDelegatedExecutionApplicationContext.java:355)
      3. org.springframework.osgi.util.internal.PrivilegedUtils.executeWithCustomTCCL(PrivilegedUtils.java:85)
      4. org.springframework.osgi.context.support.AbstractDelegatedExecutionApplicationContext.completeRefresh(AbstractDelegatedExecutionApplicationContext.java:320)
      4 frames
    8. org.springframework.osgi
      DependencyWaiterApplicationContextExecutor$CompleteRefreshTask.run
      1. org.springframework.osgi.extender.internal.dependencies.startup.DependencyWaiterApplicationContextExecutor$CompleteRefreshTask.run(DependencyWaiterApplicationContextExecutor.java:132)
      1 frame
    9. Java RT
      Thread.run
      1. java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
      2. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
      3. java.lang.Thread.run(Thread.java:662)
      3 frames