tju-yxq opened a new pull request, #2586: URL: https://github.com/apache/rocketmq-dashboard/pull/2586
## Summary - add a write-only `clearApiKey` flag to the LLM config contract - clear the stored key instead of restoring it when the flag is set - add a "Clear key" action to the AI Assistant settings tab - require confirmation before clearing - update the configured-key badge after a successful clear - keep the existing "leave blank to preserve the current key" behavior unchanged - keep environment-injected `RMQ_LLM_TOKEN` authoritative at runtime and do not attempt to remove it ## Why The AI Assistant settings can save or preserve an API key but cannot remove one. Leaving the field blank preserves the stored value, so once a key is persisted the only UI options are replacing it or editing storage externally. The general settings model already has clear-key semantics; this brings the AI Assistant configuration to the same lifecycle. ## Tests - focused backend: `LlmConfigServiceTest, LlmControllerTest` — 32 tests passed - focused frontend: `AiAssistantTab.test.tsx` — 8 tests passed - `npm run lint -- --quiet`: 0 errors (2 pre-existing warnings) - `npm run build`: passed - `git diff --check`: passed Production changes: 63 additions / 1 deletion. Although the full PR is 100 additions / 1 deletion, production code is below the 100-line threshold, so this is a useful candidate but not counted as a complete 100+ production-line group. Closes #2585 -- 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]
