Beispiel #1
0
        public override async Task <bool> ContainsAsync(T item)
        {
            var itemData        = ToSafeData(item);
            var requestMessage  = SetContainsCodec.EncodeRequest(Name, itemData);
            var responseMessage = await Cluster.Messaging.SendToPartitionOwnerAsync(requestMessage, PartitionId).CfAwait();

            return(SetContainsCodec.DecodeResponse(responseMessage).Response);
        }
        public override bool Contains(T item)
        {
            var request = SetContainsCodec.EncodeRequest(GetName(), ToData(item));

            return(Invoke(request, m => SetContainsCodec.DecodeResponse(m).response));
        }