Repository navigation
Description
Before Creating the Bug Report
- I have searched the open issues of this repository and believe that this is not a duplicate.
- This is a defect in RocketMQ Studio, not a usage question and not a defect in another Apache RocketMQ repository.
- I can reproduce this on the current
rocketmq-studiobranch, or I have stated the exact version I am running below.
Studio Version
branch: rocketmq-studio
git commit id: 779b8c0e
deployed as: reproduced by a component test against that commit (the affected code is the web client)
Runtime Environment
OS: Ubuntu on WSL2
MySQL: not applicable — the defect is in the web client's settings tab
browser: not applicable — reproduced in a jsdom unit test (vitest + Testing Library)
Connected RocketMQ Cluster
RocketMQ version: not applicable — reproduced with a stubbed LLM configuration API in a unit test
access mode: not applicable
deployment: not applicable
Describe the Bug
When the AI assistant configuration cannot be loaded, Settings → AI 助手 renders the configuration
form anyway, with every field empty and the API key slot prompting for a key
(web/src/pages/settings/AiAssistantTab.tsx:159-176):
Promise.all([getLlmConfig(), getLlmModels().catch(() => null)])
.then(([config, models]) => { ... applyConfig(config, ...); })
.catch(() => {
if (!cancelled) message.error(t('llm.loadFailed'));
})applyConfig never runs, so apiKeyConfigured stays false and the tab claims that no provider,
model or API key is set up — the failure is only a toast, and there is no retry. The load endpoints
are admin-only on the server (AuthInterceptor.isAdminOnlyGetPath includes /api/llm/config and
/api/llm/models, answering 403 "Admin permission required"), so a reader opening the tab always
sees that blank configuration, and the server's reason is discarded.
The list components already handle this shape (AlertRuleAssetList renders an error notice with a
retry above its table), and the home page's assistant load failure is handled the same way in #6082.
Steps to Reproduce
Reproduced by a component test rather than against a server:
- Render the settings tab with
GET /api/llm/configrejecting (a reader's 403). - The tab shows a toast and an empty configuration form; nothing states why the configuration is
missing and there is no way to retry the load.
What Did You Expect to See?
The tab should say that the configuration could not be read (with the reason the request failed
with) and offer a retry, instead of presenting an unreadable configuration as an empty one.
What Did You See Instead?
A blank configuration form that claims nothing is configured, plus a transient toast; the server's
"Admin permission required" never reaches the operator.
Additional Context
- A fix with a regression test follows in a pull request.
- The case is pinned by a unit test that fails without the fix:
Unable to find an element with the text: Admin permission required.
Are You Willing to Submit a Pull Request?
- Yes, I am willing to submit a pull request.
Activity
lizhimins commentedon Oct 15, 2026
Resolved by #6550 (merged into
rocketmq-studioascdbd1fa8f). The merge target is not the default branch, so this issue does not auto-close.