报错如下
Exception encountered during context initialization - cancelling refresh attempt: org.springframework.context.ApplicationContextException: Unable to start embedded container; nested exception is java.lang.RuntimeException: org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘webMetricsFilter’ defined in class path resource [io/micrometer/spring/autoconfigure/web/servlet/ServletMetricsConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [io.micrometer.spring.web.servlet.WebMvcMetricsFilter]: Factory method ‘webMetricsFilter’ threw exception; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘org.springframework.security.oauth2.config.annotation.web.configuration.AuthorizationServerEndpointsConfiguration’: Unsatisfied dependency expressed through field ‘configurers’; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘authorizationServerConfig’ defined in file [D:\project\choerodon\oauth-server\target\classes\io\choerodon\oauth\infra\config\AuthorizationServerConfig.class]: Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘authenticationManager’ defined in class path resource [org/springframework/boot/autoconfigure/security/AuthenticationManagerConfiguration.class]: Unsatisfied dependency expressed through method ‘authenticationManager’ parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘org.springframework.security.config.annotation.authentication.configuration.AuthenticationConfiguration’: Unsatisfied dependency expressed through method ‘setGlobalAuthenticationConfigurers’ parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘globalAuthenticationConfig’: Unsatisfied dependency expressed through field ‘choerodonAuthenticationProvider’; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘choerodonAuthenticationProvider’: Unsatisfied dependency expressed through field ‘organizationRepository’; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘organizationRepositoryImpl’ defined in file [D:\project\choerodon\oauth-server\target\classes\io\choerodon\oauth\infra\repository\impl\OrganizationRepositoryImpl.class]: Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘organizationMapper’ defined in file [D:\project\choerodon\oauth-server\target\classes\io\choerodon\oauth\infra\mapper\OrganizationMapper.class]: Unsatisfied dependency expressed through bean property ‘sqlSessionFactory’; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘sqlSessionFactory’ defined in class path resource [org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.class]: Unsatisfied dependency expressed through method ‘sqlSessionFactory’ parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘dataSource’ defined in class path resource [org/springframework/boot/autoconfigure/jdbc/DataSourceConfiguration$Tomcat.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.apache.tomcat.jdbc.pool.DataSource]: Factory method ‘dataSource’ threw exception; nested exception is org.springframework.boot.autoconfigure.jdbc.DataSourceProperties$DataSourceBeanCreationException: Cannot determine embedded database driver class for database type NONE. If you want an embedded database please put a supported one on the classpath. If you have database settings to be loaded from a particular profile you may need to active it (no profiles are currently active).
2018-06-13 21:09:18.509 ERROR [-,] 1388 — [ main] o.s.b.d.LoggingFailureAnalysisReporter :
请问下是源码运行还是镜像运行?
看起来好像是没有配置数据库连接
这是本地跑的吧?配置文件指定正确的数据库的JDBC,用户名,密码
我们web容器用的是undertow,所以需要把tomcat排除掉,跟这个应该无关。报错是JDBC的错,请问你有没有修改配置或依赖,我们刚才启动了下0.6.0代码是可以正常启动不会报错的
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-undertow</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
<exclusions>
<exclusion>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-tomcat</artifactId>
</exclusion>
</exclusions>
</dependency>