Commit Graph
87 Commits
Author SHA1 Message Date
Ilan Steemers dfb1b03cd0 Experimenting with disque build on travis 2015-09-02 20:12:00 +02:00
Ilan Steemers b901039a44 Experimenting with disque build on travis 2015-09-02 20:08:20 +02:00
Ilan Steemers 1a61fa2821 Experimenting with disque build on travis 2015-09-02 20:04:48 +02:00
Ilan Steemers 0756fb9896 Experimenting with disque build on travis 2015-09-02 20:00:43 +02:00
Ilan Steemers 8ce441bed5 Adds more brokers
* added IronMQ
* added Aws SQS
* removed SafeRedis.
 During tests the 'safe' part wasn't consistent enough
2015-09-02 19:04:03 +02:00
Ilan Steemers 5171f1a183 Disabled Disque tests for now 2015-08-30 21:04:07 +02:00
Ilan Steemers 452f53f899 New container build on Travis 2015-08-30 20:57:05 +02:00
Ilan Steemers d6b9b10e3e Adds tests for brokers
* test for redis and django-redis
* test for disque

TODO add disque to Travis
2015-08-30 20:26:30 +02:00
Ilan Steemers 0740c90148 adds pluggable brokers
* added redis broker
 * added django_redis broker
 * added task acknowledgement
2015-08-29 18:54:07 +02:00
Ilan Steemers 439c8a2f77 Moves Status to it's own file
This way only qmonitor and qinfo need Curses and you can still run the cluster without it.
2015-08-26 13:11:58 +02:00
Ilan Steemers 3e92fddcdd #50 removes redis connection argument from pusher process 2015-08-24 10:08:43 +02:00
Ilan b99e16f108 adds catch_up configuration option
When a cluster hasn't run for a while, the default behavior is to keep executing schedules until they are caught up with the present time.
By setting `catch_up` to False, schedules will not play catch up and instead get rescheduled to the future.
2015-08-18 11:57:15 +02:00
Ilan 3d12c1d36e adds queue_size()
returns the size of the current redis queue
2015-08-13 15:54:57 +02:00
Ilan df7f8bbcaf Adds more stats to the qinfo command
* Average execution time
* Tasks per day/hour/minute/second
* Number of schedules
2015-08-12 12:39:14 +02:00
Ilan e86308b434 adds qinfo management command
It seems more practical to give this its own command instead of `qmonitor --info`
2015-08-10 13:20:17 +02:00
Ilan 63030aa9d1 Tests schedule creation via model 2015-08-10 13:18:50 +02:00
Ilan 79393dee16 adds --info summary to monitor command 2015-08-09 19:29:24 +02:00
Ilan de5d0f2725 Adds a 'minutes' option to the scheduler 2015-08-05 20:30:29 +02:00
Ilan f470fbf975 uses empty() instead of qsize() == 0 2015-08-04 18:30:07 +02:00
Ilan af61270f62 #40 qsize not implemented 2015-08-04 12:26:23 +02:00
Ilan 9899c42740 * fixes save_limit +1
* adds save_limit test
* expands recycle test
2015-07-31 18:39:54 +02:00
Ilan f8c9ef1bfa adds short delay in test
On some platforms the cluster is not always ready in time for test assertion
2015-07-23 14:57:00 +02:00
Ilan c5b8b800f6 Adds save override option for tasks
Also adds `q_options` dict for async and schedule options
2015-07-20 19:43:27 +02:00
Ilan 5fd436021f Expanding coverage 2015-07-20 12:17:12 +02:00
Ilan d7ecaee18d Added tests for failures filtering
fixed a bug
2015-07-19 15:21:06 +02:00
Ilan e75fbecda8 fixed typo and added group tests 2015-07-19 13:56:16 +02:00
Ilan e4737d765a Schedule name is optional
For backwards compatibility the schedule name is an optional keyword in the `schedule` function.

Adjusted docs accordingly
2015-07-18 19:41:21 +02:00
Ilan c127604f10 Adds task groups
* task now takes an optional keyword `group`
* added result_group()  and fetch_group()
* added group column to Success admin
* group column in searchable
* added `name` field to Schedules
* Scheduled tasks take schedule name as group
2015-07-18 17:20:50 +02:00
Ilan Steemers 05c8f3bc16 Merge pull request #20 from Koed00/dev
Tests now run with logging level debug
2015-07-17 05:28:59 -07:00
Ilan b876b1e06d Tests now run with logging level DEBUG 2015-07-17 14:17:40 +02:00
Ilan Steemers 1e7b3f6ce0 Merge pull request #18 from Koed00/dev
Adds a `timeout` override per task
2015-07-16 21:57:47 +02:00
Ilan af735c328e Adds a timeout override per task
* added a `timeout` keyword to tasks.
* timeouts now count down instead of up
* `timeout` in task overrides global timeout setting
* added tests for timeout override
* added a test for recycling
2015-07-16 20:35:29 +02:00
Ilan Steemers afda141ed1 Merge pull request #17 from Koed00/dev
Adds management commands to the tests
2015-07-16 18:22:10 +02:00
Ilan 0dbeccdfda Optparse needs named arguments in call_command 2015-07-16 16:11:32 +02:00
Ilan 5a3f875baa Added management commands to tests
* added --run-once option to the management commands for testing
2015-07-16 15:17:15 +02:00
Ilan 218b6a9795 removed unused import 2015-07-16 14:36:36 +02:00
Ilan 6826e75a37 docs: Added a report example
Also added  a test based on the example.
2015-07-16 14:03:07 +02:00
Ilan a5580c75a1 Workaround for Travis
Travis doesn't support cpu affinity in their virtuals so I've added a setting TESTING that will bypass the actual affinity setting, but will still cover most of the code.
Might be useful for future workarounds.
2015-07-15 22:17:13 +02:00
Ilan 1f28bf1c68 Travis doesn't like cpu affinity. I'm guessing 2015-07-15 20:15:46 +02:00
Ilan 2d0820e80b Adds cpu affinity for the workers. Courtesy of the optional psutil module. 2015-07-15 19:53:13 +02:00
Ilan e5708a1ab2 Clean up redis after test 2015-07-15 12:45:11 +02:00
Ilan Steemers 6c9dd1a910 Schedules of type ONCE will now self destruct with negative repeats or just deactivated with positive repeats 2015-07-11 11:32:46 +02:00
Ilan Steemers e62fd1ee70 Fixes #7
* added a synchronous cluster simulation

* added a test for the sync function

* moved signing into its own module

* refactored imports to solve circular import problems stemming from the task module pretending to be a cluster

* added documentation for the new sync option
2015-07-09 20:16:21 +02:00
Ilan Steemers 0413a2e65a refresh_from_db is 1.8 only 2015-07-08 21:06:32 +02:00
Ilan Steemers 0a8196838a Removed security middleware from test for Django 1.7 2015-07-08 21:02:00 +02:00
Ilan Steemers f29fdee5ad Fixes import error 2015-07-08 13:43:46 +02:00
Ilan Steemers f8708cfd73 Task now uses a UUID4 instead of a LUID 2015-07-08 13:33:03 +02:00
Ilan Steemers 729abaf726 set exit timeout if no timeout is given 2015-07-07 20:37:03 +02:00
Ilan Steemers 4ee47fc38f upping the coverage 2015-07-07 20:20:28 +02:00
Ilan Steemers d06aa40a38 Removed Cluster.is_idle
It wasn't used and it could be confused with the cluster stat IDLE
2015-07-06 11:13:54 +02:00