public interface IConnection extends AutoCloseable
Modifier and Type | Method and Description |
---|---|
void |
close()
close this connection.
|
Map<Integer,Load> |
getLoad(Collection<Integer> tasks)
Get the current load for the given tasks.
|
int |
getPort()
Get the port for this connection.
|
void |
send(Iterator<TaskMessage> msgs)
send batch messages.
|
void |
sendBackPressureStatus(BackPressureStatus bpStatus)
Sends the back pressure metrics to all downstream connections.
|
void |
sendLoadMetrics(Map<Integer,Double> taskToLoad)
Send load metrics to all downstream connections.
|
void sendLoadMetrics(Map<Integer,Double> taskToLoad)
taskToLoad
- a map from the task id to the load for that task.void sendBackPressureStatus(BackPressureStatus bpStatus)
void send(Iterator<TaskMessage> msgs)
Map<Integer,Load> getLoad(Collection<Integer> tasks)
tasks
- the tasks to look for.int getPort()
void close()
close
in interface AutoCloseable
Copyright © 2023 The Apache Software Foundation. All rights reserved.