Add recorder vars db_max_retries and db_retry_wait (#12023)

* added documentation for recorder component

Added db_max_retries and db_retry_wait variables to docs

* added default values to vars and edited database setup section.

* readded recorder details line i mistakenly removed

* changed int to integer
This commit is contained in:
Jonathan Østrup 2020-02-11 11:51:59 +01:00 committed by GitHub
parent 31a8f12391
commit a4a74552c2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -31,6 +31,16 @@ recorder:
description: The URL that points to your database.
required: false
type: string
db_max_retries:
description: The max amount of times, the recorder retries to connect to the database.
required: false
default: 10
type: integer
db_retry_wait:
description: The time in seconds, that the recorder sleeps when trying to connect to the database.
required: false
default: 3
type: integer
purge_keep_days:
description: Specify the number of history days to keep in recorder database after a purge.
required: false
@ -180,6 +190,7 @@ If you are using the default `FULL` recovery model for MS SQL Server you will ne
### Database startup
If you are running a database server instance on the same server as Home Assistant then you must ensure that this service starts before Home Assistant. For a Linux instance running Systemd (Raspberry Pi, Debian, Ubuntu and others) then you should edit the service file.
To help facilitate this, db_max_retry and db_retry_wait variables have been added to ensure the recorder retries the connection to your database enough times, for your database to start up.
```bash
sudo nano /etc/systemd/system/home-assistant@homeassistant.service