public interface MappingRuleAction
Modifier and Type | Method and Description |
---|---|
MappingRuleResult |
execute(VariableContext variables)
This method is the main logic of the action, it shall determine based on
the mapping context, what should be the action's result.
|
MappingRuleResult |
getFallback()
Returns the fallback action to be taken if the main action (result returned
by the execute method) fails.
|
MappingRuleAction |
setFallbackDefaultPlacement()
Sets the fallback method to place to default, if the action cannot be
executed.
|
MappingRuleAction |
setFallbackReject()
Sets the fallback method to reject, if the action cannot be executed the
application will get rejected.
|
MappingRuleAction |
setFallbackSkip()
Sets the fallback method to skip, if the action cannot be executed
We move onto the next rule, ignoring this one.
|
void |
validate(MappingRuleValidationContext ctx)
This method is responsible for config validation, the context contains all
information required for validation, method should throw an exception on
detectable setup errors.
|
MappingRuleResult getFallback()
MappingRuleResult execute(VariableContext variables)
variables
- The variable context, which contains all the variablesMappingRuleAction setFallbackReject()
MappingRuleAction setFallbackSkip()
MappingRuleAction setFallbackDefaultPlacement()
void validate(MappingRuleValidationContext ctx) throws org.apache.hadoop.yarn.exceptions.YarnException
ctx
- Validation context with all the necessary objects and helper
methods required during validationorg.apache.hadoop.yarn.exceptions.YarnException
- is thrown on validation errorCopyright © 2008–2024 Apache Software Foundation. All rights reserved.