类 GatewayRuleManager

java.lang.Object
com.alibaba.csp.sentinel.adapter.gateway.common.rule.GatewayRuleManager

public final class GatewayRuleManager extends Object
从以下版本开始:
1.6.0
作者:
Eric Zhao
  • 方法详细资料

    • register2Property

      public static void register2Property(com.alibaba.csp.sentinel.property.SentinelProperty<Set<GatewayFlowRule>> property)
    • loadRules

      public static boolean loadRules(Set<GatewayFlowRule> rules)
      Load all provided gateway rules into memory, while previous rules will be replaced.
      参数:
      rules - rule set
      返回:
      true if updated, otherwise false
    • getRules

      public static Set<GatewayFlowRule> getRules()
    • getRulesForResource

      public static Set<GatewayFlowRule> getRulesForResource(String resourceName)
    • getConvertedParamRules

      public static List<com.alibaba.csp.sentinel.slots.block.flow.param.ParamFlowRule> getConvertedParamRules(String resourceName)

      Get all converted parameter rules.

      Note: caller SHOULD NOT modify the list and rules.

      参数:
      resourceName - valid resource name
      返回:
      converted parameter rules
    • isValidRule

      public static boolean isValidRule(GatewayFlowRule rule)