Exemplo n.º 1
0
        public override async Task <long> LogKV(Memory <byte> key, Memory <byte> value, bool isDeleted)
        {
            var c   = GetChannelWriter();
            var tcs = new TaskCompletionSource <long>();
            var po  = new PutOperation();

            po.LoggingCompleted = tcs;
            po.Key     = key;
            po.Value   = value;
            po.Deleted = isDeleted;
            await c.WriteAsync(po);

            var off = await po.LoggingCompleted.Task;

            return(off);
        }