Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2201,7 +2201,7 @@ protected void syncBrokerMemberGroup() {
BrokerController.LOG.error("syncBrokerMemberGroup from namesrv failed, ", e);
return;
}
if (brokerMemberGroup == null || brokerMemberGroup.getBrokerAddrs().size() == 0) {
if (brokerMemberGroup == null || brokerMemberGroup.getBrokerAddrs().isEmpty()) {
BrokerController.LOG.warn("Couldn't find any broker member from namesrv in {}/{}", this.brokerConfig.getBrokerClusterName(), this.brokerConfig.getBrokerName());
return;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ public void run() {

this.waitForRunning(interval);

if (!this.serving && this.buffer.size() == 0 && getOffsetTotalSize() == 0) {
if (!this.serving && this.buffer.isEmpty() && getOffsetTotalSize() == 0) {
this.serving = true;
}
} catch (Throwable e) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ private PullResult pullSyncImpl(MessageQueue mq, SubscriptionData subscriptionDa
}

public void resetTopic(List<MessageExt> msgList) {
if (null == msgList || msgList.size() == 0) {
if (null == msgList || msgList.isEmpty()) {
return;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public static Map<String, String> parseToMap(String attributesModification) {
}

public static String parseToString(Map<String, String> attributes) {
if (attributes == null || attributes.size() == 0) {
if (attributes == null || attributes.isEmpty()) {
return "";
}

Expand Down