Я пытаюсь реализовать вызов Open-fiegn от модуля CurrrenceExchange в CurrencyConversion, но я застрял в этой ошибке. Кто -нибудь может помочь мне с этим. Я проверил другой ответ и попытался добавить #spring.datasource.driver-class-name = com.mysql.jdbc.driver , но не работал.
Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
2022-09-22 21:07:32.787 ERROR [currency-conversion-service,,] 261173 --- [ 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 dev are currently active).
< /code>
pom.xml
4.0.0
org.springframework.boot
spring-boot-starter-parent
2.6.6
com.hashedin
currency-conversion-service
0.0.1-SNAPSHOT
currency-conversion-service
Currency Exchange Service template for HU SDE 22.3.2 Advanced Java track
1.8
2021.0.1
org.springframework.boot
spring-boot-starter-web
org.springframework.cloud
spring-cloud-starter-loadbalancer
org.springframework.cloud
spring-cloud-starter-netflix-eureka-client
org.springframework.boot
spring-boot-starter-test
test
org.springframework.boot
spring-boot-starter-data-jpa
org.springframework.cloud
spring-cloud-starter-openfeign
3.1.4
org.springframework.cloud
spring-cloud-starter-sleuth
org.springdoc
springdoc-openapi-ui
1.6.11
org.openapitools
jackson-databind-nullable
0.2.1
io.swagger
swagger-annotations
1.6.1
javax.persistence
javax.persistence-api
2.2
org.projectlombok
lombok
org.springframework.cloud
spring-cloud-dependencies
${spring-cloud.version}
pom
import
org.springframework.boot
spring-boot-maven-plugin
2.7.3
< /code>
prapperties < /p>
spring.application.name=currency-conversion-service
#spring.datasource.driver-class-name=com.mysql.jdbc.Driver
spring.profiles.active=dev
server.port=8081
spring.cloud.config.enabled=false
eureka.client.serviceUrl.defaultZone=https://hu-22-java-adv-mastereureka-ser ... app/eureka
eureka.instance.prefer-ip-address=true
eureka.instance.hostname=https://hu-22-java-adv-mastereureka-ser ... .a.run.app
eureka.client.register-with-eureka=true
eureka.client.fetch-registry=true
Подробнее здесь: https://stackoverflow.com/questions/738 ... ot-specifi