Aias00 opened a new issue, #10772:
URL: https://github.com/apache/rocketmq/issues/10772
### Problem
`DefaultAdminService#createTopicOnBroker` null-checks broker addresses in
`sampleBrokerDataList`, but not in `curBrokerDataList`:
```java
for (BrokerData brokerData : curBrokerDataList) {
curBrokerAddr.add(brokerData.getBrokerAddrs().get(MixAll.MASTER_ID));
}
```
If the current route data contains a malformed `BrokerData` with
`brokerAddrs == null`, this throws a `NullPointerException` before the method
can create the topic on valid sample brokers.
### Expected behavior
Malformed current broker rows should be ignored when building the set of
existing broker addresses. This should match the later sample broker handling,
which already skips null broker address maps and missing master addresses.
### Impact
A stale or partial route response can prevent Proxy admin topic creation
from proceeding, even when valid sample broker data is available.
### Suggested fix
- Null-check `brokerData` and `brokerData.getBrokerAddrs()` while collecting
current broker addresses.
- Skip null master broker addresses.
- Add regression coverage for a current broker row with null broker
addresses.
--
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]