fix: harden bundled dashboard and alert asset loading - #1200
Conversation
RockteMQ-AI
left a comment
There was a problem hiding this comment.
Summary
This PR fixes Grafana dashboard asset loading to use explicit UTF-8 encoding instead of the platform default charset. Prevents garbled dashboard names/descriptions on systems where the default encoding is not UTF-8 (e.g., Windows with GBK).
Simple but important correctness fix.
LGTM.
Automated review by github-manager-bot
RockteMQ-AI
left a comment
There was a problem hiding this comment.
Summary
This PR fixes Grafana dashboard asset loading to use explicit UTF-8 encoding instead of the platform default charset. Prevents garbled dashboard names/descriptions on systems where the default encoding is not UTF-8 (e.g., Windows with GBK).
Simple but important correctness fix.
LGTM.
Automated review by github-manager-bot
RockteMQ-AI
left a comment
There was a problem hiding this comment.
New commit looks good. Adding a null/non-object guard after readTree() prevents crashes on malformed dashboard JSON assets. The protected visibility change on resolveResources() is a reasonable trade-off for testability. The new test covering empty and array JSON inputs is thorough.
Automated review by github-manager-bot
6c0faaf to
64cf382
Compare
…quick start; align tests Consolidates apache#1122, apache#1123, apache#1200, apache#1217: decode Grafana dashboard assets as UTF-8, skip invalid Grafana assets and incomplete alert rules, bound Prometheus time-series labels, stop seeding demo resources by default and complete the Docker Compose quick start docs. Also aligns pre-existing tests with the integrated behaviors (required instance type, live resource counts on delete, long TPS fields, default dashboard cluster type).
…tics and asset loading (#1177) * feat: complete instance scoping for metadata mutations, message queries, producers and dashboard Consolidates #1112, #1120, #1162, #1166, #1177: route Apache Topic mutations, test messages, producer connections, message queries, dashboard data and metrics sources by the selected instance; scope metadata deletes to the current cluster; redirect unknown instance routes. * fix: harden instance lifecycle, runtime admin caches and cloud credential invalidation Consolidates #1185, #1213, #1225, #1236, #1238: release unused runtime AdminClients, normalize NameServer cache keys, align cache lifecycle, validate Apache instance endpoints and type before persistence, invalidate Aliyun clients after credential changes, expose unavailable cloud resource counts and check current resources before deleting an instance. * fix: harden runtime diagnostics, dashboard overview and async detail freshness Consolidates #1089, #1205, #1219, #1223, #1240: guard stale async detail responses (consumer groups, LiteTopic), coordinate group refreshes, remove unsupported group/subscription actions, surface unavailable broker runtime statistics/versions and cluster discovery failures, wire Broker Cluster restart, mark dashboard clusters warning on runtime failures, preserve TPS precision, reuse broker runtime snapshots, distinguish unavailable DLQ statistics, handle missing DLQ enqueue timestamps, stop stalled pull scans and report DLQ resend failures. * fix: harden bundled asset loading, metrics labels and defaults; docs quick start; align tests Consolidates #1122, #1123, #1200, #1217: decode Grafana dashboard assets as UTF-8, skip invalid Grafana assets and incomplete alert rules, bound Prometheus time-series labels, stop seeding demo resources by default and complete the Docker Compose quick start docs. Also aligns pre-existing tests with the integrated behaviors (required instance type, live resource counts on delete, long TPS fields, default dashboard cluster type).
|
Consolidated into #1177 (merged into rocketmq-studio as f727341): this change was integrated together with the remaining batch of instance-scoping, lifecycle, runtime-diagnostic and asset-hardening fixes, adapted to the current architecture and verified with the full test suite. Thanks for the contribution! / 已并入 #1177(合入 rocketmq-studio,SHA f727341):与其余 instance 作用域、生命周期、运行时诊断与资产加固修复合批整合,适配了当前架构并通过全量测试。感谢贡献! |
Summary
Closes #1199
Closes #1201
Closes #1209
Verification