MongoDB
We use a MongoDB to store the experiments and the recorded data of all participants. It is written to exclusively by the Database API - nothing else connects to it directly.
Collections, indexes and timestamps
The collections the API creates, the indexes it declares on startup, and the
difference between the client-side localTime and the server-assigned
serverTime are documented at
Data Model
in the backend documentation.
That distinction matters for analysis: serverTime is stamped when a
batched request arrives, so every sample in one batch shares it. Use
localTime for alignment within a client.
Installation
Docker
You can run a MongoDB instance using Docker. You should adapt all paths and logins to your needs.
- Customise the data according to your needs.
- Change the directories according to your system.
bindIp: 127.0.0.1 only accepts local connections
With this setting MongoDB is reachable only from the container itself, so an
API running elsewhere cannot connect. Widen it to the interface the API
reaches it on - and keep security.authorization enabled if you do.