org.springframework.beans.factory.BeanCreationException

If you like a tip written by other Samebug users, mark is as helpful! Marks help our algorithm provide you better solutions and also help other users.
tip

Ant scp task has an attribute called trust. If set to false (default) the host you connect to has to be set in the knownhosts file (you might have to create it) Another way is to explicitly set "trust = true". Check the documentation: https://goo.gl/G5680x

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

  • GitHub comment 35#102391948
    via GitHub by rgwch
    ,
    • org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'environmentRepository' defined in org.springframework.cloud.config.server.config.EnvironmentRepositoryConfiguration$GitRepositoryConfiguration: Invocation of init method failed; nested exception is org.eclipse.jgit.api.errors.TransportException: ssh://git-codecommit.us-east-1.amazonaws.com/v1/repos/configserver: USERAUTH fail at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1578)[spring-beans-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:545)[spring-beans-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482)[spring-beans-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)[spring-beans-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)[spring-beans-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)[spring-beans-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)[spring-beans-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:776)[spring-beans-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:861)[spring-context-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:541)[spring-context-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:122)[spring-boot-1.4.0.RELEASE.jar:1.4.0.RELEASE] at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:759)[spring-boot-1.4.0.RELEASE.jar:1.4.0.RELEASE] at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:369)[spring-boot-1.4.0.RELEASE.jar:1.4.0.RELEASE] at org.springframework.boot.SpringApplication.run(SpringApplication.java:313)[spring-boot-1.4.0.RELEASE.jar:1.4.0.RELEASE] at org.springframework.boot.SpringApplication.run(SpringApplication.java:1185)[spring-boot-1.4.0.RELEASE.jar:1.4.0.RELEASE] at org.springframework.boot.SpringApplication.run(SpringApplication.java:1174)[spring-boot-1.4.0.RELEASE.jar:1.4.0.RELEASE] at com.zalora.ConfigServiceApplication.main(ConfigServiceApplication.java:12)[classes/:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[na:1.8.0_102] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)[na:1.8.0_102] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[na:1.8.0_102] at java.lang.reflect.Method.invoke(Method.java:498)[na:1.8.0_102] at com.intellij.rt.execution.application.AppMain.main(AppMain.java:147)[idea_rt.jar:na] Caused by: org.eclipse.jgit.api.errors.TransportException: ssh://git-codecommit.us-east-1.amazonaws.com/v1/repos/configserver: USERAUTH fail at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:139)[org.eclipse.jgit-3.5.3.201412180710-r.jar:3.5.3.201412180710-r] at org.eclipse.jgit.api.CloneCommand.fetch(CloneCommand.java:178)[org.eclipse.jgit-3.5.3.201412180710-r.jar:3.5.3.201412180710-r] at org.eclipse.jgit.api.CloneCommand.call(CloneCommand.java:125)[org.eclipse.jgit-3.5.3.201412180710-r.jar:3.5.3.201412180710-r] at org.springframework.cloud.config.server.environment.JGitEnvironmentRepository.cloneToBasedir(JGitEnvironmentRepository.java:282)[spring-cloud-config-server-1.1.2.RELEASE.jar:1.1.2.RELEASE] at org.springframework.cloud.config.server.environment.JGitEnvironmentRepository.initClonedRepository(JGitEnvironmentRepository.java:183)[spring-cloud-config-server-1.1.2.RELEASE.jar:1.1.2.RELEASE] at org.springframework.cloud.config.server.environment.JGitEnvironmentRepository.afterPropertiesSet(JGitEnvironmentRepository.java:135)[spring-cloud-config-server-1.1.2.RELEASE.jar:1.1.2.RELEASE] at org.springframework.cloud.config.server.environment.MultipleJGitEnvironmentRepository.afterPropertiesSet(MultipleJGitEnvironmentRepository.java:64)[spring-cloud-config-server-1.1.2.RELEASE.jar:1.1.2.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1637)[spring-beans-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1574)[spring-beans-4.3.2.RELEASE.jar:4.3.2.RELEASE] ... 21 more Caused by: org.eclipse.jgit.errors.TransportException: ssh://git-codecommit.us-east-1.amazonaws.com/v1/repos/configserver: USERAUTH fail at org.eclipse.jgit.transport.JschConfigSessionFactory.getSession(JschConfigSessionFactory.java:159)[org.eclipse.jgit-3.5.3.201412180710-r.jar:3.5.3.201412180710-r] at org.eclipse.jgit.transport.SshTransport.getSession(SshTransport.java:136)[org.eclipse.jgit-3.5.3.201412180710-r.jar:3.5.3.201412180710-r] at org.eclipse.jgit.transport.TransportGitSsh$SshFetchConnection.<init>(TransportGitSsh.java:262)[org.eclipse.jgit-3.5.3.201412180710-r.jar:3.5.3.201412180710-r] at org.eclipse.jgit.transport.TransportGitSsh.openFetch(TransportGitSsh.java:161)[org.eclipse.jgit-3.5.3.201412180710-r.jar:3.5.3.201412180710-r] at org.eclipse.jgit.transport.FetchProcess.executeImp(FetchProcess.java:136)[org.eclipse.jgit-3.5.3.201412180710-r.jar:3.5.3.201412180710-r] at org.eclipse.jgit.transport.FetchProcess.execute(FetchProcess.java:122)[org.eclipse.jgit-3.5.3.201412180710-r.jar:3.5.3.201412180710-r] at org.eclipse.jgit.transport.Transport.fetch(Transport.java:1115)[org.eclipse.jgit-3.5.3.201412180710-r.jar:3.5.3.201412180710-r] at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:130)[org.eclipse.jgit-3.5.3.201412180710-r.jar:3.5.3.201412180710-r] ... 29 more Caused by: com.jcraft.jsch.JSchException: USERAUTH fail at com.jcraft.jsch.UserAuthPublicKey.start(UserAuthPublicKey.java:118)[jsch-0.1.50.jar:na] at com.jcraft.jsch.Session.connect(Session.java:463)[jsch-0.1.50.jar:na] at org.eclipse.jgit.transport.JschConfigSessionFactory.getSession(JschConfigSessionFactory.java:116)[org.eclipse.jgit-3.5.3.201412180710-r.jar:3.5.3.201412180710-r] ... 36 more

    Users with the same issue

    jf-ast
    10 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    95 more bugmates