Class GuardOutcome
java.lang.Object
org.frontcache.guard.GuardOutcome
Result of running the guard pipeline for one request: either "carry on to FC_Total" or a
terminal action (reject / redirect) together with the rule that produced it.
Dry-run rules that matched are carried alongside: they do not stop the request, but each one is
written to the failed-requests log so a new rule can be validated against real traffic before it
enforces anything.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final GuardOutcomeno rule matched - the request continues as usual -
Method Summary
Modifier and TypeMethodDescriptionstatic GuardOutcomeA challenge: a redirect tochallengePlugin's page, attarget.static GuardOutcomegetRule()booleanstatic GuardOutcomestatic GuardOutcome
-
Field Details
-
CONTINUE
no rule matched - the request continues as usual
-
-
Method Details
-
terminal
public static GuardOutcome terminal(GuardRule rule, String resolvedTarget, List<GuardRule> dryRunMatches) -
terminal
public static GuardOutcome terminal(GuardRule rule, GuardAction action, String resolvedTarget, List<GuardRule> dryRunMatches) - Parameters:
action- what is done instead of the rule's own action - a challenge rule'selse, or the 429 a challenge answers a request it cannot redirect
-
challenge
-
cont
-
isTerminal
public boolean isTerminal() -
getRule
-
getAction
- Returns:
- what is done - the rule's action, except where a challenge rule fell back to its
elseaction or answered a non-GET with a 429; null for CONTINUE
-
getChallengePlugin
- Returns:
- the plugin a challenge sends the visitor to; null for every other outcome
-
getResolvedTarget
- Returns:
- redirect target with placeholders expanded, or null for non-redirect outcomes
-
getDryRunMatches
-