A generic interface for Key Value storage operations. Ideal for simple key-values that might migrate across in memory, SQL Server or NoSQL - a quick and easy way to create a KeyValue store.
By default, this library ships with an in-memory implementation. KeyValueInMemory
which implements the IKeyValueRepo
interface.
You should install the KeyValueRepo with NuGet:
Install-Package Calebs.KeyValueRepo
Or via the .NET Core command line interface:
dotnet add package Calebs.KeyValueRepo
Either command, from Package Manager Console or .NET Core CLI, will download and install Calebs.KeyValueRepo and all required dependencies.
- PRs should be against the
Develop
branch. - Merged PRs to
Develop
will trigger a[version]-ci-[buildnumber]
deployment to nuget, assuming all unit tests pass. - Merged PRs to
Main
will trigger a [version] deployment to nuget, assuming all of the tests pass.
The package version
is defined in the KeyValueRepo.csproj
file, using .NET SDK style structure. We follow semantic versioning
for this package.
- Get(string Id)
- GetAll()
- Update(string Id, T object)
- GetMeta(string Id)
- GetMetaAll()
- GetHistory(string Id)
- Remove(string Id)
- RemoveAll()
- Get(int Id) => Get(string Id)
- Update(int Id, T object) => Update(string Id, T object)
- Remove(int Id) => Remove(string Id)
- 0.1.0 - initial release (in Memory)
- 0.2.0 - added SqlLite Implementation
- ✔ SQLite Nuget Package
- ✔ Base (InMemory) Unit Test Nuget Package
- 0.3.0 - Added Meta Objects
- 0.4.0 - Completed SQLite Package with Meta Objects
- 0.5.0 - Added: Remove(id) and RemoveAll to IKeyValueRepo
- New Repo: Azure Tables Implementation
- New Repo: Sql Server Implementation
- New Repo: Azure CosmoDB Implementation