dynflow 1.8.1 → 1.8.2
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 +4 -4
- data/examples/remote_executor.rb +4 -3
- data/lib/dynflow/executors/sidekiq/core.rb +1 -1
- data/lib/dynflow/rails/configuration.rb +4 -4
- data/lib/dynflow/version.rb +1 -1
- data/lib/dynflow.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d4db626bf7deb1705c684ec0a1e4a0f55326129f94513076d0bd6eda7a8b61e7
|
4
|
+
data.tar.gz: 006b0a3e56c17c8c827f7375e761d1f47608b586d5fdbaaa3a16bc220b8879d6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8cb9a7044648545e5da5f1be5452d3170a1be2077207ccc83b85c2fd59523851bbe4a2e3cdef484cf6f02c41b82357373de11c4d41b7fb13802be0d1a49aa2c7
|
7
|
+
data.tar.gz: 91cb66bfddeb1044c52f2959d7c1d3f3e4ff4bf5b44dfa938ae1d48d07650e6a6c9169f9db6ab73ba0bf79d9bd0ce41235c6b1aecedc322a56f784466fa4bc05
|
data/examples/remote_executor.rb
CHANGED
@@ -168,10 +168,11 @@ elsif defined?(Sidekiq)
|
|
168
168
|
Sidekiq.default_worker_options = { :retry => 0, 'backtrace' => true }
|
169
169
|
# assuming the remote executor was required as part of initialization
|
170
170
|
# of the ActiveJob worker
|
171
|
-
|
171
|
+
queues = Sidekiq.configure_server { |c| c.options[:queues] }
|
172
|
+
world = if queues.include?("dynflow_orchestrator")
|
172
173
|
RemoteExecutorExample.initialize_sidekiq_orchestrator
|
173
|
-
elsif (
|
174
|
+
elsif (queues - ['dynflow_orchestrator']).any?
|
174
175
|
RemoteExecutorExample.initialize_sidekiq_worker
|
175
176
|
end
|
176
|
-
Sidekiq.options[:dynflow_world] = world
|
177
|
+
Sidekiq.configure_server { |c| c.options[:dynflow_world] = world }
|
177
178
|
end
|
@@ -9,7 +9,7 @@ require 'sidekiq-reliable-fetch'
|
|
9
9
|
Sidekiq.configure_server do |config|
|
10
10
|
# Use semi-reliable fetch
|
11
11
|
# for details see https://gitlab.com/gitlab-org/sidekiq-reliable-fetch/blob/master/README.md
|
12
|
-
config
|
12
|
+
config[:semi_reliable_fetch] = true
|
13
13
|
Sidekiq::ReliableFetch.setup_reliable_fetch!(config)
|
14
14
|
end
|
15
15
|
|
@@ -100,7 +100,7 @@ module Dynflow
|
|
100
100
|
end
|
101
101
|
|
102
102
|
def sidekiq_worker?
|
103
|
-
defined?(::Sidekiq) && ::Sidekiq.
|
103
|
+
defined?(::Sidekiq) && ::Sidekiq.configure_server { |c| c[:queues].any? }
|
104
104
|
end
|
105
105
|
|
106
106
|
def calculate_db_pool_size(world)
|
@@ -108,7 +108,7 @@ module Dynflow
|
|
108
108
|
|
109
109
|
base_value = 5
|
110
110
|
if defined?(::Sidekiq)
|
111
|
-
Sidekiq.
|
111
|
+
Sidekiq.configure_server { |c| c[:concurrency] } + base_value
|
112
112
|
else
|
113
113
|
world.config.queues.values.inject(base_value) do |pool_size, pool_options|
|
114
114
|
pool_size += pool_options[:pool_size]
|
@@ -152,7 +152,7 @@ module Dynflow
|
|
152
152
|
# we can't do any operation until the Rails.application.dynflow.world is set
|
153
153
|
config.auto_execute = false
|
154
154
|
config.auto_validity_check = false
|
155
|
-
if sidekiq_worker? && !Sidekiq.
|
155
|
+
if sidekiq_worker? && !Sidekiq.configure_server { |c| c[:queues].include?("dynflow_orchestrator") }
|
156
156
|
config.delayed_executor = nil
|
157
157
|
end
|
158
158
|
end
|
@@ -192,7 +192,7 @@ module Dynflow
|
|
192
192
|
if remote?
|
193
193
|
false
|
194
194
|
else
|
195
|
-
if defined?(::Sidekiq) && Sidekiq.
|
195
|
+
if defined?(::Sidekiq) && Sidekiq.configure_server { |c| c[:dynflow_executor] }
|
196
196
|
::Dynflow::Executors::Sidekiq::Core
|
197
197
|
else
|
198
198
|
::Dynflow::Executors::Parallel::Core
|
data/lib/dynflow/version.rb
CHANGED
data/lib/dynflow.rb
CHANGED
@@ -25,7 +25,7 @@ module Dynflow
|
|
25
25
|
# @return [Dynflow::World, nil]
|
26
26
|
def process_world
|
27
27
|
return @process_world if defined? @process_world
|
28
|
-
@process_world = Sidekiq.options[:dynflow_world]
|
28
|
+
@process_world = Sidekiq.configure_server { |c| c.options[:dynflow_world] }
|
29
29
|
raise "process world is not set" unless @process_world
|
30
30
|
@process_world
|
31
31
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dynflow
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.8.
|
4
|
+
version: 1.8.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ivan Necas
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2023-11-
|
12
|
+
date: 2023-11-30 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: multi_json
|