API调用失败:HHH000206:找不到hibernate.properties更改Spring Boot的数据源时发生异常

时间:2019-11-08 06:12:56

标签: spring hibernate jpa properties

我想将数据源从mariah DB更改为oracle 9i数据库。

关于执行,它给出以下异常。我是否需要修改连接到该数据库的存储库和模型?

错误:

2019-11-08 12:29:04.011  INFO 16044 --- [  restartedMain] org.hibernate.Version                    : HHH000412: Hibernate Core {5.3.10.Final}
2019-11-08 12:29:04.013  INFO 16044 --- [  restartedMain] org.hibernate.cfg.Environment            : HHH000206: hibernate.properties not found
2019-11-08 12:29:04.160  INFO 16044 --- [  restartedMain] o.hibernate.annotations.common.Version   : HCANN000001: Hibernate Commons Annotations {5.0.4.Final}
2019-11-08 12:29:04.356  INFO 16044 --- [  restartedMain] org.hibernate.dialect.Dialect            : HHH000400: Using dialect: org.hibernate.dialect.Oracle9iDialect

application.properties

// Server Port
server.port=4200

spring.datasource.url =jdbc:oracle:thin:@localhost:1521:dev
spring.datasource.username =ops$dev
spring.datasource.password =abc123sss
spring.datasource.driver-class-name=oracle.jdbc.OracleDriver

spring.jpa.properties.hibernate.ddl-auto=create
spring.jpa.database-platform= org.hibernate.dialect.Oracle9iDialect
spring.jpa.properties.hibernate.dialect = org.hibernate.dialect.Oracle9iDialect
spring.jpa.hibernate.ddl-auto = true 

然后,我的屏幕显示无法连接,而不是发出字符串消息:

enter image description here

0 个答案:

没有答案