https://github.com/mapikit/mongo-db-protocol
A DB-Protocol for using mongo with Meta-System
https://github.com/mapikit/mongo-db-protocol
Last synced: 5 months ago
JSON representation
A DB-Protocol for using mongo with Meta-System
- Host: GitHub
- URL: https://github.com/mapikit/mongo-db-protocol
- Owner: mapikit
- License: gpl-3.0
- Created: 2021-12-08T00:42:27.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2023-09-13T13:35:18.000Z (almost 3 years ago)
- Last Synced: 2024-03-02T16:36:52.735Z (over 2 years ago)
- Language: TypeScript
- Size: 958 KB
- Stars: 0
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Mongo-Db-Protocol
This is a DB Protocol for [Meta-System](https://mapikit.github.io/meta-system-docs/) to be used with MongoDB.
This file contains basic instructions and the base interface of the methods and operations inlcuded.
## How to use it
In your Meta-System configuration file you should add an object to the `protocols` array like the following:
```json
{
"protocols": [
{
"protocolType": "@meta-system/mongo-db-protocol",
"protocolVersion": "latest", // Should be the version you want to use
"configuration": {
"databaseName": "some-db-name", // The name of the DB you want to connect to
"dbConnectionString": "mongo://some-url-to-your-db" // URL connection - may contain user and password
}
}
]
}
```
## Interfaces
As any DB Protocol, the interface of the db operations (such as "insert", "find") can be whatever suits the protocol the best, even though it is recommended to follow the Meta-System query model. This protocol actually respects the full model, and is compatible with any schema and operation following the MSYS query model.
[**see the query model here**](https://mapikit.github.io/meta-system-docs/docs/api-docs/functions/schema-functions/queries)