lancelothuxi opened a new issue, #29628:
URL: https://github.com/apache/shardingsphere/issues/29628
## Bug Report
I have dynamic property in jdbc url as like :
jdbc:postgresql://localhost:5432/sharding_db01?ApplicationName=${HOSTNAME},
currently i run my application in docker container, the HOSTNAME is pod
name, which is different for every pod,
it works fine in local mode, and the HOSTNAME is replaced by the pod name
correctly, but in cluster mode(using zookeeper), the HOSTNAME
is keeping unchanged, I debuged the source code , find that the jdbc url is
always replaced by the configure stored in zookeeper,
I also tried the following configure:
` datasource:
ds10: # 实例名称,自定义
type: com.zaxxer.hikari.HikariDataSource
driver-class-name: org.postgresql.Driver
jdbc-url: jdbc:postgresql://localhost:5432/sharding_db01
password: mypassword
username: myusername
data-source-properties:
"ApplicationName": ${HOSTNAME}
`
it works the same, is replaced with the config from zookeeper.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail:
[email protected]
For queries about this service, please contact Infrastructure at:
[email protected]