- java.lang.Object
-
- org.redkale.cluster.HttpRpcClient
-
- 所有已实现的接口:
ClusterRpcClient<WebRequest,HttpResult<byte[]>>
- 直接已知子类:
HttpClusterRpcClient
,HttpLocalRpcClient
public abstract class HttpRpcClient extends Object implements ClusterRpcClient<WebRequest,HttpResult<byte[]>>
不依赖MessageRecord则可兼容RPC方式详情见: https://redkale.org
- 从以下版本开始:
- 2.1.0
- 作者:
- zhangjx
-
-
构造器概要
构造器 构造器 说明 HttpRpcClient()
-
方法概要
-
-
-
方法详细资料
-
produceMessage
public final CompletableFuture<Void> produceMessage(WebRequest request)
从接口复制的说明:ClusterRpcClient
发送消息,无需响应- 指定者:
produceMessage
在接口中ClusterRpcClient<WebRequest,HttpResult<byte[]>>
- 参数:
request
- 消息体- 返回:
- 应答
-
produceMessage
public final CompletableFuture<Void> produceMessage(Serializable userid, WebRequest request)
-
produceMessage
public final CompletableFuture<Void> produceMessage(Serializable userid, String groupid, WebRequest request)
-
produceMessage
public final CompletableFuture<Void> produceMessage(String topic, WebRequest request)
-
sendMessage
public final CompletableFuture<HttpResult<byte[]>> sendMessage(WebRequest request)
从接口复制的说明:ClusterRpcClient
发送消息,需要响应- 指定者:
sendMessage
在接口中ClusterRpcClient<WebRequest,HttpResult<byte[]>>
- 参数:
request
- 消息体- 返回:
- 应答消息
-
sendMessage
public final CompletableFuture<HttpResult<byte[]>> sendMessage(Serializable userid, WebRequest request)
-
sendMessage
public final CompletableFuture<HttpResult<byte[]>> sendMessage(Serializable userid, String groupid, WebRequest request)
-
sendMessage
public final CompletableFuture<HttpResult<byte[]>> sendMessage(String topic, WebRequest request)
-
sendMessage
public <T> CompletableFuture<T> sendMessage(WebRequest request, Type type)
-
sendMessage
public <T> CompletableFuture<T> sendMessage(Serializable userid, WebRequest request, Type type)
-
sendMessage
public <T> CompletableFuture<T> sendMessage(Serializable userid, String groupid, WebRequest request, Type type)
-
generateHttpReqTopic
public String generateHttpReqTopic(WebRequest request, String path)
-
sendMessage
public abstract CompletableFuture<HttpResult<byte[]>> sendMessage(String topic, Serializable userid, String groupid, WebRequest request)
-
produceMessage
public abstract CompletableFuture<Void> produceMessage(String topic, Serializable userid, String groupid, WebRequest request)
-
getNodeid
protected abstract String getNodeid()
-
-