|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
@InterfaceStability.Evolving public interface EdgeManager
This interface defines the routing of the event between tasks of producer and consumer vertices. The routing is bi-directional. Users can customize the routing by providing an implementation of this interface. Implementations must provide a 0 argument public constructor.
| Method Summary | |
|---|---|
int |
getNumDestinationConsumerTasks(int sourceTaskIndex,
int numDestinationTasks)
Get the number of destination tasks that consume data from the source task |
int |
getNumDestinationTaskPhysicalInputs(int numSourceTasks,
int destinationTaskIndex)
Get the number of physical inputs on the destination task |
int |
getNumSourceTaskPhysicalOutputs(int numDestinationTasks,
int sourceTaskIndex)
Get the number of physical outputs on the source task |
void |
initialize(EdgeManagerContext edgeManagerContext)
Initializes the EdgeManager. |
void |
routeDataMovementEventToDestination(DataMovementEvent event,
int sourceTaskIndex,
int numDestinationTasks,
Map<Integer,List<Integer>> inputIndicesToTaskIndices)
Return the routing information to inform consumers about the source task output that is now available. |
int |
routeInputErrorEventToSource(InputReadErrorEvent event,
int destinationTaskIndex)
Return the source task index to which to send the input error event |
void |
routeInputSourceTaskFailedEventToDestination(int sourceTaskIndex,
int numDestinationTasks,
Map<Integer,List<Integer>> inputIndicesToTaskIndices)
Return the routing information to inform consumers about the failure of a source task whose outputs have been potentially lost. |
| Method Detail |
|---|
void initialize(EdgeManagerContext edgeManagerContext)
EdgeManagerContext when the
edgeManager is replaced.
edgeManagerContext - the context within which this EdgeManager will run. Includes
information like configuration which the user may have specified
while setting up the edge.
int getNumDestinationTaskPhysicalInputs(int numSourceTasks,
int destinationTaskIndex)
numSourceTasks - Total number of source tasksdestinationTaskIndex - Index of destination task for which number of
inputs is needed
int getNumSourceTaskPhysicalOutputs(int numDestinationTasks,
int sourceTaskIndex)
numDestinationTasks - Total number of destination taskssourceTaskIndex - Index of the source task for which number of outputs
is needed
void routeDataMovementEventToDestination(DataMovementEvent event,
int sourceTaskIndex,
int numDestinationTasks,
Map<Integer,List<Integer>> inputIndicesToTaskIndices)
event - Data movement eventsourceTaskIndex - Source tasknumDestinationTasks - Total number of destination tasksinputIndicesToTaskIndices - Map via which the routing information is returned
void routeInputSourceTaskFailedEventToDestination(int sourceTaskIndex,
int numDestinationTasks,
Map<Integer,List<Integer>> inputIndicesToTaskIndices)
sourceTaskIndex - Source tasknumDestinationTasks - Total number of destination tasksinputIndicesToTaskIndices - Map via which the routing information is returned
int getNumDestinationConsumerTasks(int sourceTaskIndex,
int numDestinationTasks)
sourceTaskIndex - Source task indexnumDestinationTasks - Total number of destination tasks
int routeInputErrorEventToSource(InputReadErrorEvent event,
int destinationTaskIndex)
event - Input read error event. Has more information about the errordestinationTaskIndex - Destination task that reported the error
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||