Mirror sync interval specified as duration string (#1407)
* Sync interval specifed as duration string * Changed mirror interval text * make fmt * Add MinInterval for mirror sync * Use duration internally * Changed min default to 10m * make fmt * Incorrect default * Removed defaults in MustDuration() * Add Mirror interval migration * Default values corrected * Use transaction during migration * Change http 500 to page with error message * Cleanup session.commit()
This commit is contained in:
parent
edbb9eefd6
commit
54f0293f0a
10 changed files with 90 additions and 21 deletions
6
conf/app.ini
vendored
6
conf/app.ini
vendored
|
@ -461,8 +461,10 @@ PULL = 300
|
|||
GC = 60
|
||||
|
||||
[mirror]
|
||||
; Default interval in hours between each check
|
||||
DEFAULT_INTERVAL = 8
|
||||
; Default interval as a duration between each check
|
||||
DEFAULT_INTERVAL = 8h
|
||||
; Min interval as a duration must be > 1m
|
||||
MIN_INTERVAL = 10m
|
||||
|
||||
[api]
|
||||
; Max number of items will response in a page
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue