parallax 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1b5ac6d394abaaa2b0f2b6634f0cb46a1e77584ae41d0a603dd46c96bd35b3c3
4
- data.tar.gz: cc568d1e88bed4cb5f7d2f7708fe6cdf1203e4623c0541c4a0326c6d8c5771c5
3
+ metadata.gz: 199b9a1f7d00f3ab396af10da44fbec350f059444e133a68128c33f6103efd44
4
+ data.tar.gz: f23cd123597d3070c5e23ab98a5db1288c5d85bf0f4170618ff304a1f17e05e9
5
5
  SHA512:
6
- metadata.gz: a72b7b5fb0d24365f359ce534b0c5feba903a8e534a994c509a0f2ff13fac449023990903e6f5dcd8ac85dc6bb2d358bddfd7f40c5f3f0058b2b16d79288bdf1
7
- data.tar.gz: 126f94e0441ce1bbc4acbbc86488b4f0df19bfa537c2afaca0ec0b6dd1d51ae7eb3b06d3cfd8586a3b40364ff7c54370abba4a89cdf6c9220d39575c7ddc7cfd
6
+ metadata.gz: a6a57b1760de4e0e857f46e2da3d0c18040846358c5f398270ec33328e661e63bff3d68d6a6d91baf09b38eb209a73691a14b3294b8aa58870847dac66084018
7
+ data.tar.gz: 6b8a58e098e65c5070b804cc6081dce58f616aaf06bd6b25adadb2cc2db8e5bf1606fa75732ef4fe0f73c9f98ba0f97c87ee6dc1fd8ec7c4d469bc3549edb7bc
data/Gemfile.lock CHANGED
@@ -1,22 +1,108 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- parallax (0.1.1)
4
+ parallax (0.3.0)
5
5
  activesupport
6
6
 
7
7
  GEM
8
8
  remote: https://rubygems.org/
9
9
  specs:
10
- activesupport (5.2.1.1)
10
+ actioncable (5.2.2)
11
+ actionpack (= 5.2.2)
12
+ nio4r (~> 2.0)
13
+ websocket-driver (>= 0.6.1)
14
+ actionmailer (5.2.2)
15
+ actionpack (= 5.2.2)
16
+ actionview (= 5.2.2)
17
+ activejob (= 5.2.2)
18
+ mail (~> 2.5, >= 2.5.4)
19
+ rails-dom-testing (~> 2.0)
20
+ actionpack (5.2.2)
21
+ actionview (= 5.2.2)
22
+ activesupport (= 5.2.2)
23
+ rack (~> 2.0)
24
+ rack-test (>= 0.6.3)
25
+ rails-dom-testing (~> 2.0)
26
+ rails-html-sanitizer (~> 1.0, >= 1.0.2)
27
+ actionview (5.2.2)
28
+ activesupport (= 5.2.2)
29
+ builder (~> 3.1)
30
+ erubi (~> 1.4)
31
+ rails-dom-testing (~> 2.0)
32
+ rails-html-sanitizer (~> 1.0, >= 1.0.3)
33
+ activejob (5.2.2)
34
+ activesupport (= 5.2.2)
35
+ globalid (>= 0.3.6)
36
+ activemodel (5.2.2)
37
+ activesupport (= 5.2.2)
38
+ activerecord (5.2.2)
39
+ activemodel (= 5.2.2)
40
+ activesupport (= 5.2.2)
41
+ arel (>= 9.0)
42
+ activestorage (5.2.2)
43
+ actionpack (= 5.2.2)
44
+ activerecord (= 5.2.2)
45
+ marcel (~> 0.3.1)
46
+ activesupport (5.2.2)
11
47
  concurrent-ruby (~> 1.0, >= 1.0.2)
12
48
  i18n (>= 0.7, < 2)
13
49
  minitest (~> 5.1)
14
50
  tzinfo (~> 1.1)
15
- concurrent-ruby (1.1.3)
51
+ arel (9.0.0)
52
+ builder (3.2.3)
53
+ concurrent-ruby (1.1.4)
54
+ crass (1.0.4)
16
55
  diff-lcs (1.3)
17
- i18n (1.1.1)
56
+ erubi (1.8.0)
57
+ globalid (0.4.1)
58
+ activesupport (>= 4.2.0)
59
+ i18n (1.2.0)
18
60
  concurrent-ruby (~> 1.0)
61
+ loofah (2.2.3)
62
+ crass (~> 1.0.2)
63
+ nokogiri (>= 1.5.9)
64
+ mail (2.7.1)
65
+ mini_mime (>= 0.1.1)
66
+ marcel (0.3.3)
67
+ mimemagic (~> 0.3.2)
68
+ method_source (0.9.2)
69
+ mimemagic (0.3.3)
70
+ mini_mime (1.0.1)
71
+ mini_portile2 (2.4.0)
19
72
  minitest (5.11.3)
73
+ nio4r (2.3.1)
74
+ nokogiri (1.9.1)
75
+ mini_portile2 (~> 2.4.0)
76
+ rack (2.0.6)
77
+ rack-test (1.1.0)
78
+ rack (>= 1.0, < 3)
79
+ rails (5.2.2)
80
+ actioncable (= 5.2.2)
81
+ actionmailer (= 5.2.2)
82
+ actionpack (= 5.2.2)
83
+ actionview (= 5.2.2)
84
+ activejob (= 5.2.2)
85
+ activemodel (= 5.2.2)
86
+ activerecord (= 5.2.2)
87
+ activestorage (= 5.2.2)
88
+ activesupport (= 5.2.2)
89
+ bundler (>= 1.3.0)
90
+ railties (= 5.2.2)
91
+ sprockets-rails (>= 2.0.0)
92
+ rails-dev-tools (1.2.3)
93
+ rails (~> 5.2.2)
94
+ rainbow (~> 3.0)
95
+ rails-dom-testing (2.0.3)
96
+ activesupport (>= 4.2.0)
97
+ nokogiri (>= 1.6)
98
+ rails-html-sanitizer (1.0.4)
99
+ loofah (~> 2.2, >= 2.2.2)
100
+ railties (5.2.2)
101
+ actionpack (= 5.2.2)
102
+ activesupport (= 5.2.2)
103
+ method_source
104
+ rake (>= 0.8.7)
105
+ thor (>= 0.19.0, < 2.0)
20
106
  rainbow (3.0.0)
21
107
  rake (10.5.0)
22
108
  rspec (3.8.0)
@@ -32,19 +118,31 @@ GEM
32
118
  diff-lcs (>= 1.2.0, < 2.0)
33
119
  rspec-support (~> 3.8.0)
34
120
  rspec-support (3.8.0)
121
+ sprockets (3.7.2)
122
+ concurrent-ruby (~> 1.0)
123
+ rack (> 1, < 3)
124
+ sprockets-rails (3.2.1)
125
+ actionpack (>= 4.0)
126
+ activesupport (>= 4.0)
127
+ sprockets (>= 3.0.0)
128
+ thor (0.20.3)
35
129
  thread_safe (0.3.6)
36
130
  tzinfo (1.2.5)
37
131
  thread_safe (~> 0.1)
132
+ websocket-driver (0.7.0)
133
+ websocket-extensions (>= 0.1.0)
134
+ websocket-extensions (0.1.3)
38
135
 
39
136
  PLATFORMS
40
137
  ruby
41
138
 
42
139
  DEPENDENCIES
43
- bundler (~> 1.17)
140
+ bundler (>= 1.17)
44
141
  parallax!
142
+ rails-dev-tools
45
143
  rainbow
46
- rake (~> 10.0)
47
- rspec (~> 3.0)
144
+ rake (>= 10.0)
145
+ rspec (>= 3.0)
48
146
 
49
147
  BUNDLED WITH
50
- 1.17.0
148
+ 1.17.1
data/README.md CHANGED
@@ -40,9 +40,13 @@ end
40
40
  # [2] in
41
41
  ```
42
42
 
43
- If you need inter-process communication, this can be done by calling `worker.send` and passing a list of arguments. The args are serialized and passed via IO pipe to a `collector` object, which is by default an instance of `Parallax::Collector` class. The collector then parses the args and treats them like a method call where the first arg is the name of the method. In the example above, the collectors calls the `log` method which prints the second arg.
43
+ If you need inter-process communication, this can be done by calling `worker.send` and passing a list of arguments. The args are serialized and passed via IO pipe to a `collector` object, which is by default an instance of `Parallax::Collector` class. The collector then parses the args and treats them like a method call where the first arg is the name of the method.
44
44
 
45
- The collector object is returned by the `Parallax.execute` method, so if you need to store each worker processed data you can use the `worker.store` method or implement it in your own custom collector. For example:
45
+ There are a number of predefined methods, build on top of `worker.send` that you can call to do a number of tasks:
46
+ * `log`: Used in the example above, the collectors calls the `log` method which prints the message to the stdout.
47
+ * `store`: Saves the argument object into a variable called `workers_data` in the collector.
48
+
49
+ The collector object is returned by the `Parallax.execute` method, so if you need to access the stored data called with the `worker.store` method you can do:
46
50
 
47
51
  ```ruby
48
52
  numbers = (0..100).to_a
@@ -65,12 +69,47 @@ puts collector.workers_data.inspect
65
69
 
66
70
  Other options you can pass to execute are:
67
71
  * `processes`: the number of processes in which parallelize the execution. Defaults to `Etc.nprocessors` (which is equal to the number of cores of the current running machine).
72
+ * `collector`: a custom collector object that you can implement yourself.
73
+
74
+ To use a custom collector, you need to `include Parallax::Collectable` in your custom collector, and initialize your collector by calling the included `initialize_collector` method.
75
+ Example of a custom collector:
76
+
77
+ ```ruby
78
+ # custom_collector.rb
79
+ class CustomCollector
80
+ include Parallax::Collectable
81
+
82
+ def initialize(worker_count, *args)
83
+ # Do your own initialization with *args, and then
84
+ initialize_collector(workers_count)
85
+ end
68
86
 
69
- Methods available for a `worker` object, which are collected in the `collector` object:
70
- * `log(message)`: prints a message in stdout.
71
- * `store(object)`: stores an object with timestamp and worker index.
72
- * `rescue(error)`: rescues an error from a worker and raises the same error in the collector.
73
- * `close`: closes worker communication with the collector.
87
+ def store(worker_index, object)
88
+ workers_data.push [ "worker #{worker_index} stored: #{object.inspect}" ]
89
+ end
90
+ end
91
+ ```
92
+
93
+ ```ruby
94
+ workers_count = 4
95
+ numbers = (0..100).to_a
96
+
97
+ custom_collector = CustomCollector.new(workers_count)
98
+ Parallax.execute numbers, collector: custom_collector, do |worker, numbers_chunk|
99
+ numbers_chunk.each do |number|
100
+ worker.store number * 2
101
+ end
102
+ end
103
+
104
+ puts custom_collector.workers_data.inspect
105
+
106
+ # Example output with 4 cores and custom collector:
107
+ # [ ["worker 0 stored 0"],
108
+ # ["worker 3 stored 152"],
109
+ # ["worker 1 stored 52"],
110
+ # ["worker 2 stored 102"],
111
+ # ...
112
+ ```
74
113
 
75
114
  ## Development
76
115
 
data/dev.yml ADDED
@@ -0,0 +1,4 @@
1
+ dev:
2
+ project_type: single
3
+ project_name: parallax
4
+ project_folder: /Users/fballardin/progetti/francy/parallax
@@ -0,0 +1,115 @@
1
+ module Parallax
2
+ module Collectable
3
+
4
+ def self.included(base)
5
+
6
+ # @return [Integer] the number of workers running in parallel.
7
+ attr_accessor :workers_count
8
+ # @return [Array] the result of all workers' store method calls.
9
+ attr_accessor :workers_data
10
+ # @return [Integer] the number of completed worker processes.
11
+ attr_accessor :closed_workers_count
12
+ # @return [IO::Pipe] the receiving stream of data.
13
+ attr_accessor :receiving_stream
14
+ # @return [IO::Pipe] the sending stream of data.
15
+ attr_accessor :sending_stream
16
+
17
+ ##
18
+ # Inizializes the collectable object with its needed parameters.
19
+ #
20
+ # @param [Integer] workers_count the number of workers running in parallel.
21
+ #
22
+ # @return [nil]
23
+ def initialize_collector(workers_count)
24
+ @workers_count = workers_count
25
+ @closed_workers_count = 0
26
+ @receiving_stream, @sending_stream = IO.pipe
27
+ @workers_data = []
28
+ end
29
+
30
+ ##
31
+ # Reads data from the receiving stream.
32
+ #
33
+ # @return [String] the received data.
34
+ def receive
35
+ self.collect @receiving_stream.gets.chomp
36
+ end
37
+
38
+ ##
39
+ # Interprets a received message from the worker and
40
+ # executes a method in the collector.
41
+ #
42
+ # @param [String] message the message as a string.
43
+ #
44
+ # @return [Object] the execution of the interpreted method.
45
+ def collect(message)
46
+ worker_index, method, *arguments = eval(message)
47
+ self.send method, worker_index, *arguments
48
+ end
49
+
50
+ ##
51
+ # Prints a message from the worker.
52
+ #
53
+ # @param [Integer] worker_index the worker number.
54
+ # @param [String] message the worker message.
55
+ #
56
+ # @return [nil]
57
+ def log(worker_index, message)
58
+ puts message
59
+ end
60
+
61
+ ##
62
+ # Saves an object in the workers' data.
63
+ #
64
+ # @param [Integer] worker_index the worker number.
65
+ # @param [Object] object the object.
66
+ #
67
+ # @return [nil]
68
+ def store(worker_index, object)
69
+ workers_data.push [ Time.now, worker_index, object ]
70
+ end
71
+
72
+ ##
73
+ # In a worker raises an error, this is rescued and reraised
74
+ # in the collector.
75
+ #
76
+ # @param [Integer] worker_index the worker number.
77
+ # @param [Class] error_class the class of the error.
78
+ # @param [String] error_message the message of the error.
79
+ #
80
+ # @return [nil]
81
+ def rescue(worker_index, error_class, error_message)
82
+ raise error_class, "Worker #{worker_index} Error: #{error_message}"
83
+ end
84
+
85
+ ##
86
+ # Closes a worker.
87
+ #
88
+ # @param [Integer] worker_index the worker number.
89
+ #
90
+ # @return [nil]
91
+ def close_worker(worker_index)
92
+ @closed_workers_count += 1
93
+ end
94
+
95
+ ##
96
+ # Closes the collector and its data streams.
97
+ #
98
+ # @return [nil]
99
+ def close
100
+ @receiving_stream.close
101
+ @sending_stream.close
102
+ end
103
+
104
+ ##
105
+ # Checks if all workers have terminated.
106
+ #
107
+ # return [Boolean] if all workers have terminated.
108
+ def all_workers_terminated?
109
+ @closed_workers_count >= @workers_count
110
+ end
111
+
112
+ end
113
+
114
+ end
115
+ end
@@ -1,51 +1,10 @@
1
1
  module Parallax
2
2
  class Collector
3
3
 
4
- attr_accessor :workers_count
5
- attr_accessor :workers_data
6
- attr_accessor :closed_workers_count
7
- attr_accessor :receiving_stream
8
- attr_accessor :sending_stream
4
+ include Parallax::Collectable
9
5
 
10
6
  def initialize(workers_count)
11
- @workers_count = workers_count
12
- @closed_workers_count = 0
13
- @receiving_stream, @sending_stream = IO.pipe
14
- @workers_data = []
15
- end
16
-
17
- def receive
18
- self.collect @receiving_stream.gets.chomp
19
- end
20
-
21
- def collect(message)
22
- worker_index, method, *arguments = eval(message)
23
- self.send method, worker_index, *arguments
24
- end
25
-
26
- def log(worker_index, message)
27
- puts message
28
- end
29
-
30
- def store(worker_index, object)
31
- workers_data.push [ Time.now, worker_index, object ]
32
- end
33
-
34
- def rescue(worker_index, error_class, error_message)
35
- raise error_class, "Worker #{worker_index} Error: #{error_message}"
36
- end
37
-
38
- def close_worker(worker_index)
39
- @closed_workers_count += 1
40
- end
41
-
42
- def all_workers_terminated?
43
- @closed_workers_count >= @workers_count
44
- end
45
-
46
- def close
47
- @receiving_stream.close
48
- @sending_stream.close
7
+ initialize_collector(workers_count)
49
8
  end
50
9
 
51
10
  end
@@ -1,3 +1,3 @@
1
1
  module Parallax
2
- VERSION = "0.2.0"
2
+ VERSION = '0.3.0'
3
3
  end
@@ -1,36 +1,80 @@
1
1
  module Parallax
2
2
  class Worker
3
3
 
4
- attr_accessor :receiver
4
+ # @return [Object] the collector object.
5
+ attr_accessor :collector
6
+ # @return [Integer] the index of this worker.
5
7
  attr_accessor :index
6
8
 
7
- def initialize(receiver, index)
8
- @receiver = receiver
9
+ ##
10
+ # Creates a new worker referred to the specified collector,
11
+ # and with the given index.
12
+ #
13
+ # @param [Collector] the collector.
14
+ # @param [Integer] the index.
15
+ #
16
+ # @return [Worker] the worker.
17
+ def initialize(collector, index)
18
+ @collector = collector
9
19
  @index = index
10
20
  end
11
21
 
22
+ ##
23
+ # Packs the message before sending it to the sending stream.
24
+ #
25
+ # @params [Array] args the message.
26
+ #
27
+ # @return [String] a string representation of the packed message.
12
28
  def pack(*args)
13
29
  [ self.index, *args ].inspect
14
30
  end
15
31
 
32
+ ##
33
+ # Sends the message to the sending stream.
34
+ #
35
+ # @params [Array] args the message.
36
+ #
37
+ # @return [nil]
16
38
  def send(*args)
17
- @receiver.sending_stream.puts pack(*args)
39
+ @collector.sending_stream.puts pack(*args)
18
40
  end
19
41
 
42
+ ##
43
+ # Logs the message to the collector.
44
+ #
45
+ # @params [String] message the message.
46
+ #
47
+ # @return [nil]
20
48
  def log(message)
21
- @receiver.sending_stream.puts pack(:log, message)
49
+ @collector.sending_stream.puts pack(:log, message)
22
50
  end
23
51
 
52
+ ##
53
+ # Stores the object in the collector.
54
+ #
55
+ # @param [Object] the object.
56
+ #
57
+ # @return [nil]
24
58
  def store(object)
25
- @receiver.sending_stream.puts pack(:store, object)
59
+ @collector.sending_stream.puts pack(:store, object)
26
60
  end
27
61
 
62
+ ##
63
+ # Rescues an error from the worker and sends it to the collector.
64
+ #
65
+ # @param [Exception] error the error.
66
+ #
67
+ # @return [nil]
28
68
  def rescue(error)
29
- @receiver.sending_stream.puts pack(:rescue, error.class, error.message)
69
+ @collector.sending_stream.puts pack(:rescue, error.class, error.message)
30
70
  end
31
71
 
72
+ ##
73
+ # Closes the worker and alerts the collector.
74
+ #
75
+ # @return [nil]
32
76
  def close
33
- @receiver.sending_stream.puts pack(:close_worker)
77
+ @collector.sending_stream.puts pack(:close_worker)
34
78
  end
35
79
 
36
80
  end
data/lib/parallax.rb CHANGED
@@ -1,12 +1,21 @@
1
1
  require 'active_support/core_ext/array'
2
2
 
3
3
  require 'parallax/version'
4
+ require 'parallax/collectable'
4
5
  require 'parallax/collector'
5
6
  require 'parallax/worker'
6
7
 
7
8
  module Parallax
8
9
 
9
10
  class << self
11
+
12
+ ##
13
+ # Get the default number of workers.
14
+ #
15
+ # @return [Integer] the workers count.
16
+ def workers_count
17
+ Etc.nprocessors
18
+ end
10
19
 
11
20
  ##
12
21
  # Divides the given elements in groups of N and executes
@@ -17,9 +26,13 @@ module Parallax
17
26
  #
18
27
  # @return [Collector] all processes output collector.
19
28
  def execute(elements, options = {}, &block)
20
- processes = options[:processes] || Etc.nprocessors
29
+ processes = options[:processes] || Parallax.workers_count
21
30
 
22
- collector = Parallax::Collector.new(processes)
31
+ if options[:collector].present?
32
+ collector = options[:collector]
33
+ else
34
+ collector = Parallax::Collector.new(processes)
35
+ end
23
36
  elements_chunks = elements.in_groups(processes, false)
24
37
  processes.times do |worker_index|
25
38
  Process.fork do
data/parallax.gemspec CHANGED
@@ -1,31 +1,32 @@
1
1
 
2
- lib = File.expand_path("../lib", __FILE__)
2
+ lib = File.expand_path('../lib', __FILE__)
3
3
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
- require "parallax/version"
4
+ require 'parallax/version'
5
5
 
6
6
  Gem::Specification.new do |spec|
7
- spec.name = "parallax"
7
+ spec.name = 'parallax'
8
8
  spec.version = Parallax::VERSION
9
- spec.authors = ["Francesco Ballardin"]
10
- spec.email = ["francesco.ballardin@develonproject.com"]
9
+ spec.authors = ['Francesco Ballardin']
10
+ spec.email = ['francesco.ballardin@develonproject.com']
11
11
 
12
12
  spec.summary = %q{Enhances Ruby inter-process communication, to boost your parallel code execution.}
13
13
  spec.description = %q{Enhances Ruby inter-process communication, to boost your parallel code execution.}
14
- spec.homepage = "https://github.com/Pluvie/ruby-parallax"
14
+ spec.homepage = 'https://github.com/Pluvie/ruby-parallax'
15
15
 
16
16
  # Specify which files should be added to the gem when it is released.
17
17
  # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
18
18
  spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
19
19
  `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
20
20
  end
21
- spec.bindir = "exe"
21
+ spec.bindir = 'exe'
22
22
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
23
- spec.require_paths = ["lib"]
23
+ spec.require_paths = ['lib']
24
24
 
25
- spec.add_dependency "activesupport"
25
+ spec.add_dependency 'activesupport'
26
26
 
27
- spec.add_development_dependency "bundler", "~> 1.17"
28
- spec.add_development_dependency "rake", "~> 10.0"
29
- spec.add_development_dependency "rspec", "~> 3.0"
30
- spec.add_development_dependency "rainbow"
27
+ spec.add_development_dependency 'bundler', '>= 1.17'
28
+ spec.add_development_dependency 'rake', '>= 10.0'
29
+ spec.add_development_dependency 'rspec', '>= 3.0'
30
+ spec.add_development_dependency 'rainbow'
31
+ spec.add_development_dependency 'rails-dev-tools'
31
32
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: parallax
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Francesco Ballardin
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-12-04 00:00:00.000000000 Z
11
+ date: 2018-12-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -28,42 +28,42 @@ dependencies:
28
28
  name: bundler
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - "~>"
31
+ - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: '1.17'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - "~>"
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '1.17'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rake
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - "~>"
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
47
  version: '10.0'
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - "~>"
52
+ - - ">="
53
53
  - !ruby/object:Gem::Version
54
54
  version: '10.0'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: rspec
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - "~>"
59
+ - - ">="
60
60
  - !ruby/object:Gem::Version
61
61
  version: '3.0'
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - "~>"
66
+ - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '3.0'
69
69
  - !ruby/object:Gem::Dependency
@@ -80,6 +80,20 @@ dependencies:
80
80
  - - ">="
81
81
  - !ruby/object:Gem::Version
82
82
  version: '0'
83
+ - !ruby/object:Gem::Dependency
84
+ name: rails-dev-tools
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'
83
97
  description: Enhances Ruby inter-process communication, to boost your parallel code
84
98
  execution.
85
99
  email:
@@ -97,7 +111,9 @@ files:
97
111
  - Rakefile
98
112
  - bin/console
99
113
  - bin/setup
114
+ - dev.yml
100
115
  - lib/parallax.rb
116
+ - lib/parallax/collectable.rb
101
117
  - lib/parallax/collector.rb
102
118
  - lib/parallax/version.rb
103
119
  - lib/parallax/worker.rb