mirror of
https://github.com/apache/rocketmq.git
synced 2026-09-21 05:44:03 +08:00
update double validations
This commit is contained in:
@@ -86,7 +86,7 @@ public class BrokerOuterAPI {
|
||||
public String fetchNameServerAddr() {
|
||||
try {
|
||||
String addrs = this.topAddressing.fetchNSAddr();
|
||||
if (addrs != null && !UtilAll.isBlank(addrs)) {
|
||||
if (!UtilAll.isBlank(addrs)) {
|
||||
if (!addrs.equals(this.nameSrvAddr)) {
|
||||
log.info("name server address changed, old: {} new: {}", this.nameSrvAddr, addrs);
|
||||
this.updateNameServerAddressList(addrs);
|
||||
|
||||
@@ -227,7 +227,7 @@ public class MQClientAPIImpl {
|
||||
public String fetchNameServerAddr() {
|
||||
try {
|
||||
String addrs = this.topAddressing.fetchNSAddr();
|
||||
if (addrs != null && !UtilAll.isBlank(addrs)) {
|
||||
if (!UtilAll.isBlank(addrs)) {
|
||||
if (!addrs.equals(this.nameSrvAddr)) {
|
||||
log.info("name server address changed, old=" + this.nameSrvAddr + ", new=" + addrs);
|
||||
this.updateNameServerAddressList(addrs);
|
||||
|
||||
Reference in New Issue
Block a user