server/docs/kv_db_arch.md

30 lines
794 B
Markdown
Raw Permalink Normal View History

2024-02-25 22:28:18 +04:00
# Архитектура KV DB (Dragonfly)
- `apikey_{apikey}`
- API ключ для приложений
2024-02-25 22:28:18 +04:00
- Поля
- `owner`
- Имеет TTL
- `devices_{device_uuid}`
2024-02-25 22:28:18 +04:00
- Поля
- `exists`: bool
- `tls_only`: bool
- `mtls_only`: bool
- `lat`: decimal
- `long`: decimal
- `alt`: decimal
- `devices_{device_uuid}_sensor{sensor_mac}_{tai_timestamp}`
- Только значение
- `devices_{device_uuid}_{sensor_mac}`
- Поля
- `unit`: str
- `devices_{device_uuid}_commands`
- `devices_mac{device_mac}`
- Маппинг до device_uuid
- `users_{user_uuid}`
- username: string
- password_hash: string
2024-05-31 16:50:58 +04:00
!!!! Убедитесь что в переменных ключей нет `_` !!!!