libis-workflow 2.0.7 → 2.0.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9327567da6093380f849f0deacb992873af61e60
4
- data.tar.gz: 5478d89b9e65716195e371dd0dcb667b89445161
3
+ metadata.gz: 08a9cade8a7cca8a05119c13566040aac6c124a4
4
+ data.tar.gz: 4cf75b64d08da9cfa54a9ffb8a4fbbe4a6d245c3
5
5
  SHA512:
6
- metadata.gz: 72ffe0fcc00964f7ec170d4b8595d220c0f9027735f22c8b76d6fa000c96ea4681854abb91452f13c274b6161b6deeaa9b9c59dfdc4efd0e9d72994b2778de25
7
- data.tar.gz: 26accfb461c22d93319bf955eed26ff3dbbd60fe2de62b4debd32f5e73bfd04d7ced849b55412a6d9db89ea73af02bf05fd556f4990c127fad1d9d7c04c8d216
6
+ metadata.gz: ced7d5d87182ea4460a36b3d80ce884b5cbc1dda573d477ce3f28dd306b2ccd07039ccae5b3b5695ce2c19f66cfa1e170f5ad281a907b2be522b17e70c8426b2
7
+ data.tar.gz: ae9bfc4b4955e6fa9679c0874908b69d5e2705e9ec8a7a519c9407277a98332bbacaebb3c8e0dfdb261936c934335a80ce364bc9a8c6a3e01b0a6294b7a7dce8
@@ -70,6 +70,8 @@ module Libis
70
70
  self.tasks = workflow.tasks
71
71
  configure_tasks self.options
72
72
 
73
+ self.save!
74
+
73
75
  self.tasks.each do |task|
74
76
  task.run self
75
77
  end
@@ -6,6 +6,9 @@ module Libis
6
6
  # noinspection RubyTooManyMethodsInspection
7
7
  class TaskGroup < Libis::Workflow::Task
8
8
 
9
+ parameter abort_on_failure: true,
10
+ description: 'Stop processing tasks if one task fails.'
11
+
9
12
  attr_accessor :tasks
10
13
 
11
14
  def initialize(parent, cfg = {})
@@ -38,6 +41,7 @@ module Libis
38
41
  debug 'Running subtask (%d/%d): %s', item, i+1, tasks.size, task.name
39
42
  task.run item
40
43
  status[item.status(task.namepath)] += 1
44
+ break if parameter(:abort_on_failure) && item.status(task.namepath) != :DONE
41
45
  end
42
46
 
43
47
  substatus_check(status, item, 'task')
@@ -1,5 +1,5 @@
1
1
  module Libis
2
2
  module Workflow
3
- VERSION = '2.0.7' unless const_defined? :VERSION # the guard is against a redefinition warning that happens on Travis
3
+ VERSION = '2.0.8' unless const_defined? :VERSION # the guard is against a redefinition warning that happens on Travis
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: libis-workflow
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.7
4
+ version: 2.0.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kris Dekeyser
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-03-13 00:00:00.000000000 Z
11
+ date: 2016-03-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler