Changeset View
Changeset View
Standalone View
Standalone View
swh/lister/npm/__init__.py
# Copyright (C) 2019 the Software Heritage developers | # Copyright (C) 2019 the Software Heritage developers | ||||
# License: GNU General Public License version 3, or any later version | # License: GNU General Public License version 3, or any later version | ||||
# See top-level LICENSE file for more information | # See top-level LICENSE file for more information | ||||
def register(): | def register(): | ||||
from .models import NpmVisitModel, NpmModel | from .models import NpmVisitModel, NpmModel | ||||
from .lister import NpmLister | from .lister import NpmLister | ||||
return {'models': [NpmVisitModel, NpmModel], | return {'models': [NpmVisitModel, NpmModel], | ||||
'lister': NpmLister, | 'lister': NpmLister, | ||||
'task_modules': ['%s.tasks' % __name__], | 'task_modules': ['%s.tasks' % __name__], | ||||
'task_types': { | |||||
'list-npm-full': { | |||||
'default_interval': '7 days', | |||||
'min_interval': '7 days', | |||||
'max_interval': '7 days', | |||||
}, | |||||
vlorentz: why a specific value for npm?
There should be at least a comment about this. | |||||
Not Done Inline ActionsProbably because that matches the current production setup. type | description | backend_name | default_interval | min_interval | max_interval | backoff_factor | max_queue_length$ -----------------------------------+--------------------------------------------------------------+-------------------------------------------------------+------------------+--------------+--------------+----------------+-----------------$ list-npm-full | Full npm lister | swh.lister.npm.tasks.NpmListerTask | 7 days | 7 days | 7 days | 1 | $ ardumont: Probably because that matches the current production setup.
```
type… | |||||
Not Done Inline ActionsAnd why was it done in production? vlorentz: And why was it done in production? | |||||
Not Done Inline ActionsI don't really know (i must have kept the existing ones which we now find somehow consistently in the scheduling db). Same goes for the existing other setup, why 90 (list-full), 64 (loaders), 1 (list-incremental) day(s)? ardumont: I don't really know (i must have kept the existing ones which we now find somehow consistently… | |||||
Done Inline Actions
yep! douardda: > Probably because that matches the current production setup.
yep!
| |||||
}, | |||||
} | } |
why a specific value for npm?
There should be at least a comment about this.