@InterfaceAudience.Public @InterfaceStability.Unstable public abstract class EdgeManagerPlugin extends Object
Constructor and Description |
---|
EdgeManagerPlugin(EdgeManagerPluginContext context)
Create an instance of the EdgeManagerPlugin.
|
Modifier and Type | Method and Description |
---|---|
EdgeManagerPluginContext |
getContext()
Return the
EdgeManagerPluginContext for this specific instance of
the vertex manager. |
abstract int |
getNumDestinationConsumerTasks(int sourceTaskIndex)
Get the number of destination tasks that consume data from the source task
|
abstract int |
getNumDestinationTaskPhysicalInputs(int destinationTaskIndex)
Get the number of physical inputs on the destination task
|
abstract int |
getNumSourceTaskPhysicalOutputs(int sourceTaskIndex)
Get the number of physical outputs on the source task
|
abstract void |
initialize()
Initializes the EdgeManagerPlugin.
|
abstract void |
routeDataMovementEventToDestination(DataMovementEvent event,
int sourceTaskIndex,
int sourceOutputIndex,
Map<Integer,List<Integer>> destinationTaskAndInputIndices)
Return the routing information to inform consumers about the source task
output that is now available.
|
abstract int |
routeInputErrorEventToSource(InputReadErrorEvent event,
int destinationTaskIndex,
int destinationFailedInputIndex)
Return the source task index to which to send the input error event
|
abstract void |
routeInputSourceTaskFailedEventToDestination(int sourceTaskIndex,
Map<Integer,List<Integer>> destinationTaskAndInputIndices)
Return the routing information to inform consumers about the failure of a
source task whose outputs have been potentially lost.
|
public EdgeManagerPlugin(EdgeManagerPluginContext context)
context
- the context within which this EdgeManagerPlugin will run. Includes
information like configuration which the user may have specified
while setting up the edge.public abstract void initialize() throws Exception
EdgeManagerPluginContext
when the
EdgeManagerPlugin is replaced.Exception
public abstract int getNumDestinationTaskPhysicalInputs(int destinationTaskIndex) throws Exception
destinationTaskIndex
- Index of destination task for which number of
inputs is neededException
public abstract int getNumSourceTaskPhysicalOutputs(int sourceTaskIndex) throws Exception
sourceTaskIndex
- Index of the source task for which number of outputs
is neededException
public abstract void routeDataMovementEventToDestination(DataMovementEvent event, int sourceTaskIndex, int sourceOutputIndex, Map<Integer,List<Integer>> destinationTaskAndInputIndices) throws Exception
event
- Data movement event that contains the output informationsourceTaskIndex
- Source task that produced the eventsourceOutputIndex
- Index of the physical output on the source task that produced the
eventdestinationTaskAndInputIndices
- Map via which the routing information is returnedException
public abstract void routeInputSourceTaskFailedEventToDestination(int sourceTaskIndex, Map<Integer,List<Integer>> destinationTaskAndInputIndices) throws Exception
sourceTaskIndex
- Source taskdestinationTaskAndInputIndices
- Map via which the routing information is returnedException
public abstract int getNumDestinationConsumerTasks(int sourceTaskIndex) throws Exception
sourceTaskIndex
- Source task indexException
public abstract int routeInputErrorEventToSource(InputReadErrorEvent event, int destinationTaskIndex, int destinationFailedInputIndex) throws Exception
event
- Input read error event. Has more information about the errordestinationTaskIndex
- Destination task that reported the errordestinationFailedInputIndex
- Index of the physical input on the destination task that reported
the errorException
public EdgeManagerPluginContext getContext()
EdgeManagerPluginContext
for this specific instance of
the vertex manager.EdgeManagerPluginContext
for the inputCopyright © 2024 Apache Software Foundation. All rights reserved.