iloveeyjafjalla opened a new pull request, #6843:
URL: https://github.com/apache/rocketmq-dashboard/pull/6843
## Which Issue(s) This PR Fixes
Fixes #6842
## Problem / Evidence
`STUDIO_AI_RMQCTL_TIMEOUT` is documented in `deploy/.env.example` and
forwarded by `deploy/docker-compose.yml`, but the property the app binds is
`studio.ai.conversation.rmqctl-timeout` and `application.yml` spelled it as a
literal `PT60S`:
```yaml
rmqctl-enabled: ${STUDIO_AI_RMQCTL_ENABLED:true}
rmqctl-server-url: ${STUDIO_AI_RMQCTL_SERVER_URL:}
rmqctl-timeout: PT60S # <- the third sibling has no bridge
```
So the documented name mapped to `studio.ai.rmqctl.timeout`, which neither
`application.yml` nor any configuration-properties class provides, and
`RmqctlWorkspace` kept handing the literal 60 s to every rmqctl invocation
(`RmqctlWorkspace.java:428`).
## Fix
Bridge the third sibling the way the other two are bridged:
```yaml
rmqctl-timeout: ${STUDIO_AI_RMQCTL_TIMEOUT:PT60S}
```
## Tests
Extended the existing `AiConversationPropertiesTest`, which already pins the
`STUDIO_AI_RMQCTL_ENABLED` bridge with a context runner, with the two timeout
cases next to it. The override case fails before the change:
```
rmqctlTimeoutShouldHonourTheDocumentedEnvironmentOverrideTest
expected: 5M
but was: 1M
```
After the change (JDK 21, offline Maven):
```
Tests run: 4, Failures: 0, Errors: 0, Skipped: 0
(AiConversationPropertiesTest) BUILD SUCCESS
```
The default case (`PT60S`) is pinned as well, so the change cannot quietly
move the default. One yml line plus two cases; the properties class,
`RmqctlWorkspace` and the compose file are untouched. Verified against the
repository's own deployment files at `a92c2314`; the change was prepared with
AI assistance and reviewed, tested and verified by me.
--
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]