bjornharrtell / PgKeyValueDB

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

PgKeyValueDB

Introduction

A simple as possible document database abstraction and implementation using PostgreSQL.

It uses POCO mapping to allow use of any C# instance that can be (de)serialized from/to a JSON object as a value.

Usage

It's recommended to use .NET Dependency Injection and setup via your Startup class like this:

services.AddPgKeyValueDB(connectionString);

You can then inject PgKeyValueDB as constructor parameter where you need it.

The PgKeyValueDB instance offers basic API to do Set, Get and Remove operations.

FAQ

What about distributed/concurrent usage?

Should be no different from standard PostgreSQL behaviour i.e https://www.postgresql.org/docs/current/transaction-iso.html. Note that default isolation level can be set in connection string with fx Options=-c default_transaction_isolation=serializable.

About

License:BSD 3-Clause "New" or "Revised" License


Languages

Language:C# 100.0%