Skip to content

IntBasis/IntBasis.DocumentOriented

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

IntBasis.DocumentOriented

Don't know which Document DB to use? This project provides a simple abstraction for Document DB storage, retrieval and observation. You can easily switch providers in service configuration.

Packages

  • MongoDB
    services.AddDocumentOrientedMongoDb(config)
  • RavenDB
    services.AddDocumentOrientedRavenDb(config)
  • LiteDB (coming soon)
    services.AddDocumentOrientedLiteDb(config)
Key Services
IDocumentChanges Provides a way to subscribe to notifications of changes to Document Entities
IDocumentQuery Responsible for encapsulating querying the Document Database
IDocumentStorage Encapsulates the simple storage and retrieval of individual document entities by Id.

Building and Running

Notes on working with this Repo and running the local Document DB servers required for tests.

Dev Environment (Windows)

Installation requires an elevated Administrator shell

Install Chocolatey

# RavenDB
choco install ravendb 
# MongoDB
choco install mongodb
# MongoDB Compass Database Explorer (optional)
choco install mongodb-compass

Running DB Servers

RavenDB (Windows Only)

C:\RavenDB\run.ps1

MongoDB config is available in the source root which configures MongoDB to use local .MongoDB folder.

mongod --config ./mongod.cfg

Cleanly shutting down MongoDB

Windows
cd 'C:\Program Files\MongoDB\Server\5.3\bin'
./mongo
macOS
mongosh

MongoDB shell

use admin
db.shutdownServer()
quit()

To Do