示例#1
0
        /// <inheritdoc/>
        public async Task SetAsync(string key, byte[] value, DistributedCacheEntryOptions options, CancellationToken token = default)
        {
            await FusioCacheChaosUtils.MaybeChaosAsync(ChaosMinDelay, ChaosMaxDelay, ChaosThrowProbability).ConfigureAwait(false);

            await _innerCache.SetAsync(key, value, options, token).ConfigureAwait(false);
        }
示例#2
0
        /// <inheritdoc/>
        public async Task RemoveAsync(string key, CancellationToken token = default)
        {
            await FusioCacheChaosUtils.MaybeChaosAsync(ChaosMinDelay, ChaosMaxDelay, ChaosThrowProbability).ConfigureAwait(false);

            await _innerCache.RemoveAsync(key, token).ConfigureAwait(false);
        }