示例#1
0
 public boolean apply(LoadBalancerRule rule) {
   logger.trace("looking for state on rule %s", checkNotNull(rule, "rule"));
   rule = refresh(rule);
   if (rule == null) return false;
   logger.trace(
       "%s: looking for rule state %s: currently: %s",
       rule.getId(), State.ACTIVE, rule.getState());
   return rule.getState() == State.ACTIVE;
 }
示例#2
0
 private LoadBalancerRule refresh(LoadBalancerRule rule) {
   return client.getLoadBalancerApi().getLoadBalancerRule(rule.getId());
 }