示例#1
0
 private static bool IsMatchedByEndPoint(RaftClusterMember member, IPEndPoint endPoint)
 => member.Endpoint.Equals(endPoint);
示例#2
0
            static async Task <TResponse> TryReceiveMessage(RaftClusterMember sender, IMessage message, IEnumerable <IInputChannel> handlers, MessageReader <TResponse> responseReader, CancellationToken token)
            {
                var responseMsg = await(handlers.TryReceiveMessage(sender, message, null, token) ?? throw new UnexpectedStatusCodeException(new NotImplementedException())).ConfigureAwait(false);

                return(await responseReader(responseMsg, token).ConfigureAwait(false));
            }
示例#3
0
 private static bool IsMatchedById(RaftClusterMember actual, ClusterMemberId expected)
 => actual.Id == expected;