public static final class MapState.Builder extends Object implements InputOutputResultItemsPathBuilder<MapState.Builder>, ParametersBuilder<MapState.Builder>, ResultSelectorBuilder<MapState.Builder>
MapState.Buildable.Utilspublic MapState.Builder comment(String comment)
comment - New comment.public MapState.Builder maxConcurrency(Integer maxConcurrency)
maxConcurrency - New comment.public MapState.Builder iterator(Iterator.Builder iteratorBuilder)
iteratorBuilder - Instance of Iterator.Builder. Note that
the Iterator object is not built until the MapState is built so any modifications on the
state builder will be reflected in this object.public MapState.Builder inputPath(String inputPath)
InputOutputPathBuilderinputPath in interface InputOutputPathBuilder<MapState.Builder>inputPath - New path value.public MapState.Builder resultPath(String resultPath)
ResultPathBuilderresultPath in interface ResultPathBuilder<MapState.Builder>resultPath - New path value.public MapState.Builder itemsPath(String itemsPath)
InputOutputResultItemsPathBuilderitemsPath in interface InputOutputResultItemsPathBuilder<MapState.Builder>itemsPath - New path value.public MapState.Builder outputPath(String outputPath)
InputOutputPathBuilderoutputPath in interface InputOutputPathBuilder<MapState.Builder>outputPath - New path value.public MapState.Builder parameters(String parameters)
ParametersBuilder
{
...
"Parameters": {
"flagged": true,
"parts": {
"first.$": "$.vals[0]",
"last3.$": "$.vals[3:]"
}
}
...
}
And suppose that the input to the state is as follows:
{
"flagged": 7,
"vals": [0, 10, 20, 30, 40, 50]
}
Then the effective input to the task will be as follows:
{
"flagged": true,
"parts": {
"first": 0,
"last3": [30, 40, 50]
}
}
parameters in interface ParametersBuilder<MapState.Builder>parameters - Raw JSON string representing Parameters value.public MapState.Builder parameters(Object parameters)
ParametersBuilder
{
...
"Parameters": {
"flagged": true,
"parts": {
"first.$": "$.vals[0]",
"last3.$": "$.vals[3:]"
}
}
...
}
And suppose that the input to the state is as follows:
{
"flagged": 7,
"vals": [0, 10, 20, 30, 40, 50]
}
Then the effective input to the task will be as follows:
{
"flagged": true,
"parts": {
"first": 0,
"last3": [30, 40, 50]
}
}
parameters in interface ParametersBuilder<MapState.Builder>parameters - Object that will be serialized into the JSON document representing this states parameters.public MapState.Builder resultSelector(String resultSelector)
ResultSelectorBuilder
{
...
"ResultSelector": {
"ClusterId.$": "$.output.ClusterId",
"ResourceType.$": "$.resourceType"
},
"ResultPath": "$.EMROutput"
...
}
Suppose the result of the Task is as follows:
{
...
"resourceType": "elasticmapreduce",
"output": {
"ClusterId": "AKIAIOSFODNN7EXAMPLE"
}
...
}
Then the effective result from the task will be as follows:
{
...
"EMROutput": {
"ClusterId": "AKIAIOSFODNN7EXAMPLE",
"ResourceType": "elasticmapreduce"
}
...
}
resultSelector in interface ResultSelectorBuilder<MapState.Builder>resultSelector - Raw JSON string representing ResultSelector value.public MapState.Builder resultSelector(Object resultSelector)
ResultSelectorBuilder
{
...
"ResultSelector": {
"ClusterId.$": "$.output.ClusterId",
"ResourceType.$": "$.resourceType"
},
"ResultPath": "$.EMROutput"
...
}
Suppose the result of the Task is as follows:
{
...
"resourceType": "elasticmapreduce",
"output": {
"ClusterId": "AKIAIOSFODNN7EXAMPLE"
}
...
}
Then the effective result from the task will be as follows:
{
...
"EMROutput": {
"ClusterId": "AKIAIOSFODNN7EXAMPLE",
"ResourceType": "elasticmapreduce"
}
...
}
resultSelector in interface ResultSelectorBuilder<MapState.Builder>resultSelector - Object that will be serialized into the JSON document representing this state's ResultSelector.public MapState.Builder transition(Transition.Builder builder)
builder - New transition.public MapState.Builder retriers(Retrier.Builder... retrierBuilders)
Retriers to this states retries. If a single branch fails then the entire map state is
considered failed and eligible for retry.retrierBuilders - Instances of Retrier.Builder. Note
that the Retrier object is not built until the MapState is built so any modifications on
the state builder will be reflected in this object.public MapState.Builder retrier(Retrier.Builder retrierBuilder)
Retrier to this states retries. If a single branch fails then the entire map state is
considered failed and eligible for retry.retrierBuilder - Instance of Retrier.Builder. Note
that the Retrier object is not built until the MapState is built so any modifications on
the
state builder will be reflected in this object.public MapState.Builder catchers(Catcher.Builder... catcherBuilders)
Catchers to this states catchers. If a single branch fails then the entire map state
is considered failed and eligible to be caught.catcherBuilders - Instances of Catcher.Builder. Note
that the Catcher object is not built until the MapState is built so any modifications on
the state builder will be reflected in this object.public MapState.Builder catcher(Catcher.Builder catcherBuilder)
Catcher to this states catchers. If a single branch fails then the entire map state
is
considered failed and eligible to be caught.catcherBuilder - Instance of Catcher.Builder. Note
that the Catcher object is not built until the MapState is built so any modifications on
the
state builder will be reflected in this object.Copyright © 2024. All rights reserved.