Example #1
0
 /// <inheritdoc/>
 public virtual bool ConcurrentReader(ref Key key, ref Input input, ref Value value, ref Output dst, ref ReadInfo readInfo) => true;
Example #2
0
 /// <inheritdoc/>
 public virtual bool SingleReader(ref Key key, ref Input input, ref Value value, ref Output dst, ref ReadInfo readInfo) => true;
 public bool ConcurrentReader(ref Key key, ref Input input, ref Value value, ref Output dst, ref RecordInfo recordInfo, ref ReadInfo readInfo, out bool lockFailed)
 {
     lockFailed = false;
     if (_clientSession.functions.ConcurrentReader(ref key, ref input, ref value, ref dst, ref readInfo))
     {
         return(true);
     }
     if (readInfo.Action == ReadAction.Expire)
     {
         recordInfo.Tombstone = true;
     }
     return(false);
 }
 public bool SingleReader(ref Key key, ref Input input, ref Value value, ref Output dst, ref RecordInfo recordInfo, ref ReadInfo readInfo)
 => _clientSession.functions.SingleReader(ref key, ref input, ref value, ref dst, ref readInfo);
Example #5
0
 public bool ConcurrentReaderLock(ref Key key, ref Input input, ref Value value, ref Output dst, ref RecordInfo recordInfo, ref ReadInfo readInfo, out bool lockFailed)
 {
     if (!recordInfo.LockShared())
     {
         lockFailed = true;
         return(false);
     }
     try
     {
         lockFailed = false;
         return(ConcurrentReaderNoLock(ref key, ref input, ref value, ref dst, ref recordInfo, ref readInfo));
     }
     finally
     {
         recordInfo.UnlockShared();
     }
 }
Example #6
0
 public bool ConcurrentReader(ref Key key, ref Input input, ref Value value, ref Output dst, ref RecordInfo recordInfo, ref ReadInfo readInfo, out bool lockFailed)
 {
     lockFailed = false;
     return(this.DisableLocking
                        ? ConcurrentReaderNoLock(ref key, ref input, ref value, ref dst, ref recordInfo, ref readInfo)
                        : ConcurrentReaderLock(ref key, ref input, ref value, ref dst, ref recordInfo, ref readInfo, out lockFailed));
 }
Example #7
0
 /// <inheritdoc />
 public override bool ConcurrentReader(ref SpanByte key, ref SpanByte input, ref SpanByte value, ref byte[] dst, ref ReadInfo readInfo)
 {
     dst = value.ToByteArray();
     return(true);
 }