using Elsa.Caching.Models;
namespace Elsa.Caching;
/// Storage for cache entries. Implementations must distinguish a miss from a cached null.
public interface ICacheProvider
{
bool IsShared { get; }
Task> GetAsync(string key, CancellationToken cancellationToken = default);
Task SetAsync(string key, T? value, CacheEntryOptions options, CancellationToken cancellationToken = default);
Task RemoveAsync(string key, CancellationToken cancellationToken = default);
}
public record CacheResult(bool Found, T? Value);