![]() |
VOOZH | about |
dotnet add package BitFaster.Caching --version 2.6.0
NuGet\Install-Package BitFaster.Caching -Version 2.6.0
<PackageReference Include="BitFaster.Caching" Version="2.6.0" />
<PackageVersion Include="BitFaster.Caching" Version="2.6.0" />Directory.Packages.props
<PackageReference Include="BitFaster.Caching" />Project file
paket add BitFaster.Caching --version 2.6.0
#r "nuget: BitFaster.Caching, 2.6.0"
#:package BitFaster.Caching@2.6.0
#addin nuget:?package=BitFaster.Caching&version=2.6.0Install as a Cake Addin
#tool nuget:?package=BitFaster.Caching&version=2.6.0Install as a Cake Tool
High performance, thread-safe in-memory caching primitives for .NET.
ConcurrentLru is a light weight drop in replacement for ConcurrentDictionary, but with bounded size enforced by the TU-Q eviction policy (based on 2Q). There are no background threads, no global locks, concurrent throughput is high, lookups are fast and hit rate outperforms a pure LRU in all tested scenarios.
Choose a capacity and use just like ConcurrentDictionary, but with bounded size:
int capacity = 128;
var lru = new ConcurrentLru<string, SomeItem>(capacity);
var value = lru.GetOrAdd("key", (key) => new SomeItem(key));
Optionally configure ConcurrentLru with a time-based eviction policy, either:
ConcurrentLfu is a drop in replacement for ConcurrentDictionary, but with bounded size enforced by the W-TinyLFU admission policy. ConcurrentLfu has near optimal hit rate and high scalability. Reads and writes are buffered then replayed asynchronously to mitigate lock contention.
Choose a capacity and use just like ConcurrentDictionary, but with bounded size:
int capacity = 128;
var lfu = new ConcurrentLfu<string, SomeItem>(capacity);
var value = lfu.GetOrAdd("key", (key) => new SomeItem(key));
Optionally configure ConcurrentLfu with a time-based eviction policy, either:
Please refer to the wiki for API documentation, and an analysis of hit rate, latency and throughput.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 net5.0 was computed. net5.0-windows net5.0-windows was computed. net6.0 net6.0 is compatible. net6.0-android net6.0-android was computed. net6.0-ios net6.0-ios was computed. net6.0-maccatalyst net6.0-maccatalyst was computed. net6.0-macos net6.0-macos was computed. net6.0-tvos net6.0-tvos was computed. net6.0-windows net6.0-windows was computed. net7.0 net7.0 was computed. net7.0-android net7.0-android was computed. net7.0-ios net7.0-ios was computed. net7.0-maccatalyst net7.0-maccatalyst was computed. net7.0-macos net7.0-macos was computed. net7.0-tvos net7.0-tvos was computed. net7.0-windows net7.0-windows was computed. net8.0 net8.0 was computed. net8.0-android net8.0-android was computed. net8.0-browser net8.0-browser was computed. net8.0-ios net8.0-ios was computed. net8.0-maccatalyst net8.0-maccatalyst was computed. net8.0-macos net8.0-macos was computed. net8.0-tvos net8.0-tvos was computed. net8.0-windows net8.0-windows was computed. net9.0 net9.0 was computed. net9.0-android net9.0-android was computed. net9.0-browser net9.0-browser was computed. net9.0-ios net9.0-ios was computed. net9.0-maccatalyst net9.0-maccatalyst was computed. net9.0-macos net9.0-macos was computed. net9.0-tvos net9.0-tvos was computed. net9.0-windows net9.0-windows was computed. net10.0 net10.0 is compatible. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
| .NET Core | netcoreapp2.0 netcoreapp2.0 was computed. netcoreapp2.1 netcoreapp2.1 was computed. netcoreapp2.2 netcoreapp2.2 was computed. netcoreapp3.0 netcoreapp3.0 was computed. netcoreapp3.1 netcoreapp3.1 is compatible. |
| .NET Standard | netstandard2.0 netstandard2.0 is compatible. netstandard2.1 netstandard2.1 was computed. |
| .NET Framework | net461 net461 was computed. net462 net462 was computed. net463 net463 was computed. net47 net47 was computed. net471 net471 was computed. net472 net472 was computed. net48 net48 was computed. net481 net481 was computed. |
| MonoAndroid | monoandroid monoandroid was computed. |
| MonoMac | monomac monomac was computed. |
| MonoTouch | monotouch monotouch was computed. |
| Tizen | tizen40 tizen40 was computed. tizen60 tizen60 was computed. |
| Xamarin.iOS | xamarinios xamarinios was computed. |
| Xamarin.Mac | xamarinmac xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos xamarinwatchos was computed. |
Showing the top 5 NuGet packages that depend on BitFaster.Caching:
| Package | Downloads |
|---|---|
|
NServiceBus.RabbitMQ
RabbitMQ support for NServiceBus |
|
|
NServiceBus.Transport.AzureServiceBus
Azure Service Bus transport for NServiceBus |
|
|
Splitio
Package Description |
|
|
OPCFoundation.NetStandard.Opc.Ua.Client
OPC UA Client Class Library |
|
|
NServiceBus.AmazonSQS
NServiceBus.AmazonSQS |
Showing the top 9 popular GitHub repositories that depend on BitFaster.Caching:
| Repository | Stars |
|---|---|
|
jellyfin/jellyfin
The Free Software Media System - Server Backend & API
|
|
|
Flow-Launcher/Flow.Launcher
:mag: Quick file search & app launcher for Windows with community-made plugins
|
|
|
OPCFoundation/UA-.NETStandard
OPC Unified Architecture .NET Standard
|
|
|
Nexus-Mods/NexusMods.App
Home of the development of the Nexus Mods App
|
|
|
goatcorp/Dalamud
FFXIV plugin framework and API
|
|
|
planetarium/libplanet
Blockchain in C#/.NET for on-chain, decentralized gaming
|
|
|
RedpointGames/uet
UET (Unreal Engine Tool) makes building and testing Unreal Engine projects and plugins easy. It can distribute builds with BuildGraph, remotely execute automation tests on device and across multiple machines, handles fault tolerance and automatic retries and generally makes the whole experience of automating Unreal Engine a lot more pleasant.
|
|
|
Dubzer/TgTranslator
Telegram bot that translates messages in groups
|
|
|
ncosentino/DevLeader
Projects referred to by my blog, Dev Leader
|
| Version | Downloads | Last Updated |
|---|---|---|
| 2.6.0 | 151,351 | 5/4/2026 |
| 2.5.4 | 1,835,697 | 6/28/2025 |
| 2.5.3 | 2,480,333 | 1/13/2025 |
| 2.5.2 | 3,580,635 | 9/15/2024 |
| 2.5.1 | 754,638 | 6/9/2024 |
| 2.5.0 | 96,925 | 5/9/2024 |
| 2.4.1 | 4,397,086 | 12/11/2023 |
| 2.4.0 | 13,997 | 11/24/2023 |
| 2.3.3 | 71,045 | 11/11/2023 |
| 2.3.2 | 222,131 | 10/25/2023 |
| 2.3.1 | 8,432 | 10/22/2023 |
| 2.3.0 | 36,924 | 10/6/2023 |
| 2.2.1 | 45,334 | 8/22/2023 |
| 2.2.0 | 232,654 | 4/29/2023 |
| 2.1.3 | 61,517 | 3/17/2023 |
| 2.1.2 | 16,415 | 3/11/2023 |
| 2.1.1 | 397,255 | 10/14/2022 |
| 2.1.0 | 70,283 | 9/11/2022 |
| 2.0.0 | 2,663,431 | 7/29/2022 |
| 1.1.0 | 22,663 | 7/1/2022 |