Skip to content

Commit

Permalink
[common] Rename queue names
Browse files Browse the repository at this point in the history
This code renames the names of Arthur queues:
- create  --> initial_fetch_jobs
- update  --> incremental_fetch_jobs
- archive --> archive_jobs

Tests have been updated accordingly.

Signed-off-by: Valerio Cosentino <[email protected]>
  • Loading branch information
valeriocos committed Oct 22, 2019
1 parent 60b05a9 commit eeaae76
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
6 changes: 3 additions & 3 deletions arthur/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@

CH_PUBSUB = 'ch_arthur'

Q_ARCHIVE_JOBS = 'archive'
Q_CREATION_JOBS = 'create'
Q_UPDATING_JOBS = 'update'
Q_ARCHIVE_JOBS = 'archive_jobs'
Q_CREATION_JOBS = 'initial_fetch_jobs'
Q_UPDATING_JOBS = 'incremental_fetch_jobs'
Q_STORAGE_ITEMS = 'items'

TIMEOUT = 3600 * 24
Expand Down
3 changes: 2 additions & 1 deletion tests/test_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
import rq

from arthur.server import ArthurServer
from arthur.common import Q_CREATION_JOBS

from base import TestBaseRQ

Expand Down Expand Up @@ -372,7 +373,7 @@ def test_job(self, mock_utcnow):
self.assertEqual(job['job_id'], job_task_result['job_id'])
self.assertEqual(job['job_status'], 'finished')
self.assertEqual(job['timeout'], 86400)
self.assertEqual(job['origin'], 'create')
self.assertEqual(job['origin'], Q_CREATION_JOBS)
self.assertEqual(job['result'], job_task_result)
self.assertEqual(job['log'], mock_logs)

Expand Down

0 comments on commit eeaae76

Please sign in to comment.