diff --git a/README.md b/README.md index c7d45467..b2611ffd 100644 --- a/README.md +++ b/README.md @@ -15,10 +15,12 @@ Linux, Mono | - ## CacheManager Nuget Packages +> **Important:** The 1.2.x version of CacheManager does only upgrade the .NET Standard support and uses the latest StackExchange.Redis package which comes with some breaking changes (dropped .Signed package). + | Package Name | .Net 4.0 | .Net 4.5 | .NET Standard |--------------| :-------: | :-------: | :-------: -| [CacheManager.Core][Core.nuget] | x | x | 1.2 -| [CacheManager.StackExchange.Redis][Redis.nuget] | - | x | 1.5 +| [CacheManager.Core][Core.nuget] | x | x | 1.2, 2.0 +| [CacheManager.StackExchange.Redis][Redis.nuget] | - | 4.6.1 | 2.0 | [CacheManager.SystemRuntimeCaching][SystemRuntimeCaching.nuget] | x | x | - | [CacheManager.Microsoft.Extensions.Caching.Memory][MSCache.nuget] | - | x | 1.3 | [CacheManager.Microsoft.Extensions.Configuration][Configuration.nuget] | - | x | 1.2 diff --git a/samples/AspnetCore.WebApp/AspnetCore.WebApp.csproj b/samples/AspnetCore.WebApp/AspnetCore.WebApp.csproj index 8ab25c3d..f2768773 100644 --- a/samples/AspnetCore.WebApp/AspnetCore.WebApp.csproj +++ b/samples/AspnetCore.WebApp/AspnetCore.WebApp.csproj @@ -1,12 +1,11 @@  - netcoreapp1.0 + netcoreapp2.0 true AspnetCore.WebApp Exe AspnetCore.WebApp - 1.1.1 @@ -24,24 +23,7 @@ - - - - - - - - - - - - + - - - - - - - + \ No newline at end of file diff --git a/samples/CacheManager.Examples/CacheManager.Examples.csproj b/samples/CacheManager.Examples/CacheManager.Examples.csproj index 550dfb58..46991139 100644 --- a/samples/CacheManager.Examples/CacheManager.Examples.csproj +++ b/samples/CacheManager.Examples/CacheManager.Examples.csproj @@ -3,7 +3,7 @@ CacheManager.Examples Console Application MICHA - net451 + net462 CacheManager.Examples Exe CacheManager.Examples @@ -20,23 +20,17 @@ + + + - - - - - - - - - + - - + \ No newline at end of file diff --git a/samples/CacheManager.Examples/Program.cs b/samples/CacheManager.Examples/Program.cs index 358eeda1..72b24f00 100644 --- a/samples/CacheManager.Examples/Program.cs +++ b/samples/CacheManager.Examples/Program.cs @@ -2,11 +2,9 @@ using System.Threading; using CacheManager.Core; using Microsoft.Extensions.Logging; -#if NET451 -using Microsoft.Practices.Unity; -#else using Unity; -#endif +using Unity.Injection; +using Unity.Lifetime; namespace CacheManager.Examples { @@ -361,4 +359,4 @@ public void PutSomethingIntoTheCache() _cache.Put("myKey", "something"); } } -} \ No newline at end of file +} diff --git a/src/CacheManager.Core/CacheManager.Core.csproj b/src/CacheManager.Core/CacheManager.Core.csproj index 0e184b17..e2026570 100644 --- a/src/CacheManager.Core/CacheManager.Core.csproj +++ b/src/CacheManager.Core/CacheManager.Core.csproj @@ -2,7 +2,7 @@ CacheManager is an open source caching abstraction layer for .NET written in C#. It supports various cache providers and implements many advanced features. The Core library contains all base interfaces and tools. You should install at least one other CacheManager package to get cache handle implementations. - net40;net45;netstandard1.2 + net40;net45;netstandard1.2;netstandard2 False Caching;Cache;CacheManager;Distributed Cache;StackExchange Redis;Azure AppFabric;Memcached @@ -15,6 +15,7 @@ $(DefineConstants);NETSTANDARD - - + + $(DefineConstants);NETSTANDARD + \ No newline at end of file diff --git a/src/CacheManager.Couchbase/CacheManager.Couchbase.csproj b/src/CacheManager.Couchbase/CacheManager.Couchbase.csproj index 9f1f4501..20e26c61 100644 --- a/src/CacheManager.Couchbase/CacheManager.Couchbase.csproj +++ b/src/CacheManager.Couchbase/CacheManager.Couchbase.csproj @@ -2,7 +2,7 @@ CacheManager extension package to work with Couchbase as a distributed cache. CacheManager is an open source caching abstraction layer for .NET written in C#. It supports various cache providers and implements many advanced features. - net45;netstandard1.5 + net452;netstandard1.5 true true Caching;Cache;CacheManager;Distributed Cache;StackExchange Redis;Azure AppFabric;Memcached @@ -11,9 +11,9 @@ - + - + \ No newline at end of file diff --git a/src/CacheManager.Microsoft.Extensions.Caching.Memory/CacheManager.Microsoft.Extensions.Caching.Memory.csproj b/src/CacheManager.Microsoft.Extensions.Caching.Memory/CacheManager.Microsoft.Extensions.Caching.Memory.csproj index 5476e3a9..a69d5e7e 100644 --- a/src/CacheManager.Microsoft.Extensions.Caching.Memory/CacheManager.Microsoft.Extensions.Caching.Memory.csproj +++ b/src/CacheManager.Microsoft.Extensions.Caching.Memory/CacheManager.Microsoft.Extensions.Caching.Memory.csproj @@ -3,7 +3,7 @@ CacheManager is an open source caching abstraction layer for .NET written in C#. It supports various cache providers and implements many advanced features. This package contains the specific cache handle for Microsoft.Extensions.Caching.Memory. MichaConrad;AuroraDysis - net451;netstandard1.3 + net451;netstandard1.3;netstandard2 true true Caching;Cache;CacheManager;Distributed Cache;StackExchange Redis;Azure AppFabric;Memcached @@ -11,11 +11,10 @@ - + - - - + + \ No newline at end of file diff --git a/src/CacheManager.Microsoft.Extensions.Configuration/CacheManager.Microsoft.Extensions.Configuration.csproj b/src/CacheManager.Microsoft.Extensions.Configuration/CacheManager.Microsoft.Extensions.Configuration.csproj index 29524929..c5c53762 100644 --- a/src/CacheManager.Microsoft.Extensions.Configuration/CacheManager.Microsoft.Extensions.Configuration.csproj +++ b/src/CacheManager.Microsoft.Extensions.Configuration/CacheManager.Microsoft.Extensions.Configuration.csproj @@ -2,7 +2,7 @@ CacheManager extension package to use Microsoft.Extensions.Configuration to configure the CacheManager instance. CacheManager is an open source caching abstraction layer for .NET written in C#. This is the ASP.NET Core configuration integration package. - net45;netstandard1.2 + net45;netstandard1.2;netstandard2 true true Caching;Cache;CacheManager;Distributed Cache;StackExchange Redis;Azure AppFabric;Memcached @@ -10,16 +10,18 @@ - + + $(DefineConstants);NETSTANDARD + + + - - - - $(DefineConstants);NETSTANDARD - - + + + + \ No newline at end of file diff --git a/src/CacheManager.Microsoft.Extensions.Logging/CacheManager.Microsoft.Extensions.Logging.csproj b/src/CacheManager.Microsoft.Extensions.Logging/CacheManager.Microsoft.Extensions.Logging.csproj index 98826d92..0c4c1d60 100644 --- a/src/CacheManager.Microsoft.Extensions.Logging/CacheManager.Microsoft.Extensions.Logging.csproj +++ b/src/CacheManager.Microsoft.Extensions.Logging/CacheManager.Microsoft.Extensions.Logging.csproj @@ -2,7 +2,7 @@ CacheManager extension package to work with Microsoft.Extensions.Logging as logging provider. CacheManager is an open source caching abstraction layer for .NET written in C#. The ASP.NET Core logging provides a bridge to the Microsoft.Extensions.Logging framework. - net45;netstandard1.2 + net45;netstandard1.2;netstandard2 true true Caching;Cache;CacheManager;Distributed Cache;StackExchange Redis;Azure AppFabric;Memcached @@ -10,11 +10,10 @@ - + - - - + + \ No newline at end of file diff --git a/src/CacheManager.Serialization.Json/CacheManager.Serialization.Json.csproj b/src/CacheManager.Serialization.Json/CacheManager.Serialization.Json.csproj index f4969afe..f5f57f03 100644 --- a/src/CacheManager.Serialization.Json/CacheManager.Serialization.Json.csproj +++ b/src/CacheManager.Serialization.Json/CacheManager.Serialization.Json.csproj @@ -2,19 +2,18 @@ CacheManager extension package providing JSON serialization for distributed caches. CacheManager is an open source caching abstraction layer for .NET written in C#. It supports various cache providers and implements many advanced features. The Core library contains a Newtonsoft.Json based serializer implementation which can be used instead of the default binary serializer. - netstandard1.2;net40;net45 + netstandard2;netstandard1.2;net40;net45 true true Caching;Cache;CacheManager;Distributed Cache;StackExchange Redis;Azure AppFabric;Memcached - - - - + + - + + \ No newline at end of file diff --git a/src/CacheManager.Serialization.ProtoBuf/CacheManager.Serialization.ProtoBuf.csproj b/src/CacheManager.Serialization.ProtoBuf/CacheManager.Serialization.ProtoBuf.csproj index 09c61d7a..f3ca3899 100644 --- a/src/CacheManager.Serialization.ProtoBuf/CacheManager.Serialization.ProtoBuf.csproj +++ b/src/CacheManager.Serialization.ProtoBuf/CacheManager.Serialization.ProtoBuf.csproj @@ -3,7 +3,7 @@ CacheManager extension package providing ProtoBuf serialization for distributed caches. CacheManager is an open source caching abstraction layer for .NET written in C#. It supports various cache providers and implements many advanced features, the ProtoBuf serializer can be used in place of the default Binary Serializer Wenisman;MichaConrad - netstandard1.3;net40;net45 + netstandard2;netstandard1.3;net40;net45 true true Caching;Cache;CacheManager;Distributed Cache;StackExchange Redis;Azure AppFabric;Memcached @@ -12,10 +12,6 @@ - - - - - + \ No newline at end of file diff --git a/src/CacheManager.StackExchange.Redis/CacheManager.StackExchange.Redis.csproj b/src/CacheManager.StackExchange.Redis/CacheManager.StackExchange.Redis.csproj index 09252326..1beb0a57 100644 --- a/src/CacheManager.StackExchange.Redis/CacheManager.StackExchange.Redis.csproj +++ b/src/CacheManager.StackExchange.Redis/CacheManager.StackExchange.Redis.csproj @@ -2,24 +2,21 @@ CacheManager extension package which adds support for Redis as a distributed cache layer. CacheManager is an open source caching abstraction layer for .NET written in C#. It supports various cache providers and implements many advanced features. - net45;netstandard1.5 + net461;netstandard2 true true Caching;Cache;CacheManager;Distributed Cache;StackExchange Redis;Azure AppFabric;Memcached - + - + - - - - + $(DefineConstants);NETSTANDARD \ No newline at end of file diff --git a/src/CacheManager.StackExchange.Redis/RedisCacheBackplane.cs b/src/CacheManager.StackExchange.Redis/RedisCacheBackplane.cs index 1254d7f1..1504f7f0 100644 --- a/src/CacheManager.StackExchange.Redis/RedisCacheBackplane.cs +++ b/src/CacheManager.StackExchange.Redis/RedisCacheBackplane.cs @@ -149,7 +149,7 @@ protected override void Dispose(bool managed) private void Publish(byte[] message) { - _connection.Subscriber.Publish(_channelName, message, CommandFlags.HighPriority); + _connection.Subscriber.Publish(_channelName, message, CommandFlags.None); } private void PublishMessage(BackplaneMessage message) @@ -317,4 +317,4 @@ private void Subscribe() CommandFlags.FireAndForget); } } -} \ No newline at end of file +} diff --git a/src/CacheManager.StackExchange.Redis/RedisConnectionManager.cs b/src/CacheManager.StackExchange.Redis/RedisConnectionManager.cs index b79b934b..b951f7eb 100644 --- a/src/CacheManager.StackExchange.Redis/RedisConnectionManager.cs +++ b/src/CacheManager.StackExchange.Redis/RedisConnectionManager.cs @@ -175,7 +175,6 @@ public IConnectionMultiplexer Connect() } } - connection.PreserveAsyncOrder = false; _connections.Add(_connectionString, connection); } } @@ -228,4 +227,4 @@ public override void Write(char[] buffer, int index, int count) } } } -} \ No newline at end of file +} diff --git a/test/CacheManager.Benchmarks/BaseCacheManagerBenchmark.cs b/test/CacheManager.Benchmarks/BaseCacheManagerBenchmark.cs index b165682c..35c72be4 100644 --- a/test/CacheManager.Benchmarks/BaseCacheManagerBenchmark.cs +++ b/test/CacheManager.Benchmarks/BaseCacheManagerBenchmark.cs @@ -44,7 +44,7 @@ private static IMemcachedClientConfiguration MemcachedConfig new BaseCacheManager(BaseConfig.Builder .WithMemcachedCacheHandle(new MemcachedClient(MemcachedConfig)).Build()); - [Setup] + [GlobalSetup] public void Setup() { DictionaryCache.Clear(); @@ -207,4 +207,4 @@ protected override void Excecute(ICacheManager cache) } #endregion upate -} \ No newline at end of file +} diff --git a/test/CacheManager.Benchmarks/CacheManager.Benchmarks.csproj b/test/CacheManager.Benchmarks/CacheManager.Benchmarks.csproj index f34ceb8f..bb2897c0 100644 --- a/test/CacheManager.Benchmarks/CacheManager.Benchmarks.csproj +++ b/test/CacheManager.Benchmarks/CacheManager.Benchmarks.csproj @@ -1,6 +1,6 @@  - net46 + net462 CacheManager.Benchmarks Exe CacheManager.Benchmarks @@ -19,12 +19,10 @@ - + true - - \ No newline at end of file diff --git a/test/CacheManager.Benchmarks/GzBenchmark.cs b/test/CacheManager.Benchmarks/GzBenchmark.cs index ad50d49a..02941f18 100644 --- a/test/CacheManager.Benchmarks/GzBenchmark.cs +++ b/test/CacheManager.Benchmarks/GzBenchmark.cs @@ -15,7 +15,7 @@ public class GzBenchmark private byte[] _payload; - [Setup] + [GlobalSetup] public void Setup() { var list = new List(); @@ -170,4 +170,4 @@ public byte[] Decompression(byte[] compressedData) } } } -} \ No newline at end of file +} diff --git a/test/CacheManager.Benchmarks/SerializationBenchmark.cs b/test/CacheManager.Benchmarks/SerializationBenchmark.cs index 34ffe55a..12b015cb 100644 --- a/test/CacheManager.Benchmarks/SerializationBenchmark.cs +++ b/test/CacheManager.Benchmarks/SerializationBenchmark.cs @@ -31,7 +31,7 @@ public class SerializationBenchmark private BondSimpleJsonCacheSerializer _bondSimpleJson = new BondSimpleJsonCacheSerializer(); private readonly Type _pocoType = typeof(TestPoco); - [Setup] + [GlobalSetup] public void Setup() { var rnd = new Random(); @@ -171,4 +171,4 @@ public void BondSimpleJsonSerializer() }); } } -} \ No newline at end of file +} diff --git a/test/CacheManager.Config.Tests/CacheManager.Config.Tests.csproj b/test/CacheManager.Config.Tests/CacheManager.Config.Tests.csproj index 109f93f7..191b8f3e 100644 --- a/test/CacheManager.Config.Tests/CacheManager.Config.Tests.csproj +++ b/test/CacheManager.Config.Tests/CacheManager.Config.Tests.csproj @@ -4,7 +4,7 @@ CacheManager is an open source caching abstraction layer for .NET written in C#. It supports various cache providers and implements many advanced features. 1.0.1 MichaConrad - net451;netcoreapp1.0 + net462 CacheManager.Config.Tests Exe ../../tools/key.snk @@ -31,7 +31,7 @@ - + @@ -49,7 +49,6 @@ $(DefineConstants);NETCOREAPP - + - - + \ No newline at end of file diff --git a/test/CacheManager.Config.Tests/Program.cs b/test/CacheManager.Config.Tests/Program.cs index 6d91af7e..b38b5638 100644 --- a/test/CacheManager.Config.Tests/Program.cs +++ b/test/CacheManager.Config.Tests/Program.cs @@ -3,10 +3,6 @@ using System.Threading; using CacheManager.Core; using CacheManager.Redis; -#if !NETCOREAPP -using Enyim.Caching; -using Enyim.Caching.Configuration; -#endif using Microsoft.Extensions.Logging; namespace CacheManager.Config.Tests diff --git a/test/CacheManager.Events.Tests/CacheManager.Events.Tests.csproj b/test/CacheManager.Events.Tests/CacheManager.Events.Tests.csproj index 14df05af..546c70fb 100644 --- a/test/CacheManager.Events.Tests/CacheManager.Events.Tests.csproj +++ b/test/CacheManager.Events.Tests/CacheManager.Events.Tests.csproj @@ -19,5 +19,4 @@ - - \ No newline at end of file + diff --git a/test/CacheManager.Events.Tests/RedisAndMemoryCommand.cs b/test/CacheManager.Events.Tests/RedisAndMemoryCommand.cs index 5a550c18..6d5ff06a 100644 --- a/test/CacheManager.Events.Tests/RedisAndMemoryCommand.cs +++ b/test/CacheManager.Events.Tests/RedisAndMemoryCommand.cs @@ -93,7 +93,7 @@ public override async Task Execute() cacheA.TryUpdate(key, (oldVal) => oldVal + 1, out int? newValue); - _multiplexer.GetDatabase(0).KeyDelete(key, CommandFlags.HighPriority); + _multiplexer.GetDatabase(0).KeyDelete(key, CommandFlags.None); await Task.Delay(0); }); @@ -106,4 +106,4 @@ public override async Task Execute() return 0; } } -} \ No newline at end of file +} diff --git a/test/CacheManager.MSConfiguration.TypeLoad.Tests/CacheManager.MSConfiguration.TypeLoad.Tests.csproj b/test/CacheManager.MSConfiguration.TypeLoad.Tests/CacheManager.MSConfiguration.TypeLoad.Tests.csproj index 2908724d..3ddaeb7a 100644 --- a/test/CacheManager.MSConfiguration.TypeLoad.Tests/CacheManager.MSConfiguration.TypeLoad.Tests.csproj +++ b/test/CacheManager.MSConfiguration.TypeLoad.Tests/CacheManager.MSConfiguration.TypeLoad.Tests.csproj @@ -3,7 +3,7 @@ CacheManager.MSConfiguration.TypeLoad.Tests Class Library Micha - net452;netcoreapp1.0 + net462;netcoreapp1.0 CacheManager.MSConfiguration.TypeLoad.Tests CacheManager.MSConfiguration.TypeLoad.Tests true @@ -27,7 +27,7 @@ - + diff --git a/test/CacheManager.Tests/CacheManager.Tests.csproj b/test/CacheManager.Tests/CacheManager.Tests.csproj index 7616cc6f..fe3adccc 100644 --- a/test/CacheManager.Tests/CacheManager.Tests.csproj +++ b/test/CacheManager.Tests/CacheManager.Tests.csproj @@ -2,7 +2,7 @@ - net452;netcoreapp1.1 + net462 1.0.0 CacheManager.Tests @@ -38,7 +38,7 @@ - + @@ -59,14 +59,14 @@ - + $(DefineConstants);REDISENABLED;MOCK_HTTPCONTEXT_ENABLED; $(DefineConstants);REDISENABLED;NETCOREAPP; -