private String getClusterId() {
    if (!isClusterIdSet.get()) {
      return null;
    }
    // It is ok to read without a lock since clusterId is immutable once set.
    return clusterId.toString();
  }
Returns a cached copy of the cluster ID. null if the cache is not populated.
hbase-server/src/main/java/org/apache/hadoop/hbase/master/CachedClusterId.java