These beans declarations do not make much sense. They are declared twice,
once in the XML (spring-engine-storage-snapshot-core-context.xml), and the
second declaration is executed through the use of annotations (@Component)
in those classes. This exception is happening because there is a
configuration in the XML saying that one bean is depending on the other.
You can simply remove lines 30-40 from the XML file to fix this.



Side note: Spring automatically build the chain of dependencies between
beans to execute the dependency injection properly. The configuration
"depends-on" you find in the XML "bean" element is to define an exotic and
not obvious dependency.


On Mon, Nov 13, 2017 at 3:48 PM, Daan Hoogland <daan.hoogl...@gmail.com>
wrote:

> I'm looking at a problem, any one recognises this on master? simulator does
> not start cleanly.
>
> [WARNING] Failed startup of context o.e.j.m.p.JettyWebAppContext@51de5efa
> {/client,file:/Users/dahn/apache/cloudstack/client/
> target/classes/META-INF/webapp/,STARTING}{file:/Users/
> dahn/apache/cloudstack/client/target/classes/META-INF/webapp/}
> org.springframework.beans.factory.BeanCreationException: Error creating
> bean with name 'snapshotDataFactoryImpl' defined in URL
> [jar:file:/Users/dahn/.m2/repository/org/apache/cloudstack/cloud-engine-
> storage-snapshot/4.11.0.0-SNAPSHOT/cloud-engine-storage-
> snapshot-4.11.0.0-SNAPSHOT.jar!/META-INF/cloudstack/core/
> spring-engine-storage-snapshot-core-context.xml]:
> Circular depends-on relationship between 'snapshotDataFactoryImpl' and
> 'volumeDataFactoryImpl'
>     at
> org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean
> (AbstractBeanFactory.java:300)
>     at
> org.springframework.beans.factory.support.AbstractBeanFactory.getBean
> (AbstractBeanFactory.java:200)
>     at
> org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean
> (AbstractBeanFactory.java:304)
>     at
> org.springframework.beans.factory.support.AbstractBeanFactory.getBean
> (AbstractBeanFactory.java:200)
>     at
> org.springframework.beans.factory.support.DefaultListableBeanFactory.
> preInstantiateSingletons
> (DefaultListableBeanFactory.java:756)
>     at
> org.springframework.context.support.AbstractApplicationContext.
> finishBeanFactoryInitialization
> (AbstractApplicationContext.java:868)
>     at
> org.springframework.context.support.AbstractApplicationContext.refresh
> (AbstractApplicationContext.java:549)
>     at
> org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.
> loadContext
> (DefaultModuleDefinitionSet.java:145)
>     at
> org.apache.cloudstack.spring.module.model.impl.
> DefaultModuleDefinitionSet$2.with
> (DefaultModuleDefinitionSet.java:122)
>     at
> org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.
> withModule
> (DefaultModuleDefinitionSet.java:245)
>     at
> org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.
> withModule
> (DefaultModuleDefinitionSet.java:250)
>     at
> org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.
> withModule
> (DefaultModuleDefinitionSet.java:250)
>     at
> org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.
> withModule
> (DefaultModuleDefinitionSet.java:233)
>     at
> org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.
> loadContexts
> (DefaultModuleDefinitionSet.java:117)
>     at
> org.apache.cloudstack.spring.module.model.impl.DefaultModuleDefinitionSet.
> load
> (DefaultModuleDefinitionSet.java:79)
>     at
> org.apache.cloudstack.spring.module.factory.ModuleBasedContextFactory.
> loadModules
> (ModuleBasedContextFactory.java:37)
>     at
> org.apache.cloudstack.spring.module.factory.CloudStackSpringContext.init
> (CloudStackSpringContext.java:71)
>     at
> org.apache.cloudstack.spring.module.factory.CloudStackSpringContext.<init>
> (CloudStackSpringContext.java:58)
>     at
> org.apache.cloudstack.spring.module.factory.CloudStackSpringContext.<init>
> (CloudStackSpringContext.java:62)
>     at
> org.apache.cloudstack.spring.module.web.CloudStackContextLoaderListene
> r.contextInitialized
> (CloudStackContextLoaderListener.java:52)
>     at
> org.eclipse.jetty.server.handler.ContextHandler.callContextInitialized
> (ContextHandler.java:800)
>     at
> org.eclipse.jetty.servlet.ServletContextHandler.callContextInitialized
> (ServletContextHandler.java:444)
>     at org.eclipse.jetty.server.handler.ContextHandler.startContext
> (ContextHandler.java:791)
>     at org.eclipse.jetty.servlet.ServletContextHandler.startContext
> (ServletContextHandler.java:294)
>     at org.eclipse.jetty.webapp.WebAppContext.startWebapp
> (WebAppContext.java:1349)
>     at org.eclipse.jetty.maven.plugin.JettyWebAppContext.startWebapp
> (JettyWebAppContext.java:297)
>     at org.eclipse.jetty.webapp.WebAppContext.startContext
> (WebAppContext.java:1342)
>     at org.eclipse.jetty.server.handler.ContextHandler.doStart
> (ContextHandler.java:741)
>     at org.eclipse.jetty.webapp.WebAppContext.doStart
> (WebAppContext.java:505)
>     at org.eclipse.jetty.maven.plugin.JettyWebAppContext.doStart
> (JettyWebAppContext.java:366)
>     at org.eclipse.jetty.util.component.AbstractLifeCycle.start
> (AbstractLifeCycle.java:68)
>     at org.eclipse.jetty.util.component.ContainerLifeCycle.start
> (ContainerLifeCycle.java:132)
>     at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart
> (ContainerLifeCycle.java:114)
>     at org.eclipse.jetty.server.handler.AbstractHandler.doStart
> (AbstractHandler.java:61)
>     at org.eclipse.jetty.server.handler.ContextHandlerCollection.doStart
> (ContextHandlerCollection.java:163)
>     at org.eclipse.jetty.util.component.AbstractLifeCycle.start
> (AbstractLifeCycle.java:68)
>     at org.eclipse.jetty.util.component.ContainerLifeCycle.start
> (ContainerLifeCycle.java:132)
>     at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart
> (ContainerLifeCycle.java:114)
>     at org.eclipse.jetty.server.handler.AbstractHandler.doStart
> (AbstractHandler.java:61)
>     at org.eclipse.jetty.util.component.AbstractLifeCycle.start
> (AbstractLifeCycle.java:68)
>     at org.eclipse.jetty.util.component.ContainerLifeCycle.start
> (ContainerLifeCycle.java:132)
>     at org.eclipse.jetty.server.Server.start (Server.java:387)
>     at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart
> (ContainerLifeCycle.java:114)
>     at org.eclipse.jetty.server.handler.AbstractHandler.doStart
> (AbstractHandler.java:61)
>     at org.eclipse.jetty.server.Server.doStart (Server.java:354)
>     at org.eclipse.jetty.maven.plugin.JettyServer.doStart
> (JettyServer.java:73)
>     at org.eclipse.jetty.util.component.AbstractLifeCycle.start
> (AbstractLifeCycle.java:68)
>     at org.eclipse.jetty.maven.plugin.AbstractJettyMojo.startJetty
> (AbstractJettyMojo.java:535)
>     at org.eclipse.jetty.maven.plugin.AbstractJettyMojo.execute
> (AbstractJettyMojo.java:358)
>     at org.eclipse.jetty.maven.plugin.JettyRunMojo.execute
> (JettyRunMojo.java:167)
>     at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo
> (DefaultBuildPluginManager.java:134)
>     at org.apache.maven.lifecycle.internal.MojoExecutor.execute
> (MojoExecutor.java:208)
>     at org.apache.maven.lifecycle.internal.MojoExecutor.execute
> (MojoExecutor.java:154)
>     at org.apache.maven.lifecycle.internal.MojoExecutor.execute
> (MojoExecutor.java:146)
>     at
> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject
> (LifecycleModuleBuilder.java:117)
>     at
> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject
> (LifecycleModuleBuilder.java:81)
>     at
> org.apache.maven.lifecycle.internal.builder.singlethreaded.
> SingleThreadedBuilder.build
> (SingleThreadedBuilder.java:51)
>     at org.apache.maven.lifecycle.internal.LifecycleStarter.execute
> (LifecycleStarter.java:128)
>     at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:309)
>     at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:194)
>     at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:107)
>     at org.apache.maven.cli.MavenCli.execute (MavenCli.java:955)
>     at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:290)
>     at org.apache.maven.cli.MavenCli.main (MavenCli.java:194)
>     at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
>     at sun.reflect.NativeMethodAccessorImpl.invoke
> (NativeMethodAccessorImpl.java:62)
>     at sun.reflect.DelegatingMethodAccessorImpl.invoke
> (DelegatingMethodAccessorImpl.java:43)
>     at java.lang.reflect.Method.invoke (Method.java:498)
>     at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced
> (Launcher.java:289)
>     at org.codehaus.plexus.classworlds.launcher.Launcher.launch
> (Launcher.java:229)
>     at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode
> (Launcher.java:415)
>     at org.codehaus.plexus.classworlds.launcher.Launcher.main
> (Launcher.java:356)
> [WARNING] !RequestLog
>
>
> --
> Daan
>



-- 
Rafael Weingärtner

Reply via email to