Skip to content

Commit 62a9a91

Browse files
authored
Merge branch 'main' into DependencyUpdates
2 parents 8007f41 + d6f11f6 commit 62a9a91

3 files changed

Lines changed: 12 additions & 0 deletions

File tree

docs/OpenTelemetry.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,3 +96,9 @@ services.AddOpenTelemetry()
9696
```
9797

9898
Easy peasy.
99+
100+
## 📃 Official Registry
101+
102+
FusionCache is also part of the official [OpenTelemetry Registry](https://opentelemetry.io/ecosystem/registry/?s=fusioncache):
103+
104+
![](images/otel-registry.jpg)

docs/images/otel-registry.jpg

42.1 KB
Loading

src/ZiggyCreatures.FusionCache/MicrosoftHybridCache/FusionHybridCache.cs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ public sealed class FusionHybridCache
1414
: HybridCache
1515
{
1616
private const FusionCacheEntryOptions? NoEntryOptions = null;
17+
private const string ClearAllTag = "*";
1718

1819
private readonly IFusionCache _fusionCache;
1920

@@ -99,6 +100,11 @@ public override ValueTask RemoveAsync(string key, CancellationToken cancellation
99100
/// <inheritdoc/>
100101
public override ValueTask RemoveByTagAsync(string tag, CancellationToken cancellationToken = default)
101102
{
103+
if (tag == ClearAllTag)
104+
{
105+
return _fusionCache.ClearAsync(true, NoEntryOptions, cancellationToken);
106+
}
107+
102108
return _fusionCache.RemoveByTagAsync(tag, NoEntryOptions, cancellationToken);
103109
}
104110

0 commit comments

Comments
 (0)