Как я могу ccr.read.clientSecret значение из override.properties Я нахожусь на Windows 10 Я пытаюсь запустить приложение Spring Boot с помощью командной строки
java -jar -Dspring.profiles.active=local -Dspring.config.location=file:D:/myname/Properties/override.properties myapp-0.0.1-SNAPSHOT.jar
Мой файл JAR имеет application.properties
#tomcat port
server.port=8081
#Spring Batch App
spring.batch.job.enabled=false
spring.profiles.active=
#JPA Properties
spring.jpa.show-sql=false
spring.jpa.hibernae.format_sql=true
spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.Oracle10gDialect
spring.batch.initialize-schema=always
Мои application-local.properties
accr.read.clientId=JOHN
accr.read.clientSecret=
accr.read.grantType=client_credentials
accr.read.scope=scope1
# Database settings
spring.datasource.driver-class-name=oracle.jdbc.OracleDriver
spring.datasource.driverClassName=oracle.jdbc.OracleDriver
spring.datasource.url=jdbc:oracle:thin:@devdb.in.world:1522/DEV01
spring.datasource.username=USER$NAME
spring.datasource.password=password123
override.properties
ccr.read.clientSecret=passwordisthis
Когда я выполняю первую команду для запуска приложения весенней загрузки, яПолучите ниже ошибка
Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
2019-10-03 15:18:43.675 ERROR 14828 --- [ main] o.s.b.d.LoggingFailureAnalysisReporter :
***************************
APPLICATION FAILED TO START
***************************
Description:
Failed to configure a DataSource: 'url' attribute is not specified and no embedded datasource could be configured.
Reason: Failed to determine a suitable driver class
Action:
Consider the following:
If you want an embedded database (H2, HSQL or Derby), please put it on the classpath.
If you have database settings to be loaded from a particular profile you may need to activate it (the profiles local are currently active).