ServiceRemotingCallbackClient Interface

public interface ServiceRemotingCallbackClient

Defines the interface that must be implemented for providing callback mechanism from the remoting listener to the client.

Method Summary

Modifier and Type Method and Description
void oneWayMessage(ServiceRemotingMessageHeaders messageHeaders, byte[] requestBody)

Sends a one way message to the client.

CompletableFuture<byte[]> requestResponseAsync(ServiceRemotingMessageHeaders messageHeaders, byte[] requestBody)

Sends a message to the client and gets the response.

Method Details

oneWayMessage

public void oneWayMessage(ServiceRemotingMessageHeaders messageHeaders, byte[] requestBody)

Sends a one way message to the client.

Parameters:

messageHeaders - Message headers
requestBody - Message body

Throws:

IOException - IOException

requestResponseAsync

public CompletableFuture requestResponseAsync(ServiceRemotingMessageHeaders messageHeaders, byte[] requestBody)

Sends a message to the client and gets the response.

Parameters:

messageHeaders - Message headers
requestBody - Message body

Returns:

Response body

Applies to