tasque 0.0.3 → 0.0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/Gemfile.lock +68 -0
- data/README.md +15 -0
- data/db/test.db +0 -0
- data/insque.local.yml +10 -0
- data/lib/tasque.rb +1 -0
- data/lib/tasque/configuration.rb +2 -0
- data/lib/tasque/processor.rb +8 -2
- data/lib/tasque/task.rb +2 -2
- data/lib/tasque/task_cancel.rb +10 -0
- data/lib/tasque/version.rb +1 -1
- data/spec/spec_helper.rb +100 -0
- data/spec/tasque_spec.rb +156 -0
- data/tasque.gemspec +4 -0
- metadata +68 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 49877f4056f63093fc82edb1ff458450fbadbc6113e149d083a503b9dbf9fdb6
|
4
|
+
data.tar.gz: 5fd3def76f080fa3753df861b8ba18ef487c9acee86452677b6d95260e151c94
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a197f5b667afec439400a53e1620dbba5379b79f780cca10d7dfe80837b0847c224277f4b0b15426ad8df5fd50d1b963ebb2b0d9d8ac8322502b0ce27f090593
|
7
|
+
data.tar.gz: 3a4838dd99a0186ead764d6b1bd401b97072fbd81a4d077e86de8e54c3120c7bd03101ddaea0bbfc93159fe3d7cc307da1a67f867926822c760e2c3b233686f2
|
data/Gemfile.lock
ADDED
@@ -0,0 +1,68 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
tasque (0.0.3)
|
5
|
+
activerecord
|
6
|
+
json
|
7
|
+
state_machine
|
8
|
+
timers
|
9
|
+
|
10
|
+
GEM
|
11
|
+
remote: https://rubygems.org/
|
12
|
+
specs:
|
13
|
+
activemodel (5.1.5)
|
14
|
+
activesupport (= 5.1.5)
|
15
|
+
activerecord (5.1.5)
|
16
|
+
activemodel (= 5.1.5)
|
17
|
+
activesupport (= 5.1.5)
|
18
|
+
arel (~> 8.0)
|
19
|
+
activesupport (5.1.5)
|
20
|
+
concurrent-ruby (~> 1.0, >= 1.0.2)
|
21
|
+
i18n (~> 0.7)
|
22
|
+
minitest (~> 5.1)
|
23
|
+
tzinfo (~> 1.1)
|
24
|
+
arel (8.0.0)
|
25
|
+
concurrent-ruby (1.0.5)
|
26
|
+
diff-lcs (1.3)
|
27
|
+
hitimes (1.2.6)
|
28
|
+
i18n (0.9.5)
|
29
|
+
concurrent-ruby (~> 1.0)
|
30
|
+
insque (0.6.3)
|
31
|
+
json (> 2)
|
32
|
+
redis (> 2)
|
33
|
+
json (2.1.0)
|
34
|
+
minitest (5.11.3)
|
35
|
+
redis (4.0.1)
|
36
|
+
rspec (3.7.0)
|
37
|
+
rspec-core (~> 3.7.0)
|
38
|
+
rspec-expectations (~> 3.7.0)
|
39
|
+
rspec-mocks (~> 3.7.0)
|
40
|
+
rspec-core (3.7.1)
|
41
|
+
rspec-support (~> 3.7.0)
|
42
|
+
rspec-expectations (3.7.0)
|
43
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
44
|
+
rspec-support (~> 3.7.0)
|
45
|
+
rspec-mocks (3.7.0)
|
46
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
47
|
+
rspec-support (~> 3.7.0)
|
48
|
+
rspec-support (3.7.1)
|
49
|
+
sqlite3 (1.3.13)
|
50
|
+
state_machine (1.2.0)
|
51
|
+
thread_safe (0.3.6)
|
52
|
+
timers (4.1.2)
|
53
|
+
hitimes
|
54
|
+
tzinfo (1.2.5)
|
55
|
+
thread_safe (~> 0.1)
|
56
|
+
|
57
|
+
PLATFORMS
|
58
|
+
ruby
|
59
|
+
|
60
|
+
DEPENDENCIES
|
61
|
+
activesupport
|
62
|
+
insque
|
63
|
+
rspec
|
64
|
+
sqlite3
|
65
|
+
tasque!
|
66
|
+
|
67
|
+
BUNDLED WITH
|
68
|
+
1.12.5
|
data/README.md
CHANGED
@@ -48,12 +48,27 @@ Now to process the task:
|
|
48
48
|
# register a handler for test tasks
|
49
49
|
processor.add_handler('test') do |task|
|
50
50
|
puts "Got task ##{task.id}. Task says: '#{task.params['text']}'"
|
51
|
+
task.complete!
|
51
52
|
{ log: 'got task, printed text' } # returning task result
|
52
53
|
end
|
53
54
|
|
54
55
|
# start processor and wait
|
55
56
|
processor.start
|
56
57
|
|
58
|
+
|
59
|
+
### Using with Insque
|
60
|
+
|
61
|
+
Tasque can send task and worker state updates via [Insque](https://github.com/Gropher/insque).
|
62
|
+
|
63
|
+
To enable this featute uncomment following lines in your tasque initializer:
|
64
|
+
|
65
|
+
# Send task state updates and progress notifications via Insque
|
66
|
+
config.notify = true
|
67
|
+
|
68
|
+
# Send worker heartbeat via Insque
|
69
|
+
config.heartbeat = true
|
70
|
+
config.heartbeat_interval = 10 # seconds
|
71
|
+
|
57
72
|
|
58
73
|
## Contributing
|
59
74
|
|
data/db/test.db
ADDED
Binary file
|
data/insque.local.yml
ADDED
data/lib/tasque.rb
CHANGED
data/lib/tasque/configuration.rb
CHANGED
@@ -41,6 +41,7 @@ module Tasque
|
|
41
41
|
attr_accessor :worker
|
42
42
|
attr_accessor :heartbeat
|
43
43
|
attr_accessor :heartbeat_interval
|
44
|
+
attr_accessor :heartbeat_payload
|
44
45
|
attr_accessor :notify
|
45
46
|
|
46
47
|
def initialize
|
@@ -51,6 +52,7 @@ module Tasque
|
|
51
52
|
self.progress_interval = 5 # seconds
|
52
53
|
self.heartbeat = false
|
53
54
|
self.heartbeat_interval = 10 # seconds
|
55
|
+
self.heartbeat_payload = {}
|
54
56
|
self.notify = false
|
55
57
|
end
|
56
58
|
|
data/lib/tasque/processor.rb
CHANGED
@@ -17,17 +17,21 @@ module Tasque
|
|
17
17
|
task.process
|
18
18
|
begin
|
19
19
|
task.result = block.call task
|
20
|
+
task.complete
|
21
|
+
rescue Tasque::TaskCancel => e
|
22
|
+
task.cancel
|
20
23
|
rescue Tasque::TaskError => e
|
21
24
|
task.error = {
|
22
25
|
task_error: e.task_error
|
23
26
|
}
|
27
|
+
task.failure
|
24
28
|
rescue Exception => e
|
25
29
|
task.error = {
|
26
30
|
exception: e.message,
|
27
31
|
backtrace: e.backtrace
|
28
32
|
}
|
33
|
+
task.failure
|
29
34
|
end
|
30
|
-
task.error? ? task.failure : task.complete
|
31
35
|
@current_task = nil
|
32
36
|
end
|
33
37
|
@timers.every(check_interval) do
|
@@ -35,6 +39,8 @@ module Tasque
|
|
35
39
|
has_task = Tasque::Task.fetch(type) do |task|
|
36
40
|
@handlers[type.to_sym].call(task)
|
37
41
|
end
|
42
|
+
rescue ActiveRecord::Deadlocked
|
43
|
+
retry
|
38
44
|
end while has_task
|
39
45
|
end
|
40
46
|
end
|
@@ -59,7 +65,7 @@ module Tasque
|
|
59
65
|
message = {
|
60
66
|
worker: Tasque.config.worker,
|
61
67
|
busy: !@current_job.nil?
|
62
|
-
}
|
68
|
+
}.merge(Tasque.config.heartbeat_payload)
|
63
69
|
Insque.broadcast :heartbeat, message
|
64
70
|
end
|
65
71
|
loop do
|
data/lib/tasque/task.rb
CHANGED
@@ -11,7 +11,7 @@ module Tasque
|
|
11
11
|
serialize :params, JSON
|
12
12
|
serialize :result, JSON
|
13
13
|
|
14
|
-
scope :with_task, ->(task) { where(task: task).order priority: :desc }
|
14
|
+
scope :with_task, ->(task) { where(task: task).order priority: :desc, created_at: :asc }
|
15
15
|
scope :minimum_priority, ->(priority) { priority.nil? ? nil : where('priority >= ?', priority) }
|
16
16
|
scope :to_process, -> { where status: %w(new reprocessed) }
|
17
17
|
scope :with_error, -> { where status: 'error' }
|
@@ -98,7 +98,7 @@ module Tasque
|
|
98
98
|
end
|
99
99
|
|
100
100
|
event :cancel do
|
101
|
-
transition any
|
101
|
+
transition any => :canceled
|
102
102
|
end
|
103
103
|
|
104
104
|
|
data/lib/tasque/version.rb
CHANGED
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,100 @@
|
|
1
|
+
# This file was generated by the `rspec --init` command. Conventionally, all
|
2
|
+
# specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
|
3
|
+
# The generated `.rspec` file contains `--require spec_helper` which will cause
|
4
|
+
# this file to always be loaded, without a need to explicitly require it in any
|
5
|
+
# files.
|
6
|
+
#
|
7
|
+
# Given that it is always loaded, you are encouraged to keep this file as
|
8
|
+
# light-weight as possible. Requiring heavyweight dependencies from this file
|
9
|
+
# will add to the boot time of your test suite on EVERY test run, even for an
|
10
|
+
# individual file that may not need all of that loaded. Instead, consider making
|
11
|
+
# a separate helper file that requires the additional dependencies and performs
|
12
|
+
# the additional setup, and require it from the spec files that actually need
|
13
|
+
# it.
|
14
|
+
#
|
15
|
+
# See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
|
16
|
+
RSpec.configure do |config|
|
17
|
+
# rspec-expectations config goes here. You can use an alternate
|
18
|
+
# assertion/expectation library such as wrong or the stdlib/minitest
|
19
|
+
# assertions if you prefer.
|
20
|
+
config.expect_with :rspec do |expectations|
|
21
|
+
# This option will default to `true` in RSpec 4. It makes the `description`
|
22
|
+
# and `failure_message` of custom matchers include text for helper methods
|
23
|
+
# defined using `chain`, e.g.:
|
24
|
+
# be_bigger_than(2).and_smaller_than(4).description
|
25
|
+
# # => "be bigger than 2 and smaller than 4"
|
26
|
+
# ...rather than:
|
27
|
+
# # => "be bigger than 2"
|
28
|
+
expectations.include_chain_clauses_in_custom_matcher_descriptions = true
|
29
|
+
end
|
30
|
+
|
31
|
+
# rspec-mocks config goes here. You can use an alternate test double
|
32
|
+
# library (such as bogus or mocha) by changing the `mock_with` option here.
|
33
|
+
config.mock_with :rspec do |mocks|
|
34
|
+
# Prevents you from mocking or stubbing a method that does not exist on
|
35
|
+
# a real object. This is generally recommended, and will default to
|
36
|
+
# `true` in RSpec 4.
|
37
|
+
mocks.verify_partial_doubles = true
|
38
|
+
end
|
39
|
+
|
40
|
+
# This option will default to `:apply_to_host_groups` in RSpec 4 (and will
|
41
|
+
# have no way to turn it off -- the option exists only for backwards
|
42
|
+
# compatibility in RSpec 3). It causes shared context metadata to be
|
43
|
+
# inherited by the metadata hash of host groups and examples, rather than
|
44
|
+
# triggering implicit auto-inclusion in groups with matching metadata.
|
45
|
+
config.shared_context_metadata_behavior = :apply_to_host_groups
|
46
|
+
|
47
|
+
# The settings below are suggested to provide a good initial experience
|
48
|
+
# with RSpec, but feel free to customize to your heart's content.
|
49
|
+
=begin
|
50
|
+
# This allows you to limit a spec run to individual examples or groups
|
51
|
+
# you care about by tagging them with `:focus` metadata. When nothing
|
52
|
+
# is tagged with `:focus`, all examples get run. RSpec also provides
|
53
|
+
# aliases for `it`, `describe`, and `context` that include `:focus`
|
54
|
+
# metadata: `fit`, `fdescribe` and `fcontext`, respectively.
|
55
|
+
config.filter_run_when_matching :focus
|
56
|
+
|
57
|
+
# Allows RSpec to persist some state between runs in order to support
|
58
|
+
# the `--only-failures` and `--next-failure` CLI options. We recommend
|
59
|
+
# you configure your source control system to ignore this file.
|
60
|
+
config.example_status_persistence_file_path = "spec/examples.txt"
|
61
|
+
|
62
|
+
# Limits the available syntax to the non-monkey patched syntax that is
|
63
|
+
# recommended. For more details, see:
|
64
|
+
# - http://rspec.info/blog/2012/06/rspecs-new-expectation-syntax/
|
65
|
+
# - http://www.teaisaweso.me/blog/2013/05/27/rspecs-new-message-expectation-syntax/
|
66
|
+
# - http://rspec.info/blog/2014/05/notable-changes-in-rspec-3/#zero-monkey-patching-mode
|
67
|
+
config.disable_monkey_patching!
|
68
|
+
|
69
|
+
# This setting enables warnings. It's recommended, but in some cases may
|
70
|
+
# be too noisy due to issues in dependencies.
|
71
|
+
config.warnings = true
|
72
|
+
|
73
|
+
# Many RSpec users commonly either run the entire suite or an individual
|
74
|
+
# file, and it's useful to allow more verbose output when running an
|
75
|
+
# individual spec file.
|
76
|
+
if config.files_to_run.one?
|
77
|
+
# Use the documentation formatter for detailed output,
|
78
|
+
# unless a formatter has already been configured
|
79
|
+
# (e.g. via a command-line flag).
|
80
|
+
config.default_formatter = "doc"
|
81
|
+
end
|
82
|
+
|
83
|
+
# Print the 10 slowest examples and example groups at the
|
84
|
+
# end of the spec run, to help surface which specs are running
|
85
|
+
# particularly slow.
|
86
|
+
config.profile_examples = 10
|
87
|
+
|
88
|
+
# Run specs in random order to surface order dependencies. If you find an
|
89
|
+
# order dependency and want to debug it, you can fix the order by providing
|
90
|
+
# the seed, which is printed after each run.
|
91
|
+
# --seed 1234
|
92
|
+
config.order = :random
|
93
|
+
|
94
|
+
# Seed global randomization in this process using the `--seed` CLI option.
|
95
|
+
# Setting this allows you to use `--seed` to deterministically reproduce
|
96
|
+
# test failures related to randomization by passing the same `--seed` value
|
97
|
+
# as the one that triggered the failure.
|
98
|
+
Kernel.srand config.seed
|
99
|
+
=end
|
100
|
+
end
|
data/spec/tasque_spec.rb
ADDED
@@ -0,0 +1,156 @@
|
|
1
|
+
require 'json'
|
2
|
+
require 'active_support/all'
|
3
|
+
require 'active_record'
|
4
|
+
require 'tasque'
|
5
|
+
require 'insque'
|
6
|
+
|
7
|
+
RSpec.describe 'tasque' do
|
8
|
+
before(:all) do
|
9
|
+
system "docker swarm init || true"
|
10
|
+
system "docker stack deploy -c insque.local.yml insque"
|
11
|
+
sleep 10
|
12
|
+
Insque.debug = false
|
13
|
+
Insque.sender = 'myapp'
|
14
|
+
Insque.redis_config = { host: 'localhost', port: 63790 }
|
15
|
+
Thread.abort_on_exception=true
|
16
|
+
ActiveRecord::Base.establish_connection(
|
17
|
+
:adapter => 'sqlite3',
|
18
|
+
:database => 'db/test.db'
|
19
|
+
)
|
20
|
+
ActiveRecord::Base.connection.execute('create table tasque_tasks(id INTEGER PRIMARY KEY AUTOINCREMENT, tag TEXT, task TEXT, params TEXT, result TEXT, worker TEXT, status TEXT DEFAULT "new", attempts INTEGER DEFAULT 0, progress INTEGER DEFAULT 0, priority INTEGER DEFAULT 0, started_at DATETIME, finished_at DATETIME, updated_at DATETIME, created_at DATETIME);')
|
21
|
+
end
|
22
|
+
|
23
|
+
after(:all) do
|
24
|
+
system "docker stack rm insque"
|
25
|
+
ActiveRecord::Base.connection.execute('drop table tasque_tasks;')
|
26
|
+
end
|
27
|
+
|
28
|
+
before(:each) do
|
29
|
+
Insque.redis.flushall
|
30
|
+
Tasque::Task.delete_all
|
31
|
+
Tasque.configure do |config|
|
32
|
+
config.worker = 'myworker'
|
33
|
+
config.check_interval = 1 # seconds
|
34
|
+
config.progress_interval = 1 # seconds
|
35
|
+
config.minimum_priority = nil
|
36
|
+
config.notify = false
|
37
|
+
config.heartbeat = false
|
38
|
+
config.heartbeat_interval = 1
|
39
|
+
end
|
40
|
+
end
|
41
|
+
|
42
|
+
it 'creates a task' do
|
43
|
+
Tasque::Task.create! task: 'test', params: { text: 'This is the test!' }
|
44
|
+
expect(Tasque::Task.count).to eq(1)
|
45
|
+
end
|
46
|
+
|
47
|
+
it 'processes a task' do
|
48
|
+
task = Tasque::Task.create! task: 'test', params: { text: 'This is the test!' }
|
49
|
+
processor_thread = Thread.new do
|
50
|
+
processor = Tasque::Processor.new
|
51
|
+
processor.add_handler('test') do |t|
|
52
|
+
t.complete!
|
53
|
+
{ log: 'completed task' }
|
54
|
+
end
|
55
|
+
processor.start
|
56
|
+
end
|
57
|
+
sleep 2
|
58
|
+
processor_thread.exit
|
59
|
+
task.reload
|
60
|
+
expect(task.status).to eq('complete')
|
61
|
+
expect(task.progress).to eq(100)
|
62
|
+
end
|
63
|
+
|
64
|
+
it 'uses minimum priority' do
|
65
|
+
Tasque.config.minimum_priority = 10
|
66
|
+
task1 = Tasque::Task.create! task: 'test', priority: 1, params: { text: 'This is low priority!' }
|
67
|
+
task2 = Tasque::Task.create! task: 'test', priority: 100, params: { text: 'This is high priority!' }
|
68
|
+
processor_thread = Thread.new do
|
69
|
+
processor = Tasque::Processor.new
|
70
|
+
processor.add_handler('test') do |t|
|
71
|
+
t.complete!
|
72
|
+
{ log: 'completed task' }
|
73
|
+
end
|
74
|
+
processor.start
|
75
|
+
end
|
76
|
+
sleep 2
|
77
|
+
processor_thread.exit
|
78
|
+
task1.reload
|
79
|
+
task2.reload
|
80
|
+
expect(task1.status).to eq('new')
|
81
|
+
expect(task2.status).to eq('complete')
|
82
|
+
end
|
83
|
+
|
84
|
+
it 'reports progress' do
|
85
|
+
task = Tasque::Task.create! task: 'test', params: { text: 'This is the test!' }
|
86
|
+
processor_thread = Thread.new do
|
87
|
+
processor = Tasque::Processor.new
|
88
|
+
processor.add_handler('test') do |t|
|
89
|
+
t.progress! 50
|
90
|
+
sleep 2
|
91
|
+
t.complete!
|
92
|
+
{ log: 'completed task' }
|
93
|
+
end
|
94
|
+
processor.start
|
95
|
+
end
|
96
|
+
sleep 2
|
97
|
+
task.reload
|
98
|
+
expect(task.status).to eq('processing')
|
99
|
+
expect(task.progress).to eq(50)
|
100
|
+
sleep 2
|
101
|
+
processor_thread.exit
|
102
|
+
task.reload
|
103
|
+
expect(task.status).to eq('complete')
|
104
|
+
expect(task.progress).to eq(100)
|
105
|
+
end
|
106
|
+
|
107
|
+
it 'reports errors' do
|
108
|
+
task = Tasque::Task.create! task: 'test', params: { text: 'This is the test!' }
|
109
|
+
processor_thread = Thread.new do
|
110
|
+
processor = Tasque::Processor.new
|
111
|
+
processor.add_handler('test') do |t|
|
112
|
+
raise 'Test Exception'
|
113
|
+
{ log: 'completed task' }
|
114
|
+
end
|
115
|
+
processor.start
|
116
|
+
end
|
117
|
+
sleep 2
|
118
|
+
processor_thread.exit
|
119
|
+
task.reload
|
120
|
+
expect(task.status).to eq('error')
|
121
|
+
expect(task.result['error']['exception']).to eq('Test Exception')
|
122
|
+
end
|
123
|
+
|
124
|
+
it 'uses insque notifications' do
|
125
|
+
Tasque.config.notify = true
|
126
|
+
janitor = Thread.new { Insque.janitor }
|
127
|
+
sleep 1
|
128
|
+
Tasque::Task.create! task: 'test', params: { text: 'This is the test!' }
|
129
|
+
processor_thread = Thread.new do
|
130
|
+
processor = Tasque::Processor.new
|
131
|
+
processor.add_handler('test') do |t|
|
132
|
+
t.complete!
|
133
|
+
{ log: 'completed task' }
|
134
|
+
end
|
135
|
+
processor.start
|
136
|
+
end
|
137
|
+
sleep 2
|
138
|
+
expect(Insque.redis.llen '{insque}inbox_myapp').to eq(3)
|
139
|
+
processor_thread.exit
|
140
|
+
janitor.exit
|
141
|
+
end
|
142
|
+
|
143
|
+
it 'uses heartbeat' do
|
144
|
+
Tasque.config.heartbeat = true
|
145
|
+
janitor = Thread.new { Insque.janitor }
|
146
|
+
sleep 1
|
147
|
+
processor_thread = Thread.new do
|
148
|
+
processor = Tasque::Processor.new
|
149
|
+
processor.start
|
150
|
+
end
|
151
|
+
sleep 4
|
152
|
+
expect(Insque.redis.llen '{insque}inbox_myapp').to eq(3)
|
153
|
+
processor_thread.exit
|
154
|
+
janitor.exit
|
155
|
+
end
|
156
|
+
end
|
data/tasque.gemspec
CHANGED
@@ -21,4 +21,8 @@ Gem::Specification.new do |gem|
|
|
21
21
|
gem.add_dependency("timers")
|
22
22
|
gem.add_dependency("state_machine")
|
23
23
|
gem.add_dependency("json")
|
24
|
+
gem.add_development_dependency('rspec')
|
25
|
+
gem.add_development_dependency('activesupport')
|
26
|
+
gem.add_development_dependency('sqlite3')
|
27
|
+
gem.add_development_dependency('insque')
|
24
28
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tasque
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Yuri Gomozov
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-09-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|
@@ -66,6 +66,62 @@ dependencies:
|
|
66
66
|
- - ">="
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: rspec
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: activesupport
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - ">="
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '0'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '0'
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: sqlite3
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - ">="
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '0'
|
104
|
+
type: :development
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - ">="
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '0'
|
111
|
+
- !ruby/object:Gem::Dependency
|
112
|
+
name: insque
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
114
|
+
requirements:
|
115
|
+
- - ">="
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: '0'
|
118
|
+
type: :development
|
119
|
+
prerelease: false
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - ">="
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: '0'
|
69
125
|
description: 'Task processing queue with states, history and priorities. Works with
|
70
126
|
your favorite database. '
|
71
127
|
email:
|
@@ -76,8 +132,11 @@ extra_rdoc_files: []
|
|
76
132
|
files:
|
77
133
|
- ".gitignore"
|
78
134
|
- Gemfile
|
135
|
+
- Gemfile.lock
|
79
136
|
- LICENSE
|
80
137
|
- README.md
|
138
|
+
- db/test.db
|
139
|
+
- insque.local.yml
|
81
140
|
- lib/generators/tasque/install_generator.rb
|
82
141
|
- lib/generators/tasque/templates/create_tasque_tasks.erb
|
83
142
|
- lib/generators/tasque/templates/tasque.erb
|
@@ -85,8 +144,11 @@ files:
|
|
85
144
|
- lib/tasque/configuration.rb
|
86
145
|
- lib/tasque/processor.rb
|
87
146
|
- lib/tasque/task.rb
|
147
|
+
- lib/tasque/task_cancel.rb
|
88
148
|
- lib/tasque/task_error.rb
|
89
149
|
- lib/tasque/version.rb
|
150
|
+
- spec/spec_helper.rb
|
151
|
+
- spec/tasque_spec.rb
|
90
152
|
- tasque.gemspec
|
91
153
|
homepage: https://github.com/Gropher/tasque
|
92
154
|
licenses: []
|
@@ -106,9 +168,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
106
168
|
- !ruby/object:Gem::Version
|
107
169
|
version: '0'
|
108
170
|
requirements: []
|
109
|
-
|
110
|
-
rubygems_version: 2.5.1
|
171
|
+
rubygems_version: 3.1.2
|
111
172
|
signing_key:
|
112
173
|
specification_version: 4
|
113
174
|
summary: ActiveRecord based task queue
|
114
|
-
test_files:
|
175
|
+
test_files:
|
176
|
+
- spec/spec_helper.rb
|
177
|
+
- spec/tasque_spec.rb
|