HBASE-19131 (Addendum) Use the emptyList() to replace EMPTY_LIST

This commit is contained in:
Chia-Ping Tsai 2017-11-07 04:06:00 +08:00
parent 9ee8e2714d
commit 33ede55164
1 changed files with 3 additions and 3 deletions

View File

@ -138,7 +138,7 @@ public class ClusterStatus {
*/
public List<ServerName> getDeadServerNames() {
if (deadServers == null) {
return Collections.EMPTY_LIST;
return Collections.emptyList();
}
return Collections.unmodifiableList(deadServers);
}
@ -256,7 +256,7 @@ public class ClusterStatus {
public Collection<ServerName> getServers() {
if (liveServers == null) {
return Collections.EMPTY_LIST;
return Collections.emptyList();
}
return Collections.unmodifiableCollection(this.liveServers.keySet());
}
@ -281,7 +281,7 @@ public class ClusterStatus {
*/
public List<ServerName> getBackupMasters() {
if (backupMasters == null) {
return Collections.EMPTY_LIST;
return Collections.emptyList();
}
return Collections.unmodifiableList(this.backupMasters);
}