Skip to content

Instantly share code, notes, and snippets.

@jajm
Created October 11, 2017 09:43
Show Gist options
  • Save jajm/802ac94ebd734383117963dc4af51693 to your computer and use it in GitHub Desktop.
Save jajm/802ac94ebd734383117963dc4af51693 to your computer and use it in GitHub Desktop.
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/home/ginco/ginco/ginco-cli/target/lib/logback-classic-1.0.9.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/home/ginco/ginco/ginco-cli/target/lib/slf4j-log4j12-1.6.4.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [ch.qos.logback.classic.util.ContextSelectorStaticBinder]
2017-10-11 11:41:59,067 INFO | main | o.s.context.support.ClassPathXmlApplicationContext | Refreshing org.springframework.context.support.ClassPathXmlApplicationContext@65e2dbf3: startup date [Wed Oct 11 11:41:59 CEST 2017]; root of context hierarchy
2017-10-11 11:41:59,095 INFO | main | o.s.beans.factory.xml.XmlBeanDefinitionReader | Loading XML bean definitions from class path resource [applicationContext-cli.xml]
2017-10-11 11:41:59,336 INFO | main | o.s.beans.factory.config.PropertyPlaceholderConfigurer | Loading properties file from class path resource [hibernate.properties]
2017-10-11 11:41:59,337 WARN | main | o.s.beans.factory.config.PropertyPlaceholderConfigurer | Could not load properties from class path resource [hibernate.properties]: class path resource [hibernate.properties] cannot be opened because it does not exist
2017-10-11 11:41:59,337 INFO | main | o.s.beans.factory.config.PropertyPlaceholderConfigurer | Loading properties file from class path resource [application.properties]
2017-10-11 11:41:59,337 WARN | main | o.s.beans.factory.config.PropertyPlaceholderConfigurer | Could not load properties from class path resource [application.properties]: class path resource [application.properties] cannot be opened because it does not exist
2017-10-11 11:41:59,337 INFO | main | o.s.beans.factory.config.PropertyPlaceholderConfigurer | Loading properties file from class path resource [git.properties]
2017-10-11 11:41:59,337 WARN | main | o.s.beans.factory.config.PropertyPlaceholderConfigurer | Could not load properties from class path resource [git.properties]: class path resource [git.properties] cannot be opened because it does not exist
2017-10-11 11:41:59,337 INFO | main | o.s.beans.factory.config.PropertyPlaceholderConfigurer | Loading properties file from class path resource [labels.properties]
2017-10-11 11:41:59,337 WARN | main | o.s.beans.factory.config.PropertyPlaceholderConfigurer | Could not load properties from class path resource [labels.properties]: class path resource [labels.properties] cannot be opened because it does not exist
2017-10-11 11:41:59,337 INFO | main | o.s.beans.factory.config.PropertyPlaceholderConfigurer | Loading properties file from class path resource [db.properties]
2017-10-11 11:41:59,338 INFO | main | o.s.beans.factory.config.PropertyPlaceholderConfigurer | Loading properties file from URL [file:ginco-cli.properties]
2017-10-11 11:41:59,341 INFO | main | o.s.b.f.annotation.AutowiredAnnotationBeanPostProcessor | JSR-330 'javax.inject.Inject' annotation found and supported for autowiring
2017-10-11 11:41:59,347 INFO | main | o.s.beans.factory.support.DefaultListableBeanFactory | Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@34e9fd99: defining beans [org.springframework.context.annotation.internalConfigurationAnnotationProcessor,org.springframework.context.annotation.internalAutowiredAnnotationProcessor,org.springframework.context.annotation.internalRequiredAnnotationProcessor,org.springframework.context.annotation.internalCommonAnnotationProcessor,org.springframework.context.annotation.internalPersistenceAnnotationProcessor,sessionInitier,cliExporter,cliImporter,dataSource,solrServer,propertyConfigurer,org.springframework.context.annotation.ConfigurationClassPostProcessor.importAwareProcessor]; root of factory hierarchy
2017-10-11 11:41:59,358 WARN | main | o.s.context.support.ClassPathXmlApplicationContext | Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionInitier': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private org.hibernate.SessionFactory fr.mcc.ginco.cli.SessionInitier.sessionFactory; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [org.hibernate.SessionFactory] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@javax.inject.Inject(), @javax.inject.Named(value=gincoSessionFactory)}
2017-10-11 11:41:59,358 INFO | main | o.s.beans.factory.support.DefaultListableBeanFactory | Destroying singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@34e9fd99: defining beans [org.springframework.context.annotation.internalConfigurationAnnotationProcessor,org.springframework.context.annotation.internalAutowiredAnnotationProcessor,org.springframework.context.annotation.internalRequiredAnnotationProcessor,org.springframework.context.annotation.internalCommonAnnotationProcessor,org.springframework.context.annotation.internalPersistenceAnnotationProcessor,sessionInitier,cliExporter,cliImporter,dataSource,solrServer,propertyConfigurer,org.springframework.context.annotation.ConfigurationClassPostProcessor.importAwareProcessor]; root of factory hierarchy
Exception in thread "main" org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionInitier': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private org.hibernate.SessionFactory fr.mcc.ginco.cli.SessionInitier.sessionFactory; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [org.hibernate.SessionFactory] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@javax.inject.Inject(), @javax.inject.Named(value=gincoSessionFactory)}
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:298)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1148)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:458)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:293)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:290)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:191)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:636)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:938)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:479)
at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:139)
at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:93)
at fr.mcc.ginco.cli.App.main(App.java:66)
Caused by: org.springframework.beans.factory.BeanCreationException: Could not autowire field: private org.hibernate.SessionFactory fr.mcc.ginco.cli.SessionInitier.sessionFactory; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [org.hibernate.SessionFactory] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@javax.inject.Inject(), @javax.inject.Named(value=gincoSessionFactory)}
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:531)
at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:88)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:295)
... 13 more
Caused by: org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [org.hibernate.SessionFactory] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@javax.inject.Inject(), @javax.inject.Named(value=gincoSessionFactory)}
at org.springframework.beans.factory.support.DefaultListableBeanFactory.raiseNoSuchBeanDefinitionException(DefaultListableBeanFactory.java:997)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:867)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:779)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:503)
... 15 more
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment