|
@ -269,7 +269,7 @@ There are separate Django management commands for each task: |
|
|
$ ./manage.py pruneusers |
|
|
$ ./manage.py pruneusers |
|
|
``` |
|
|
``` |
|
|
|
|
|
|
|
|
* Remove old records fromt he `api_tokenbucket` table. The TokenBucket |
|
|
|
|
|
|
|
|
* Remove old records from the `api_tokenbucket` table. The TokenBucket |
|
|
model is used for rate-limiting login attempts and similar operations. |
|
|
model is used for rate-limiting login attempts and similar operations. |
|
|
Any records older than one day can be safely removed. |
|
|
Any records older than one day can be safely removed. |
|
|
|
|
|
|
|
@ -277,6 +277,15 @@ There are separate Django management commands for each task: |
|
|
$ ./manage.py prunetokenbucket |
|
|
$ ./manage.py prunetokenbucket |
|
|
``` |
|
|
``` |
|
|
|
|
|
|
|
|
|
|
|
* Remove old records from the `api_flip` table. The Flip |
|
|
|
|
|
objects are used to track status changes of checks, and to calculate |
|
|
|
|
|
downtime statistics month by month. Flip objects from more than 3 months |
|
|
|
|
|
ago are not used and can be safely removed. |
|
|
|
|
|
|
|
|
|
|
|
``` |
|
|
|
|
|
$ ./manage.py pruneflips |
|
|
|
|
|
``` |
|
|
|
|
|
|
|
|
When you first try these commands on your data, it is a good idea to |
|
|
When you first try these commands on your data, it is a good idea to |
|
|
test them on a copy of your database, not on the live database right away. |
|
|
test them on a copy of your database, not on the live database right away. |
|
|
In a production setup, you should also have regular, automated database |
|
|
In a production setup, you should also have regular, automated database |
|
|