Data storage service for other apps, using a variety of storage types:
-
db
- A local JSON file. -
gist
- A secret GitHub Gist file synchronized at regular intervals. -
mongo
- A local MongoDB process.
Data is stored on a per-app basis, so keys are unique within a given app.
-
npm ci && npm start
to createconfig.json
. -
Choose the storage type with
STORAGE_MODE
inconfig.json
. -
Configure that storage mode with the appropriate section of
config.json
. -
Start the service again to apply the new configuration.
This service provides the following conduit
topics and message formats:
Get a value by key for a given app.
Send: { app, key }
Receive: { app, key, value, timestamp }
Set a value by key for a given app.
Send: { app, key, value }
Receive: { content: 'OK' }
Increment a numeric value by key for a given app.
Send: { app, key }
Receive: { content: 'OK' }