You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by "yyqdbngt (via GitHub)" <gi...@apache.org> on 2026/09/01 18:15:13 UTC
[PR] fix(client): tolerate null connection lists from client providers [rocketmq-dashboard]
yyqdbngt opened a new pull request, #2926:
URL: https://github.com/apache/rocketmq-dashboard/pull/2926
## Summary
The client connection endpoints trust the provider layer to return non-null lists, but the `ClientProvider` contract only declares `List<...>` return types:
- `ProducerConnectionService.listConnections()` called `.stream()` directly on the provider result, so a provider reporting an unavailable lookup as `null` surfaced as a raw NPE 500.
- `ClientService` and `listProducerGroups()` passed a `null` straight through the API as `data: null`, breaking the list contract the frontend maps over.
The service layer now normalizes a `null` provider result to an empty list, matching how the provider implementations already report "nothing found" (`List.of()`).
## Why
The provider interface is the boundary between Studio and the RocketMQ runtime; implementations can report unavailable lookups as `null` without violating anything, and the endpoints should degrade to "no connections" instead of a 500 or a null payload.
## Testing
Extended `ClientServiceTest` (+2) and `ProducerConnectionServiceTest` (+2) with null-provider-result cases for all four endpoints.
```
mvn -q -Dtest="ClientServiceTest,ProducerConnectionServiceTest" test
Tests run: 12, Failures: 0, Errors: 0, Skipped: 0
```
--
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: commits-unsubscribe@rocketmq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] fix(client): tolerate null connection lists from client providers [rocketmq-dashboard]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #2926:
URL: https://github.com/apache/rocketmq-dashboard/pull/2926#issuecomment-5593756311
This pull request has been automatically closed because there has been no activity for 7 days. If you would like to continue working on this, please reopen the PR with updated changes.
--
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: commits-unsubscribe@rocketmq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] fix(client): tolerate null connection lists from client providers [rocketmq-dashboard]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] closed pull request #2926: fix(client): tolerate null connection lists from client providers
URL: https://github.com/apache/rocketmq-dashboard/pull/2926
--
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: commits-unsubscribe@rocketmq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org