org.zodiac.sentinel.base.cluster.ClusterInitFunc Maven / Gradle / Ivy
package org.zodiac.sentinel.base.cluster;
import org.zodiac.commons.util.Asserts;
import org.zodiac.sentinel.base.constants.SentinelBaseConstants;
import org.zodiac.sentinel.base.support.AbstratcInitFunc;
public abstract class ClusterInitFunc extends AbstratcInitFunc {
private final String namespacePrefix;
public ClusterInitFunc() {
this(SentinelBaseConstants.NS_PREFIX);
}
public ClusterInitFunc(String namespacePrefix) {
this.namespacePrefix = Asserts.notBlank(namespacePrefix, "namespace prefix % is blank", namespacePrefix);
}
protected final String getNamespacePrefix() {
return namespacePrefix;
}
}