use of com.predic8.membrane.core.rules.NullRule in project service-proxy by membrane.
the class OAuth2TestUtil method makeExchangeValid.
public static void makeExchangeValid(Exchange exc) throws Exception {
exc.setOriginalRequestUri(exc.getRequest().getUri());
exc.setRule(new NullRule());
}
use of com.predic8.membrane.core.rules.NullRule in project service-proxy by membrane.
the class RuleMatchingInterceptor method handleRequest.
@Override
public Outcome handleRequest(Exchange exc) throws Exception {
if (exc.getRule() != null)
return Outcome.CONTINUE;
Rule rule = getRule(exc);
exc.setRule(rule);
if (exc.getRule().getSslOutboundContext() != null) {
exc.setProperty(Exchange.SSL_CONTEXT, exc.getRule().getSslOutboundContext());
}
if (rule instanceof NullRule) {
handleNoRuleFound(exc);
return Outcome.ABORT;
}
if (xForwardedForEnabled && (rule instanceof AbstractServiceProxy))
insertXForwardedFor(exc);
return Outcome.CONTINUE;
}
Aggregations