backend rework- full test 1
This commit is contained in:
20
db/README.md
Normal file
20
db/README.md
Normal file
@@ -0,0 +1,20 @@
|
||||
# COMMANDS DB description
|
||||
|
||||
## one command contains:
|
||||
- command
|
||||
- status
|
||||
- command_id
|
||||
- tstamp
|
||||
|
||||
### command may contain one out of following strings:
|
||||
```["toggle_machine","","","","","",""]```
|
||||
|
||||
### status may contain one out of following strings:
|
||||
```["pending","failed","served","rejected"]```
|
||||
|
||||
### command_id is a random generated 4 chars long integer to identify the exact command between Server frontend Database and ESP
|
||||
|
||||
### tstamp is the exact Date at the first ever creation of the db entry and does not say anything about completion or rejection.
|
||||
|
||||
## NOTE:
|
||||
### A created command is marked as failed after 5 minutes if its status is still pending, to ensure that no processes continue after a communication failure in the chain.
|
||||
BIN
db/commands.db
BIN
db/commands.db
Binary file not shown.
@@ -1,3 +1,6 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Dieses Skript erstellt eine SQLite-Datenbank mit einer Tabelle für Befehle.
|
||||
|
||||
import os
|
||||
import sqlite3
|
||||
|
||||
|
||||
Reference in New Issue
Block a user