aboutsummaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'plugins')
-rw-r--r--plugins/ObjectCacheServer/src/Cache/CacheStore.cs4
-rw-r--r--plugins/ObjectCacheServer/src/ICacheStore.cs4
-rw-r--r--plugins/VNLib.Data.Caching.Providers.Redis/src/RedisClientCacheEntry.cs14
-rw-r--r--plugins/VNLib.Data.Caching.Providers.Redis/src/VNLib.Data.Caching.Providers.Redis.csproj2
-rw-r--r--plugins/VNLib.Data.Caching.Providers.VNCache/src/BucketLocalManagerFactory.cs36
-rw-r--r--plugins/VNLib.Data.Caching.Providers.VNCache/src/Clustering/ClusterNodeIndex.cs89
-rw-r--r--plugins/VNLib.Data.Caching.Providers.VNCache/src/FBMCacheClient.cs4
-rw-r--r--plugins/VNLib.Data.Caching.Providers.VNCache/src/MemoryCache.cs4
-rw-r--r--plugins/VNLib.Data.Caching.Providers.VNCache/src/RemoteBackedMemoryCache.cs14
-rw-r--r--plugins/VNLib.Data.Caching.Providers.VNCache/src/VNCacheBase.cs4
-rw-r--r--plugins/VNLib.Data.Caching.Providers.VNCache/src/VNCacheClient.cs4
11 files changed, 112 insertions, 67 deletions
diff --git a/plugins/ObjectCacheServer/src/Cache/CacheStore.cs b/plugins/ObjectCacheServer/src/Cache/CacheStore.cs
index 02ed9b1..75abe37 100644
--- a/plugins/ObjectCacheServer/src/Cache/CacheStore.cs
+++ b/plugins/ObjectCacheServer/src/Cache/CacheStore.cs
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2023 Vaughn Nugent
+* Copyright (c) 2024 Vaughn Nugent
*
* Library: VNLib
* Package: ObjectCacheServer
@@ -54,7 +54,7 @@ namespace VNLib.Data.Caching.ObjectCache.Server.Cache
}
///<inheritdoc/>
- ValueTask ICacheStore.AddOrUpdateBlobAsync<T>(string objectId, string? alternateId, ObjectDataReader<T> bodyData, T state, CancellationToken token)
+ ValueTask ICacheStore.AddOrUpdateBlobAsync<T>(string objectId, string? alternateId, ObjectDataGet<T> bodyData, T state, CancellationToken token)
{
return Listener.Cache.AddOrUpdateObjectAsync(objectId, alternateId, bodyData, state, default, token);
}
diff --git a/plugins/ObjectCacheServer/src/ICacheStore.cs b/plugins/ObjectCacheServer/src/ICacheStore.cs
index a638169..dcc9b6e 100644
--- a/plugins/ObjectCacheServer/src/ICacheStore.cs
+++ b/plugins/ObjectCacheServer/src/ICacheStore.cs
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2023 Vaughn Nugent
+* Copyright (c) 2024 Vaughn Nugent
*
* Library: VNLib
* Package: ObjectCacheServer
@@ -38,7 +38,7 @@ namespace VNLib.Data.Caching.ObjectCache.Server
/// <param name="state">The state parameter to pass to the data callback</param>
/// <param name="token">A token to cancel the async operation</param>
/// <returns>A value task that represents the async operation</returns>
- ValueTask AddOrUpdateBlobAsync<T>(string objectId, string? alternateId, ObjectDataReader<T> bodyData, T state, CancellationToken token = default);
+ ValueTask AddOrUpdateBlobAsync<T>(string objectId, string? alternateId, ObjectDataGet<T> bodyData, T state, CancellationToken token = default);
/// <summary>
/// Clears all items from the store
diff --git a/plugins/VNLib.Data.Caching.Providers.Redis/src/RedisClientCacheEntry.cs b/plugins/VNLib.Data.Caching.Providers.Redis/src/RedisClientCacheEntry.cs
index f80c750..360be58 100644
--- a/plugins/VNLib.Data.Caching.Providers.Redis/src/RedisClientCacheEntry.cs
+++ b/plugins/VNLib.Data.Caching.Providers.Redis/src/RedisClientCacheEntry.cs
@@ -211,8 +211,8 @@ namespace VNLib.Data.Caching.Providers.Redis
///<inheritdoc/>
public async Task AddOrUpdateAsync<T>(string key, string? newKey, T value, ICacheObjectSerializer serialzer, CancellationToken cancellation)
{
- _ = key ?? throw new ArgumentNullException(nameof(key));
- _ = serialzer ?? throw new ArgumentNullException(nameof(serialzer));
+ ArgumentException.ThrowIfNullOrWhiteSpace(key);
+ ArgumentNullException.ThrowIfNull(serialzer);
//Alloc update buffer
using AddOrUpdateBuffer buffer = new(_defaultHeap, InitialWriterBufferSize, false);
@@ -231,7 +231,7 @@ namespace VNLib.Data.Caching.Providers.Redis
}
///<inheritdoc/>
- public async Task AddOrUpdateAsync<T>(string key, string? newKey, ObjectDataReader<T> callback, T state, CancellationToken cancellation)
+ public async Task AddOrUpdateAsync<T>(string key, string? newKey, ObjectDataGet<T> callback, T state, CancellationToken cancellation)
{
/*
* Because the redis database only allows ReadonlyMemory when
@@ -253,7 +253,7 @@ namespace VNLib.Data.Caching.Providers.Redis
await _database.KeyRenameAsync(key, newKey);
}
- static IMemoryOwner<byte> AllocAndCopy(ObjectDataReader<T> callback, T state, IUnmangedHeap heap, ref int length)
+ static IMemoryOwner<byte> AllocAndCopy(ObjectDataGet<T> callback, T state, IUnmangedHeap heap, ref int length)
{
//Get the buffer from the callback
ReadOnlySpan<byte> data = callback(state);
@@ -276,7 +276,8 @@ namespace VNLib.Data.Caching.Providers.Redis
///<inheritdoc/>
public async Task<T?> GetAsync<T>(string key, ICacheObjectDeserializer deserializer, CancellationToken cancellation)
{
- _ = deserializer ?? throw new ArgumentNullException(nameof(deserializer));
+ ArgumentException.ThrowIfNullOrWhiteSpace(key);
+ ArgumentNullException.ThrowIfNull(deserializer);
//Try to get the value from the cache
RedisValue value = await _database.StringGetAsync(key);
@@ -293,7 +294,8 @@ namespace VNLib.Data.Caching.Providers.Redis
///<inheritdoc/>
public async Task GetAsync<T>(string key, ObjectDataSet<T> callback, T state, CancellationToken cancellation)
{
- _ = callback ?? throw new ArgumentNullException(nameof(callback));
+ ArgumentException.ThrowIfNullOrWhiteSpace(key);
+ ArgumentNullException.ThrowIfNull(callback);
//Try to get the value from the cache
RedisValue value = await _database.StringGetAsync(key);
diff --git a/plugins/VNLib.Data.Caching.Providers.Redis/src/VNLib.Data.Caching.Providers.Redis.csproj b/plugins/VNLib.Data.Caching.Providers.Redis/src/VNLib.Data.Caching.Providers.Redis.csproj
index dd2d9ca..c71ee72 100644
--- a/plugins/VNLib.Data.Caching.Providers.Redis/src/VNLib.Data.Caching.Providers.Redis.csproj
+++ b/plugins/VNLib.Data.Caching.Providers.Redis/src/VNLib.Data.Caching.Providers.Redis.csproj
@@ -39,7 +39,7 @@
</ItemGroup>
<ItemGroup>
- <PackageReference Include="StackExchange.Redis" Version="2.7.10" />
+ <PackageReference Include="StackExchange.Redis" Version="2.7.17" />
</ItemGroup>
<ItemGroup>
diff --git a/plugins/VNLib.Data.Caching.Providers.VNCache/src/BucketLocalManagerFactory.cs b/plugins/VNLib.Data.Caching.Providers.VNCache/src/BucketLocalManagerFactory.cs
index 0f49849..793e9fe 100644
--- a/plugins/VNLib.Data.Caching.Providers.VNCache/src/BucketLocalManagerFactory.cs
+++ b/plugins/VNLib.Data.Caching.Providers.VNCache/src/BucketLocalManagerFactory.cs
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2023 Vaughn Nugent
+* Copyright (c) 2024 Vaughn Nugent
*
* Library: VNLib
* Package: ObjectCacheServer
@@ -37,6 +37,22 @@ using VNLib.Plugins.Extensions.Loading;
namespace VNLib.Data.Caching.Providers.VNCache
{
+ /*
+ * How it works.
+ *
+ * The built-in object cache stores allow for a memory manager to be specified for
+ * each bucket. Since all operations on buckets are mutually exclusive, we can
+ * use a single heap for each bucket to get a little more performance on memory
+ * operations since no locking is required.
+ *
+ * This class may be called by a dependency injection container, or directly
+ * created calling the Create function. Configuration may specify allocation
+ * flags, currently only the zero all flag is supported.
+ *
+ * By default we just use the process global heap configuration to inizalize new
+ * private heap instances.
+ */
+
[ConfigurationName("memory_manager", Required = false)]
internal sealed class BucketLocalManagerFactory : VnDisposeable, ICacheMemoryManagerFactory
{
@@ -47,9 +63,9 @@ namespace VNLib.Data.Caching.Providers.VNCache
public ICacheEntryMemoryManager CreateForBucket(uint bucketId)
{
//Init a new heap for a individual bucket
- IUnmangedHeap localHeap = MemoryUtil.InitializeNewHeapForProcess();
+ IUnmangedHeap localHeap = MemoryUtil.InitializeNewHeapForProcess(_zeroAll);
- BucketLocalManager manager = new (localHeap, bucketId, _zeroAll);
+ BucketLocalManager manager = new (localHeap, bucketId);
_managers.AddLast(manager);
return manager;
@@ -97,16 +113,16 @@ namespace VNLib.Data.Caching.Providers.VNCache
* to get a little more performance on memory operations
*/
- private sealed record class BucketLocalManager(IUnmangedHeap Heap, uint BucketId, bool Zero) : ICacheEntryMemoryManager
+ private sealed record class BucketLocalManager(IUnmangedHeap Heap, uint BucketId) : ICacheEntryMemoryManager
{
///<inheritdoc/>
- public object AllocHandle(uint size) => Heap.Alloc<byte>(size, Zero);
+ public object AllocHandle(uint size) => Heap.Alloc<byte>(size, false);
///<inheritdoc/>
public void FreeHandle(object handle)
{
- _ = handle ?? throw new ArgumentNullException(nameof(handle));
+ ArgumentNullException.ThrowIfNull(handle);
MemoryHandle<byte> _handle = Unsafe.As<object, MemoryHandle<byte>>(ref handle);
//Free the handle
@@ -116,7 +132,7 @@ namespace VNLib.Data.Caching.Providers.VNCache
///<inheritdoc/>
public uint GetHandleSize(object handle)
{
- _ = handle ?? throw new ArgumentNullException(nameof(handle));
+ ArgumentNullException.ThrowIfNull(handle);
MemoryHandle<byte> _handle = Unsafe.As<object, MemoryHandle<byte>>(ref handle);
return (uint)_handle.Length;
@@ -125,7 +141,7 @@ namespace VNLib.Data.Caching.Providers.VNCache
///<inheritdoc/>
public Span<byte> GetSpan(object handle, uint offset, uint length)
{
- _ = handle ?? throw new ArgumentNullException(nameof(handle));
+ ArgumentNullException.ThrowIfNull(handle);
MemoryHandle<byte> _handle = Unsafe.As<object, MemoryHandle<byte>>(ref handle);
return _handle.GetOffsetSpan(offset, checked((int)length));
@@ -134,7 +150,7 @@ namespace VNLib.Data.Caching.Providers.VNCache
///<inheritdoc/>
public MemoryHandle PinHandle(object handle, int offset)
{
- _ = handle ?? throw new ArgumentNullException(nameof(handle));
+ ArgumentNullException.ThrowIfNull(handle);
MemoryHandle<byte> _handle = Unsafe.As<object, MemoryHandle<byte>>(ref handle);
//Pin the handle
@@ -144,7 +160,7 @@ namespace VNLib.Data.Caching.Providers.VNCache
///<inheritdoc/>
public void ResizeHandle(object handle, uint newSize)
{
- _ = handle ?? throw new ArgumentNullException(nameof(handle));
+ ArgumentNullException.ThrowIfNull(handle);
MemoryHandle<byte> _handle = Unsafe.As<object, MemoryHandle<byte>>(ref handle);
//Resize the handle
diff --git a/plugins/VNLib.Data.Caching.Providers.VNCache/src/Clustering/ClusterNodeIndex.cs b/plugins/VNLib.Data.Caching.Providers.VNCache/src/Clustering/ClusterNodeIndex.cs
index a8fb0e1..c9cd746 100644
--- a/plugins/VNLib.Data.Caching.Providers.VNCache/src/Clustering/ClusterNodeIndex.cs
+++ b/plugins/VNLib.Data.Caching.Providers.VNCache/src/Clustering/ClusterNodeIndex.cs
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2023 Vaughn Nugent
+* Copyright (c) 2024 Vaughn Nugent
*
* Library: VNLib
* Package: VNLib.Data.Caching.Providers.VNCache
@@ -48,39 +48,73 @@ namespace VNLib.Data.Caching.Providers.VNCache.Clustering
public static IClusterNodeIndex CreateIndex(CacheClientConfiguration config)
{
- //Create a named semaphore to ensure only one index is created per app domain
- using Semaphore sm = new (1, 1, APP_DOMAIN_KEY, out _);
+ /* TEMPORARY:
+ * Named semaphores are only supported on Windows, which allowed synchronized communication between
+ * plugins, but this is not supported on Linux. This will be replaced with a more robust solution
+ * in the future. For now they will just need to be separate instances.
+ *
+ * Remember while plugins are in the same app-domain, they do not share an assembly
+ * load context which means unless the default ALC contains the desired types, types won't unify
+ * so we have to use "ghetto" features to avoid interprocess communication, in the same process...
+ */
- if (!sm.WaitOne(500))
+ if (OperatingSystem.IsWindows())
{
- throw new TimeoutException("Failed to access the Cluster index shared semaphore");
- }
+ //Create a named semaphore to ensure only one index is created per app domain
+ using Semaphore sm = new (1, 1, APP_DOMAIN_KEY, out _);
- try
- {
- //Try to get an existing index from the app domain
- object? remoteIndex = AppDomain.CurrentDomain.GetData(APP_DOMAIN_KEY);
- if (remoteIndex == null)
+ if (!sm.WaitOne(500))
+ {
+ throw new TimeoutException("Failed to access the Cluster index shared semaphore");
+ }
+
+ try
{
- //Create a new index and store it in the app domain
- IClusterNodeIndex index = new LocalHandler(config);
- AppDomain.CurrentDomain.SetData(APP_DOMAIN_KEY, index);
- return index;
+ //Try to get an existing index from the app domain global storage pool
+ object? remoteIndex = AppDomain.CurrentDomain.GetData(APP_DOMAIN_KEY);
+ if (remoteIndex == null)
+ {
+ //Create a new index and store it in the app domain
+ IClusterNodeIndex index = new LocalHandler(config);
+ AppDomain.CurrentDomain.SetData(APP_DOMAIN_KEY, index);
+ return index;
+ }
+ else
+ {
+ //Use the existing index
+ return new RemoteHandler(remoteIndex);
+ }
}
- else
+ finally
{
- //Use the existing index
- return new RemoteHandler(remoteIndex);
+ sm.Release();
}
}
- finally
+ else
{
- sm.Release();
+ return new LocalHandler(config);
}
}
+ /*
+ * So a bit of explaination.
+ *
+ * Plugins don't share types. Each plugin will load this package into its own ALC. Which will
+ * cause n instances of the cluster indext manager. Which can cause unecessary http traffic
+ * building the cluster index multiple times. In an attemt to avoid this, I try to share a single
+ * cluster index instance across all plugins in the same app domain.
+ *
+ * To do this a local handler instance is loaded into whichever plugin accuires the named semaphore
+ * first, and then the instance is stored in the app domain global storage pool. If its found,
+ * then other plugins will use the remote handler to access the index.
+ *
+ * The remote handler, attempts to use reflection to get function delegates and call the local
+ * handler functions via reflection.
+ *
+ * Unless VNLib.Core supports a new way to safley share types across ALCs, this is my solution.
+ */
- record class LocalHandler(CacheClientConfiguration Config) : IClusterNodeIndex, IIntervalScheduleable
+ sealed class LocalHandler(CacheClientConfiguration Config) : IClusterNodeIndex, IIntervalScheduleable
{
private Task _currentUpdate = Task.CompletedTask;
@@ -115,18 +149,11 @@ namespace VNLib.Data.Caching.Providers.VNCache.Clustering
}
}
- class RemoteHandler : IClusterNodeIndex
+ sealed class RemoteHandler(object RemoteIndex) : IClusterNodeIndex
{
- private readonly Func<string?> _remoteSerializer;
- private readonly Func<CancellationToken, Task> _waitTask;
+ private readonly Func<string?> _remoteSerializer = ManagedLibrary.GetMethod<Func<string?>>(RemoteIndex, nameof(LocalHandler.SerializeNextNode), BindingFlags.NonPublic);
- public RemoteHandler(object RemoteIndex)
- {
- //get the serializer method
- _remoteSerializer = ManagedLibrary.GetMethod<Func<string?>>(RemoteIndex, nameof(LocalHandler.SerializeNextNode), BindingFlags.NonPublic);
- //get the wait task method
- _waitTask = ManagedLibrary.GetMethod<Func<CancellationToken, Task>>(RemoteIndex, nameof(WaitForDiscoveryAsync), BindingFlags.Public);
- }
+ private readonly Func<CancellationToken, Task> _waitTask = ManagedLibrary.GetMethod<Func<CancellationToken, Task>>(RemoteIndex, nameof(WaitForDiscoveryAsync), BindingFlags.Public);
///<inheritdoc/>
public CacheNodeAdvertisment? GetNextNode()
diff --git a/plugins/VNLib.Data.Caching.Providers.VNCache/src/FBMCacheClient.cs b/plugins/VNLib.Data.Caching.Providers.VNCache/src/FBMCacheClient.cs
index e21cf4a..73783dc 100644
--- a/plugins/VNLib.Data.Caching.Providers.VNCache/src/FBMCacheClient.cs
+++ b/plugins/VNLib.Data.Caching.Providers.VNCache/src/FBMCacheClient.cs
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2023 Vaughn Nugent
+* Copyright (c) 2024 Vaughn Nugent
*
* Library: VNLib
* Package: VNLib.Data.Caching.Providers.VNCache
@@ -317,7 +317,7 @@ namespace VNLib.Data.Caching.Providers.VNCache
}
///<inheritdoc/>
- public override Task AddOrUpdateAsync<T>(string key, string? newKey, ObjectDataReader<T> callback, T state, CancellationToken cancellation)
+ public override Task AddOrUpdateAsync<T>(string key, string? newKey, ObjectDataGet<T> callback, T state, CancellationToken cancellation)
{
return !IsConnected
? throw new InvalidOperationException("The underlying client is not connected to a cache node")
diff --git a/plugins/VNLib.Data.Caching.Providers.VNCache/src/MemoryCache.cs b/plugins/VNLib.Data.Caching.Providers.VNCache/src/MemoryCache.cs
index 98f6a3d..0c1a2b5 100644
--- a/plugins/VNLib.Data.Caching.Providers.VNCache/src/MemoryCache.cs
+++ b/plugins/VNLib.Data.Caching.Providers.VNCache/src/MemoryCache.cs
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2023 Vaughn Nugent
+* Copyright (c) 2024 Vaughn Nugent
*
* Library: VNLib
* Package: VNLib.Data.Caching.Providers.VNCache
@@ -192,7 +192,7 @@ namespace VNLib.Data.Caching.Providers.VNCache
}
///<inheritdoc/>
- public override Task AddOrUpdateAsync<T>(string key, string? newKey, ObjectDataReader<T> callback, T state, CancellationToken cancellation)
+ public override Task AddOrUpdateAsync<T>(string key, string? newKey, ObjectDataGet<T> callback, T state, CancellationToken cancellation)
{
//Update object data
return _memCache.AddOrUpdateObjectAsync(key, newKey, callback, state, default, cancellation).AsTask();
diff --git a/plugins/VNLib.Data.Caching.Providers.VNCache/src/RemoteBackedMemoryCache.cs b/plugins/VNLib.Data.Caching.Providers.VNCache/src/RemoteBackedMemoryCache.cs
index c7952b4..ddc6c4b 100644
--- a/plugins/VNLib.Data.Caching.Providers.VNCache/src/RemoteBackedMemoryCache.cs
+++ b/plugins/VNLib.Data.Caching.Providers.VNCache/src/RemoteBackedMemoryCache.cs
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2023 Vaughn Nugent
+* Copyright (c) 2024 Vaughn Nugent
*
* Library: VNLib
* Package: VNLib.Data.Caching.Providers.VNCache
@@ -83,8 +83,8 @@ namespace VNLib.Data.Caching.Providers.VNCache
public RemoteBackedMemoryCache(MemoryCacheConfig memCache, IGlobalCacheProvider backingStore, BucketLocalManagerFactory? factory):base(memCache)
{
- _ = memCache ?? throw new ArgumentNullException(nameof(memCache));
- _ = backingStore ?? throw new ArgumentNullException(nameof(backingStore));
+ ArgumentNullException.ThrowIfNull(memCache);
+ ArgumentNullException.ThrowIfNull(backingStore);
memCache.Validate();
@@ -166,9 +166,9 @@ namespace VNLib.Data.Caching.Providers.VNCache
///<inheritdoc/>
public override async Task GetAsync<T>(string key, ObjectDataSet<T> setter, T state, CancellationToken cancellation)
{
- _ = key ?? throw new ArgumentNullException(nameof(key));
- _ = setter ?? throw new ArgumentNullException(nameof(setter));
-
+ ArgumentException.ThrowIfNullOrWhiteSpace(key);
+ ArgumentNullException.ThrowIfNull(setter);
+
CheckConnected();
IBlobCacheBucket bucket = _memCache.GetBucket(key);
@@ -220,7 +220,7 @@ namespace VNLib.Data.Caching.Providers.VNCache
}
///<inheritdoc/>
- public override async Task AddOrUpdateAsync<T>(string key, string? newKey, ObjectDataReader<T> callback, T state, CancellationToken cancellation)
+ public override async Task AddOrUpdateAsync<T>(string key, string? newKey, ObjectDataGet<T> callback, T state, CancellationToken cancellation)
{
CheckConnected();
diff --git a/plugins/VNLib.Data.Caching.Providers.VNCache/src/VNCacheBase.cs b/plugins/VNLib.Data.Caching.Providers.VNCache/src/VNCacheBase.cs
index f8a9ca6..c337ef4 100644
--- a/plugins/VNLib.Data.Caching.Providers.VNCache/src/VNCacheBase.cs
+++ b/plugins/VNLib.Data.Caching.Providers.VNCache/src/VNCacheBase.cs
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2023 Vaughn Nugent
+* Copyright (c) 2024 Vaughn Nugent
*
* Library: VNLib
* Package: VNLib.Data.Caching.Providers.VNCache
@@ -49,7 +49,7 @@ namespace VNLib.Data.Caching.Providers.VNCache
public abstract Task AddOrUpdateAsync<T>(string key, string? newKey, T value, ICacheObjectSerializer serialzer, CancellationToken cancellation);
///<inheritdoc/>
- public abstract Task AddOrUpdateAsync<T>(string key, string? newKey, ObjectDataReader<T> callback, T state, CancellationToken cancellation);
+ public abstract Task AddOrUpdateAsync<T>(string key, string? newKey, ObjectDataGet<T> callback, T state, CancellationToken cancellation);
///<inheritdoc/>
public abstract Task<bool> DeleteAsync(string key, CancellationToken cancellation);
diff --git a/plugins/VNLib.Data.Caching.Providers.VNCache/src/VNCacheClient.cs b/plugins/VNLib.Data.Caching.Providers.VNCache/src/VNCacheClient.cs
index 9807939..20b9f69 100644
--- a/plugins/VNLib.Data.Caching.Providers.VNCache/src/VNCacheClient.cs
+++ b/plugins/VNLib.Data.Caching.Providers.VNCache/src/VNCacheClient.cs
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2023 Vaughn Nugent
+* Copyright (c) 2024 Vaughn Nugent
*
* Library: VNLib
* Package: VNLib.Data.Caching.Providers.VNCache
@@ -173,7 +173,7 @@ namespace VNLib.Data.Caching.Providers.VNCache
}
///<inheritdoc/>
- public Task AddOrUpdateAsync<T>(string key, string? newKey, ObjectDataReader<T> callback, T state, CancellationToken cancellation)
+ public Task AddOrUpdateAsync<T>(string key, string? newKey, ObjectDataGet<T> callback, T state, CancellationToken cancellation)
{
return _client.AddOrUpdateAsync(key, newKey, callback, state, cancellation);
}