Uploaded image for project: 'Confluence Data Center'
  1. Confluence Data Center
  2. CONFSERVER-31868

Default Macro Metadata Provider plugin is disabled on startup

XMLWordPrintable

      Description

      The Default Macro Metadata Provider (plugin key: "confluence.macro.metadata.provider") will not start up after upgrading to Confluence 5.2.x or higher.

      Symptoms observed

      You may experience one or more of the following:

      • Most macros are missing in the Macro Browser
      • The Macro Browser will load indefinitely
      • The Macro Browser will fail to load, showing error "There has been an error loading the macro browser. Please try again or see your system administrator."
      • All user macros show an exclamation mark under Confluence Admin > User Macros, even if the macros have the appropriate metadata
      • Side bar stays empty when viewing a page (Since 5.6)

      Root cause

      Unclear at this time. This investigation is ongoing.

      In reviewing existing support tickets, the following stacktrace appears during Confluence startup:

      2013-12-04 13:29:20,385 ERROR [main] [atlassian.plugin.manager.DefaultPluginManager] enableConfiguredPluginModule There was an error loading the descriptor 'null' of plugin 'confluence.macro.metadata.provider'. Disabling.
      com.atlassian.spring.container.ComponentNotFoundException: Failed to find component: Error creating bean with name 'macroMetadataProviders' defined in class path resource [x]: Cannot create inner bean 'com.atlassian.confluence.macro.browser.DefaultMacroMetadataProvider#1d98320' of type [com.atlassian.confluence.macro.browser.DefaultMacroMetadataProvider] while setting bean property 'sourceList' with key [1]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'com.atlassian.confluence.macro.browser.DefaultMacroMetadataProvider#1d98320' defined in class path resource [x]: Cannot create inner bean 'com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory#14a78438' of type [com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory] while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory#14a78438' defined in class path resource [x]: Instantiation of bean failed; nested exception is org.springframework.beans.factory.BeanDefinitionStoreException: Factory method [public com.atlassian.confluence.plugin.ModuleDescriptorCache com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory.create(java.lang.Class,com.atlassian.plugin.predicate.ModuleDescriptorPredicate)] threw exception; nested exception is java.lang.NoClassDefFoundError: org/apache/lucene/search/ConstantScoreRangeQuery
      	at com.atlassian.spring.container.SpringContainerContext.getComponent(SpringContainerContext.java:79)
      	at com.atlassian.spring.container.ContainerManager.getComponent(ContainerManager.java:33)
      	at com.atlassian.confluence.plugin.descriptor.SpringComponentModuleDescriptor.enabled(SpringComponentModuleDescriptor.java:122)
      	at com.atlassian.plugin.manager.DefaultPluginManager.notifyModuleEnabled(DefaultPluginManager.java:1661)
      	at com.atlassian.confluence.plugin.ConfluencePluginManager.notifyModuleEnabled(ConfluencePluginManager.java:135)
      	at com.atlassian.plugin.manager.DefaultPluginManager.enableConfiguredPluginModule(DefaultPluginManager.java:1453)
      	at com.atlassian.plugin.manager.DefaultPluginManager.enableConfiguredPluginModules(DefaultPluginManager.java:1420)
      	at com.atlassian.plugin.manager.DefaultPluginManager.addPlugins(DefaultPluginManager.java:875)
      	at com.atlassian.confluence.plugin.ConfluencePluginManager.addPlugins(ConfluencePluginManager.java:236)
      	at com.atlassian.plugin.manager.DefaultPluginManager.init(DefaultPluginManager.java:258)
      	at com.atlassian.confluence.plugin.ConfluencePluginManager.init(ConfluencePluginManager.java:207)
      	at com.atlassian.confluence.plugin.PluginFrameworkContextListener.contextInitialized(PluginFrameworkContextListener.java:54)
      	at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4205)
      	at org.apache.catalina.core.StandardContext.start(StandardContext.java:4704)
      	at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:799)
      	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:779)
      	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:601)
      	at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:675)
      	at org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:601)
      	at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:502)
      	at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1315)
      	at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:324)
      	at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:142)
      	at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1061)
      	at org.apache.catalina.core.StandardHost.start(StandardHost.java:840)
      	at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
      	at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:463)
      	at org.apache.catalina.core.StandardService.start(StandardService.java:525)
      	at org.apache.catalina.core.StandardServer.start(StandardServer.java:754)
      	at org.apache.catalina.startup.Catalina.start(Catalina.java:595)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:601)
      	at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:289)
      	at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:414)
      Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'macroMetadataProviders' defined in class path resource [x]: Cannot create inner bean 'com.atlassian.confluence.macro.browser.DefaultMacroMetadataProvider#1d98320' of type [com.atlassian.confluence.macro.browser.DefaultMacroMetadataProvider] while setting bean property 'sourceList' with key [1]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'com.atlassian.confluence.macro.browser.DefaultMacroMetadataProvider#1d98320' defined in class path resource [x]: Cannot create inner bean 'com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory#14a78438' of type [com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory] while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory#14a78438' defined in class path resource [x]: Instantiation of bean failed; nested exception is org.springframework.beans.factory.BeanDefinitionStoreException: Factory method [public com.atlassian.confluence.plugin.ModuleDescriptorCache com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory.create(java.lang.Class,com.atlassian.plugin.predicate.ModuleDescriptorPredicate)] threw exception; nested exception is java.lang.NoClassDefFoundError: org/apache/lucene/search/ConstantScoreRangeQuery
      	at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveInnerBean(BeanDefinitionValueResolver.java:230)
      	at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:117)
      	at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveManagedList(BeanDefinitionValueResolver.java:287)
      	at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:126)
      	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1245)
      	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1010)
      	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:472)
      	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:168)
      	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:238)
      	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:185)
      	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:164)
      	at com.atlassian.spring.container.SpringContainerContext.getComponent(SpringContainerContext.java:75)
      	... 35 more
      Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'com.atlassian.confluence.macro.browser.DefaultMacroMetadataProvider#1d98320' defined in class path resource [x]: Cannot create inner bean 'com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory#14a78438' of type [com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory] while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory#14a78438' defined in class path resource [x]: Instantiation of bean failed; nested exception is org.springframework.beans.factory.BeanDefinitionStoreException: Factory method [public com.atlassian.confluence.plugin.ModuleDescriptorCache com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory.create(java.lang.Class,com.atlassian.plugin.predicate.ModuleDescriptorPredicate)] threw exception; nested exception is java.lang.NoClassDefFoundError: org/apache/lucene/search/ConstantScoreRangeQuery
      	at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveInnerBean(BeanDefinitionValueResolver.java:230)
      	at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:117)
      	at org.springframework.beans.factory.support.ConstructorResolver.resolveConstructorArguments(ConstructorResolver.java:495)
      	at org.springframework.beans.factory.support.ConstructorResolver.autowireConstructor(ConstructorResolver.java:162)
      	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireConstructor(AbstractAutowireCapableBeanFactory.java:925)
      	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:835)
      	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:440)
      	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.BeanDefinitionValueResolver.resolveInnerBean(BeanDefinitionValueResolver.java:219)
      	... 53 more
      Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory#14a78438' defined in class path resource [x]: Instantiation of bean failed; nested exception is org.springframework.beans.factory.BeanDefinitionStoreException: Factory method [public com.atlassian.confluence.plugin.ModuleDescriptorCache com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory.create(java.lang.Class,com.atlassian.plugin.predicate.ModuleDescriptorPredicate)] threw exception; nested exception is java.lang.NoClassDefFoundError: org/apache/lucene/search/ConstantScoreRangeQuery
      	at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:444)
      	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:903)
      	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:817)
      	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:440)
      	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.BeanDefinitionValueResolver.resolveInnerBean(BeanDefinitionValueResolver.java:219)
      	... 63 more
      Caused by: org.springframework.beans.factory.BeanDefinitionStoreException: Factory method [public com.atlassian.confluence.plugin.ModuleDescriptorCache com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory.create(java.lang.Class,com.atlassian.plugin.predicate.ModuleDescriptorPredicate)] threw exception; nested exception is java.lang.NoClassDefFoundError: org/apache/lucene/search/ConstantScoreRangeQuery
      	at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:127)
      	at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:435)
      	... 70 more
      Caused by: java.lang.NoClassDefFoundError: org/apache/lucene/search/ConstantScoreRangeQuery
      	at java.lang.Class.getDeclaredConstructors0(Native Method)
      	at java.lang.Class.privateGetDeclaredConstructors(Class.java:2404)
      	at java.lang.Class.getDeclaredConstructors(Class.java:1853)
      	at com.atlassian.confluence.plugin.descriptor.CustomMacroModuleDescriptor.innerHasBody(CustomMacroModuleDescriptor.java:267)
      	at com.atlassian.confluence.plugin.descriptor.CustomMacroModuleDescriptor.hasBody(CustomMacroModuleDescriptor.java:251)
      	at com.atlassian.confluence.macro.V2CompatibilityModuleDescriptorPredicate.matches(V2CompatibilityModuleDescriptorPredicate.java:20)
      	at com.atlassian.confluence.plugin.CompositeModuleDescriptorPredicate.matches(CompositeModuleDescriptorPredicate.java:33)
      	at com.atlassian.plugin.manager.DefaultPluginManager$6.apply(DefaultPluginManager.java:1087)
      	at com.atlassian.plugin.manager.DefaultPluginManager$6.apply(DefaultPluginManager.java:1084)
      	at com.google.common.collect.Iterators$7.computeNext(Iterators.java:645)
      	at com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:141)
      	at com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:136)
      	at com.google.common.collect.Iterators$5.hasNext(Iterators.java:539)
      	at com.google.common.collect.Lists.newArrayList(Lists.java:138)
      	at com.google.common.collect.ImmutableList.copyOf(ImmutableList.java:269)
      	at com.google.common.collect.ImmutableList.copyOf(ImmutableList.java:230)
      	at com.atlassian.plugin.manager.DefaultPluginManager.getModuleDescriptors(DefaultPluginManager.java:1054)
      	at com.atlassian.confluence.plugin.cached.ForwardingPluginAccessor.getModuleDescriptors(ForwardingPluginAccessor.java:68)
      	at com.atlassian.confluence.plugin.cached.EnabledModuleCachingPluginAccessor.getModuleDescriptors(EnabledModuleCachingPluginAccessor.java:27)
      	at com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory$2.getDescriptors(ModuleDescriptorCacheFactory.java:54)
      	at com.atlassian.confluence.plugin.ModuleDescriptorCache.initialize(ModuleDescriptorCache.java:118)
      	at com.atlassian.confluence.plugin.ModuleDescriptorCacheFactory.create(ModuleDescriptorCacheFactory.java:50)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:601)
      	at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:115)
      	... 71 more
      Caused by: java.lang.ClassNotFoundException: org.apache.lucene.search.ConstantScoreRangeQuery
      	at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1680)
      	at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1526)
      	at org.apache.felix.framework.ExtensionManager$ExtensionManagerModule.getClassByDelegation(ExtensionManager.java:672)
      	at org.apache.felix.framework.resolver.WireImpl.getClass(WireImpl.java:99)
      	at org.apache.felix.framework.ModuleImpl.searchImports(ModuleImpl.java:1345)
      	at org.apache.felix.framework.ModuleImpl.findClassOrResourceByDelegation(ModuleImpl.java:711)
      	at org.apache.felix.framework.ModuleImpl.access$200(ModuleImpl.java:73)
      	at org.apache.felix.framework.ModuleImpl$ModuleClassLoader.loadClass(ModuleImpl.java:1690)
      	at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
      	... 98 more
      

      The nested cause being:

      java.lang.NoClassDefFoundError: org/apache/lucene/search/ConstantScoreRangeQuery
      

      This is likely related to the Lucene search library upgrade to version 4.3 in the Confluence 5.2.x series.

      From the investigation in support tickets, this problem seems related to third-party plugins as well, perhaps due to version incompatibility.

      Workaround

      Check that all of the third-party plugins have been upgraded to the latest compatible version in accordance with https://marketplace.atlassian.com. Disable/remove any that do not have a version compatible with your Confluence version.

      In some cases we've seen, simply disabling the incompatible plugins is insufficient to resolve the issue. The plugins must be uninstalled completely. One of these is the "Adaptavist Rate Macro" plugin. Relevant KB: https://confluence.atlassian.com/display/CONFKB/Confluence+Macros+Missing+in+Macro+Browser

              onevalainen Olli Nevalainen
              rchang Robert Chang
              Votes:
              14 Vote for this issue
              Watchers:
              32 Start watching this issue

                Created:
                Updated:
                Resolved: