-
Notifications
You must be signed in to change notification settings - Fork 109
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Backplane auto-recovery is now Auto-Recovery * New shared abstract base class * Better MemoryBackplane * Xml docs * Docs * Better backpressure handling for backplane + tests * Bug fix for #168 * Add support for inspecting a value being evicted (to support disposability) * Superior backplane auto-recovery handling, like, new super dooper version, like mega awesome * Make Simulator fully interactive + add chaos-related functions * Better backplane tests * Add support for testing ReThrowBackplaneExceptions when duplicating * Benchmarks update * Dependencies update * Fix links * Add cancellation support to chaos components * A lot of internal refactoring * Add snapshot testing for v0.23.0 * Add distributed cache background execution tests * Add SetAlwaysDelay(...) overload * Mega refactoring of the entire distributed management * General cleanup * Add Timestamp to AutoRecoveryItem + minor action fix * Major refactoring, cleanup, speed up and more edge cases handled * More cleanup * Add support for splitted background run of background operations (distributed cache vs backplane) * Better tests * Small fix * Cleanup * Simulator: add random updates * Add ConnectionMultiplexerFactory to RedisBackplane * Add EditorBrowsable attribute * Add ReThrowOriginalExceptions and some specific exceptions for serialization, distributed cache and backplane errors * Make some of the classes sealed for better perf * File-scoped namespaces * Split auto-recovery code into the new AutoRecoveryService * Better auto-recovery log levels + some refactoring * Add backplane wire format modifier for * Simulator stuff * More sealed stuff * Better simulator UI * Small memory optimization * Add FromByteArray/ToByteArray static methods to BackplaneMessage * Start using the new native binary serialization methods for BackplaneMessage * Better logging * Add v0.23.0 payload samples * Start using message serialization to better mimic real backplanes * Add PhysicalExpiration to FusionCacheMemoryEntry * V0.24.0 metadata
- Loading branch information
1 parent
1be828a
commit 24d5d0b
Showing
180 changed files
with
14,059 additions
and
10,453 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
72 changes: 72 additions & 0 deletions
72
benchmarks/ZiggyCreatures.FusionCache.Benchmarks/ExecutionBenchmarkAsync.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
using System; | ||
using System.Threading; | ||
using System.Threading.Tasks; | ||
using BenchmarkDotNet.Attributes; | ||
using BenchmarkDotNet.Columns; | ||
using BenchmarkDotNet.Configs; | ||
using ZiggyCreatures.Caching.Fusion.Internals; | ||
|
||
namespace ZiggyCreatures.Caching.Fusion.Benchmarks | ||
{ | ||
[MemoryDiagnoser] | ||
[Config(typeof(Config))] | ||
public class ExecutionBenchmarkAsync | ||
{ | ||
private class Config : ManualConfig | ||
{ | ||
public Config() | ||
{ | ||
AddColumn( | ||
StatisticColumn.P95 | ||
); | ||
} | ||
} | ||
|
||
private async Task ExecutorAsync() | ||
{ | ||
for (int i = 0; i < 1_000_000_000; i++) | ||
{ | ||
i++; | ||
} | ||
} | ||
|
||
[Benchmark(Baseline = true)] | ||
public async Task WithTimeout() | ||
{ | ||
await RunUtils.RunAsyncActionAdvancedAsync( | ||
async _ => await ExecutorAsync(), | ||
TimeSpan.FromSeconds(2), | ||
false, | ||
true | ||
); | ||
} | ||
|
||
[Benchmark] | ||
public async Task WithTimeout2() | ||
{ | ||
await RunUtils.RunAsyncActionAdvancedAsync( | ||
async _ => await ExecutorAsync(), | ||
TimeSpan.FromSeconds(2), | ||
true, | ||
true | ||
); | ||
} | ||
|
||
[Benchmark] | ||
public async Task WithoutTimeout() | ||
{ | ||
await RunUtils.RunAsyncActionAdvancedAsync( | ||
async _ => await ExecutorAsync(), | ||
Timeout.InfiniteTimeSpan, | ||
true, | ||
true | ||
); | ||
} | ||
|
||
[Benchmark] | ||
public async Task Raw() | ||
{ | ||
await ExecutorAsync(); | ||
} | ||
} | ||
} |
71 changes: 71 additions & 0 deletions
71
benchmarks/ZiggyCreatures.FusionCache.Benchmarks/ExecutionBenchmarkSync.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
using System; | ||
using System.Threading; | ||
using BenchmarkDotNet.Attributes; | ||
using BenchmarkDotNet.Columns; | ||
using BenchmarkDotNet.Configs; | ||
using ZiggyCreatures.Caching.Fusion.Internals; | ||
|
||
namespace ZiggyCreatures.Caching.Fusion.Benchmarks | ||
{ | ||
[MemoryDiagnoser] | ||
[Config(typeof(Config))] | ||
public class ExecutionBenchmarkSync | ||
{ | ||
private class Config : ManualConfig | ||
{ | ||
public Config() | ||
{ | ||
AddColumn( | ||
StatisticColumn.P95 | ||
); | ||
} | ||
} | ||
|
||
private void Executor() | ||
{ | ||
for (int i = 0; i < 1_000_000_000; i++) | ||
{ | ||
i++; | ||
} | ||
} | ||
|
||
[Benchmark(Baseline = true)] | ||
public void WithTimeout() | ||
{ | ||
RunUtils.RunSyncActionAdvanced( | ||
_ => Executor(), | ||
TimeSpan.FromSeconds(2), | ||
false, | ||
true | ||
); | ||
} | ||
|
||
[Benchmark] | ||
public void WithTimeout2() | ||
{ | ||
RunUtils.RunSyncActionAdvanced( | ||
_ => Executor(), | ||
TimeSpan.FromSeconds(2), | ||
true, | ||
true | ||
); | ||
} | ||
|
||
[Benchmark] | ||
public void WithoutTimeout() | ||
{ | ||
RunUtils.RunSyncActionAdvanced( | ||
_ => Executor(), | ||
Timeout.InfiniteTimeSpan, | ||
true, | ||
true | ||
); | ||
} | ||
|
||
[Benchmark] | ||
public void Raw() | ||
{ | ||
Executor(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.