[英]How to use spring cloud config server with postgresql and jdbc as backend with multiple profiles?
[英]Spring Config Server JDBC Backend with custom table
是否可以将spring配置服务器与自定义后端表一起使用,我需要这个,因为我们已经有一个用于其他东西的表,我们想要重用它来进行配置,而不必在所有配置示例中创建PROPERTIES表
使用可以使用以下属性文件,您可以在其中实际定义表和选定的数据字段。
spring:
cloud:
config:
server:
jdbc:
sql: SELECT KEY, VALUE from CUSTOMER_TABLE where SOMETHING=?
order: 1
datasource:
url: <your db url here>
driver-class-name: <your databases driver class here>
username: <your user to database>
password:
hikari:
maximum-pool-size: 10
connection-timeout: 5000
profiles:
active:
- jdbc
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.