Commit Graph

1455 Commits (4d450ec94d4c09f28723af20aa1ca88bc109738a)
 

Author SHA1 Message Date
zhangliyong 21c14c0e21 Cleanup
zhangliyong 4d91f136f8 Move redis url default value to connect function
So worker subcommand can retrieve redis url from config file if url
option value is None, otherwise url option value will never be None.
zhangliyong 4df076f3aa Retrieve url from config file
zhangliyong 229a00fee5 Cleanup
zhangliyong 88fe5124d8 Make pythonic
zhangliyong 907e71dc86 Make pythonic
zhangliyong f10c749b7c Use click's evvar to retrieve SENTRY_DSN environment value
zhangliyong 842f27294a Convert rqworker to 'rq worker' subcommand
zhangliyong 7b434a32eb Let cleanup_ghosts accept conn argument
Selwin Ong 202be75b21 Merge pull request from foxx/feature/custom-job-ids
Allow job ID to be set on enqueue/enqueue_call() - fixes 
Selwin Ong c1dc30eae3 Added __len__ method to Queue.
Selwin Ong fae7df5aa7 Renamed StartedJobRegistry.get_job_count to StartedJobRegistry.count for consistency.
Selwin Ong 41ae1ce8a7 Added a registry.get_job_count().
Cal Leeming 6aa2e18f88 Another unused import, oops
foxx 30ea76ddd6 Fixed silly typo
foxx 0466562a13 Fixes from comments in
Added tox/vagrant tmp dir to gitignore
Removed unused import
Renamed id to job_id in enqueue_call() as per comments in 
Vincent Driessen 783b6f9ec7 Fix PEP8 complaint.
Vincent Driessen 7686785d61 Merge branch 'selwin-working-queue'
Conflicts:
	tests/test_worker.py
Vincent Driessen 4b7c59d68d Fix PEP8 complaints.
Vincent Driessen aa3cf85531 Run flake8 checks as part of test suite.
Selwin Ong 6d79082b62 Call move_expired_jobs_to_failed_queue before returning job_ids.
Selwin Ong dc12f8aee5 Fixed random registry failures when run on slower machines.
Selwin Ong 5a27ad540f Merge branch 'working-queue' of https://github.com/selwin/rq into working-queue
Conflicts:
	tests/test_worker.py
Selwin Ong 9341a4a33d Renamed WorkingQueue to StartedJobRegistry.
Selwin Ong 2e96148b31 Fixed Python 3 tests for "WorkingQueue".
Selwin Ong 60c7a3cc6e working_queue.remove call should be pipelined.
Selwin Ong 4d90cc062e Add job to WorkingQueue before execution and remove from WorkingQueue after.
Selwin Ong b0c0a84ab0 Moved some logic into worker.prepare_job_execution to make things testable.
Selwin Ong a28575088b Implemented WorkingQueue.cleanup().
Selwin Ong 3dc008d090 Added WorkingQueue class.
Selwin Ong 1047db0b3a Renamed WorkingQueue to StartedJobRegistry.
Selwin Ong 1158a0606c Fixed Python 3 tests for "WorkingQueue".
foxx b6499ce71c Fixed another py3 bug - my bad. Also moved type checking further down
Vincent Driessen 85badaf4a0 Indicate required Redis version in README.
foxx f5779c194f Renamed job_id to id, and fixed py3 bug, per
Vincent Driessen 9ab46804c6 Merge pull request from foxx/feature/testworker
Added test worker for unit tests - fixes 
foxx 52c3ad0fbf Renamed to SimpleWorker
foxx 23cae3a420 Fixed bug caused by broken merge, my bad
foxx 16ee71f26d Use class for test worker, and performs PID check in unit tests,
Selwin Ong d667fb0713 working_queue.remove call should be pipelined.
Vincent Driessen dab8373311 Fix all tests.
Vincent Driessen c860beb4d5 Fix broken imports.
Vincent Driessen b5fbc3992b Restructure new CLI modules.
A few things have changed.  First of all, there is no separate copy of
the argparse-based `rqinfo` anymore.  It now fully utilizes the new
Click subcommand.  In other words: `rqinfo` and `rq info` both invoke
the same function under the hood.

In order to support this, the main command group now does NOT take
a `url` option and initializes the connection.  Besides supporting this
alias pattern, this change was useful for two more reasons: (1) it
allows us to add subcommands that don't need the Redis server running in
the future, and (2) it makes the `--url` option an option underneath
each subcommand.  This avoids command invocations that look like this:

    $ rq --url <url> info --more --flags

And instead allows us to pass the URL to each subcommand where it's
deemed necessary:

    $ rq info --url <url> --more --flags

Which is much friendlier to use/remember.
Vincent Driessen 652cd71d2b Merge branch 'zhangliyong-cli-rq'
Vincent Driessen 5c96c61255 Change `rq requeue` subtly, mostly docs and vars.
Vincent Driessen 07dda74710 Change options of the `rq empty` command.
* Does not ask confirmation
* Does not need `--yes` option anymore
* Added --all, to clear all queues
* No implicit emptying of the failed queue.  If you want to empty the
  failed queue, just use `$ rq empty failed`
Vincent Driessen 8f1e066f15 Various little style fixes.
Vincent Driessen fc803f5d0d Fix various flake8 complaints.
foxx 2753f17e8e Fixed bug with format() in py3
foxx 72bc9e37b7 Forced job_id to only allow str/unicode