Baoyuantop commented on PR #13078:
URL: https://github.com/apache/apisix/pull/13078#issuecomment-4044288558
Hi @lxbme, the current repair method has compatibility risks.
The PR completely disables type conversion for environment variables in
apisix.yaml. This means that in standalone mode, if a user assigns a value to a
schema field that requires a number or boolean type via an environment variable
(such as upstream weight, timeout, retries, or boolean switches in plugin
configuration), the value will remain a string, causing schema validation to
fail.
```
# apisix.yaml
routes:
- uri: /test
upstream:
nodes:
"127.0.0.1:8080": ${{WEIGHT}} # WEIGHT=1 → Keep the string "1" →
schema expects number → Failure
type: roundrobin
retries: ${{RETRIES}} # It will also preserve the string
```
The solution to this problem requires further discussion and confirmation.
--
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]