- java.lang.Object
-
- org.redkale.cluster.HttpRpcClient
-
- org.redkale.cluster.spi.HttpClusterRpcClient
-
- 所有已实现的接口:
ClusterRpcClient<WebRequest,HttpResult<byte[]>>
public class HttpClusterRpcClient extends HttpRpcClient
没有配置MQ的情况下依赖ClusterAgent实现的默认HttpRpcClient实例详情见: https://redkale.org
- 从以下版本开始:
- 2.1.0
- 作者:
- zhangjx
-
-
字段概要
字段 修饰符和类型 字段 说明 protected ClusterAgent
clusterAgent
protected HttpClient
httpClient
protected HttpLocalRpcClient
localClient
protected Logger
logger
protected ConcurrentHashMap<String,Boolean>
topicServletMap
protected WebClient
webClient
-
构造器概要
构造器 构造器 说明 HttpClusterRpcClient(Application application, String resourceName, ClusterAgent clusterAgent)
-
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 protected String
getNodeid()
CompletableFuture<Void>
produceMessage(String topic, Serializable userid, String groupid, WebRequest request)
protected InetSocketAddress
randomAddress(WebRequest req, Set<InetSocketAddress> addrs)
protected CompletableFuture<HttpResult<byte[]>>
sendEachAddressAsync(WebRequest req, String requestPath, HttpHeaders clientHeaders, byte[] clientBody, Iterator<InetSocketAddress> it)
CompletableFuture<HttpResult<byte[]>>
sendMessage(String topic, Serializable userid, String groupid, WebRequest request)
-
从类继承的方法 org.redkale.cluster.HttpRpcClient
generateHttpReqTopic, generateHttpReqTopic, generateHttpReqTopic, produceMessage, produceMessage, produceMessage, produceMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage
-
-
-
-
字段详细资料
-
logger
protected final Logger logger
-
localClient
protected final HttpLocalRpcClient localClient
-
topicServletMap
protected final ConcurrentHashMap<String,Boolean> topicServletMap
-
clusterAgent
protected ClusterAgent clusterAgent
-
webClient
protected WebClient webClient
-
httpClient
protected HttpClient httpClient
-
-
构造器详细资料
-
HttpClusterRpcClient
public HttpClusterRpcClient(Application application, String resourceName, ClusterAgent clusterAgent)
-
-
方法详细资料
-
getNodeid
protected String getNodeid()
- 指定者:
getNodeid
在类中HttpRpcClient
-
sendMessage
public CompletableFuture<HttpResult<byte[]>> sendMessage(String topic, Serializable userid, String groupid, WebRequest request)
- 指定者:
sendMessage
在类中HttpRpcClient
-
produceMessage
public CompletableFuture<Void> produceMessage(String topic, Serializable userid, String groupid, WebRequest request)
- 指定者:
produceMessage
在类中HttpRpcClient
-
randomAddress
protected InetSocketAddress randomAddress(WebRequest req, Set<InetSocketAddress> addrs)
-
sendEachAddressAsync
protected CompletableFuture<HttpResult<byte[]>> sendEachAddressAsync(WebRequest req, String requestPath, HttpHeaders clientHeaders, byte[] clientBody, Iterator<InetSocketAddress> it)
-
-