Class ClientSession
- java.lang.Object
-
- org.apache.hugegraph.computer.core.network.session.TransportSession
-
- org.apache.hugegraph.computer.core.network.session.ClientSession
-
public class ClientSession extends TransportSession
-
-
Field Summary
-
Fields inherited from class org.apache.hugegraph.computer.core.network.session.TransportSession
conf, finishId, MAX_REQUEST_ID_UPDATER, maxAckId, maxRequestId, state
-
-
Constructor Summary
Constructors Constructor Description ClientSession(TransportConf conf, java.util.function.Function<Message,java.util.concurrent.Future<java.lang.Void>> sendFunction)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidfinish(long timeout)java.util.concurrent.CompletableFuture<java.lang.Void>finishAsync()booleanflowBlocking()voidonRecvAck(int ackId)voidsendAsync(MessageType messageType, int partition, java.nio.ByteBuffer buffer)voidstart(long timeout)java.util.concurrent.CompletableFuture<java.lang.Void>startAsync()protected voidstateReady()-
Methods inherited from class org.apache.hugegraph.computer.core.network.session.TransportSession
conf, finishId, genFinishId, nextRequestId, state, stateEstablished
-
-
-
-
Constructor Detail
-
ClientSession
public ClientSession(TransportConf conf, java.util.function.Function<Message,java.util.concurrent.Future<java.lang.Void>> sendFunction)
-
-
Method Detail
-
stateReady
protected void stateReady()
- Overrides:
stateReadyin classTransportSession
-
start
public void start(long timeout) throws TransportException- Throws:
TransportException
-
startAsync
public java.util.concurrent.CompletableFuture<java.lang.Void> startAsync()
-
finish
public void finish(long timeout) throws TransportException- Throws:
TransportException
-
finishAsync
public java.util.concurrent.CompletableFuture<java.lang.Void> finishAsync()
-
sendAsync
public void sendAsync(MessageType messageType, int partition, java.nio.ByteBuffer buffer)
-
onRecvAck
public void onRecvAck(int ackId)
-
flowBlocking
public boolean flowBlocking()
-
-