cpee 2.1.67 → 2.1.69

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
  SHA256:
3
- metadata.gz: 66e313a326e4a845a8274655c17d53ed396b9c4869cc7308f0d3b71396c5c1cd
4
- data.tar.gz: 2635e43efb227782f4835c94cfbde0e423c9a543c81efb66e01f5ef9d5c0d06d
3
+ metadata.gz: 742b60e370b4d7dca440503134cc68e53c86cba0efa32b2241e47e5ed30a494b
4
+ data.tar.gz: b7b77bcb900adbff359b599f4769ed5ebdf34d2eb1c1801afe589d389043f26f
5
5
  SHA512:
6
- metadata.gz: 773fb767bcd14e9e719a0716a5b5d8cb51a8a7c80ba3de7eb32a1b3f3d2f06666775fe0ebe7b9d6f57757c39fff0692d9bb8dcc5c7abe6ed1deefd4a2202b389
7
- data.tar.gz: 182169f0e3bca3b90ac0d97382ba2f3abe771c53c3e8298907a5f053fb5f0d17a7f7b567b9e5960cc0cddc490764186ebe742b233a09ec886ad87005796d75ca
6
+ metadata.gz: 70a3f1d1bad894a550150b486e097ca023674fe73e586ed795180ba82ab9c2999321b8964a7aa18576b48ab643cb5b07a6f10599d62a8ce5f583afe85d8b9f9e
7
+ data.tar.gz: 79b5d7581ad1def9ad8853844cfd8bf402daa1de398738c2477c43d5cd5c810b6ff042c5ea5aa35fbc045758f3b6e8a213cfbb9a3d87ce3f9bb69ec66224ce8a
@@ -224,6 +224,14 @@
224
224
  <attribute name="allocated_to" rngui:label="allocated_to" rngui:default="not_allocated">
225
225
  <data type="string" rngui:readonly="true"/>
226
226
  </attribute>
227
-
227
+ </element>
228
+ <element name="expectedready" rngui:label="Expected Ready">
229
+ <data name="expectedready" type="decimal" rngui:readonly="true"/>
230
+ </element>
231
+ <element name="plannedstart" rngui:label="Planned Start Time">
232
+ <data name="plannedstart" type="decimal" rngui:readonly="true"/>
233
+ </element>
234
+ <element name="plannedend" rngui:label="Planned End Time">
235
+ <data name="plannedend" type="decimal" rngui:readonly="true"/>
228
236
  </element>
229
237
  </element>
@@ -253,7 +253,15 @@
253
253
  <attribute name="allocated_to" rngui:label="allocated_to" rngui:default="not_allocated">
254
254
  <data type="string" rngui:readonly="true"/>
255
255
  </attribute>
256
-
257
256
  </element>
258
257
 
258
+ <element name="expectedready" rngui:label="Expected Ready">
259
+ <data name="expectedready" type="decimal" rngui:readonly="true"/>
260
+ </element>
261
+ <element name="plannedstart" rngui:label="Planned Start Time">
262
+ <data name="plannedstart" type="decimal" rngui:readonly="true"/>
263
+ </element>
264
+ <element name="plannedend" rngui:label="Planned End Time">
265
+ <data name="plannedend" type="decimal" rngui:readonly="true"/>
266
+ </element>
259
267
  </element>
@@ -15,6 +15,15 @@
15
15
  <attribute name="allocated_to" rngui:label="allocated_to" rngui:default="not_allocated">
16
16
  <data type="string" rngui:readonly="true"/>
17
17
  </attribute>
18
-
19
18
  </element>
19
+ <element name="expectedready" rngui:label="Expected Ready">
20
+ <data name="expectedready" type="decimal" rngui:readonly="true"/>
21
+ </element>
22
+ <element name="plannedstart" rngui:label="Planned Start Time">
23
+ <data name="plannedstart" type="decimal" rngui:readonly="true"/>
24
+ </element>
25
+ <element name="plannedend" rngui:label="Planned End Time">
26
+ <data name="plannedend" type="decimal" rngui:readonly="true"/>
27
+ </element>
28
+
20
29
  </element>
data/cpee.gemspec CHANGED
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = "cpee"
3
- s.version = "2.1.67"
3
+ s.version = "2.1.69"
4
4
  s.platform = Gem::Platform::RUBY
5
5
  s.license = "LGPL-3.0-or-later"
6
6
  s.summary = "The cloud process execution engine (cpee.org). If you just need workflow execution, without a rest service exposing it, then use WEEL."
@@ -22,7 +22,7 @@ Gem::Specification.new do |s|
22
22
  s.homepage = 'http://cpee.org/'
23
23
 
24
24
  s.add_runtime_dependency 'riddl', '~> 1.0'
25
- s.add_runtime_dependency 'weel', '~> 1.99', '>= 1.99.124'
25
+ s.add_runtime_dependency 'weel', '~> 1.99', '>= 1.99.125'
26
26
  s.add_runtime_dependency 'highline', '~> 2.0'
27
27
  s.add_runtime_dependency 'redis', '~> 5.0'
28
28
  s.add_runtime_dependency 'rubyzip', '~>2'
@@ -31,5 +31,5 @@ Gem::Specification.new do |s|
31
31
  s.add_runtime_dependency 'get_process_mem', '~>0.2'
32
32
  s.add_runtime_dependency 'webrick', '~>1.7'
33
33
  s.add_runtime_dependency 'rbtrace', '~>0.4'
34
- s.add_runtime_dependency 'cpee-eval-ruby', '~> 1.0', '>= 1.0.1'
34
+ s.add_runtime_dependency 'cpee-eval-ruby', '~> 1.0', '>= 1.0.4'
35
35
  end
@@ -36,19 +36,15 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
36
36
  def self::inform_syntax_error(arguments,err,code)# {{{
37
37
  # TODO extract spot (code) where error happened for better error handling (ruby 3.1 only)
38
38
  # https://github.com/rails/rails/pull/45818/commits/3beb2aff3be712e44c34a588fbf35b79c0246ca5
39
- puts err.message
40
- puts err.backtrace
41
-
42
39
  controller = arguments[0]
43
- mess = err.backtrace ? err.backtrace[0].gsub(/([\w -_]+):(\d+):in.*/,'\\1, Line \2: ') : ''
44
- mess += err.message
45
- controller.notify("description/error", :message => mess)
40
+ controller.notify("executionhandler/error", :message => err.backtrace[0].match(/(.*?), Line (\d+):\s(.*)/)[3] + err.message, :line => err.backtrace[0].match(/(.*?), Line (\d+):/)[2], :where => err.backtrace[0].match(/(.*?), Line (\d+):/)[1])
41
+ #mess = err.backtrace ? err.backtrace[0].gsub(/([\w -_]+):(\d+):in.*/,'\\1, Line \2: ') : ''
42
+ #mess += err.message
43
+ #controller.notify("description/error", :message => err.message, :line => err.backtrace[0].match(/(.*?):(\d+):/)[2], :where => err.backtrace[0].match(/(.*?):(\d+):/)[1])
46
44
  end# }}}
47
45
  def self::inform_connectionwrapper_error(arguments,err) # {{{
48
46
  controller = arguments[0]
49
- puts err.message
50
- puts err.backtrace
51
- controller.notify("executionhandler/error", :message => err.backtrace[0].gsub(/([\w -_]+):(\d+):in.*/,'\\1, Line \2: ') + err.message)
47
+ controller.notify("executionhandler/error", :message => err.backtrace[0].match(/(.*?), Line (\d+):\s(.*)/)[3] + err.message, :line => err.backtrace[0].match(/(.*?), Line (\d+):/)[2], :where => err.backtrace[0].match(/(.*?), Line (\d+):/)[1])
52
48
  end # }}}
53
49
  def self::inform_position_change(arguments,ipc={}) # {{{
54
50
  controller = arguments[0]
@@ -250,9 +246,7 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
250
246
  @controller.notify("activity/manipulating", :'activity-uuid' => @handler_activity_uuid, :endpoint => @handler_endpoint, :label => @label, :activity => @handler_position)
251
247
  end # }}}
252
248
  def inform_activity_failed(err) # {{{
253
- puts err.message
254
- puts err.backtrace
255
- @controller.notify("activity/failed", :'activity-uuid' => @handler_activity_uuid, :endpoint => @handler_endpoint, :label => @label, :activity => @handler_position, :message => err.message, :line => err.backtrace[0].match(/(.*?):(\d+):/)[2], :where => err.backtrace[0].match(/(.*?):(\d+):/)[1])
249
+ @controller.notify("activity/failed", :'activity-uuid' => @handler_activity_uuid, :endpoint => @handler_endpoint, :label => @label, :activity => @handler_position, :message => err.backtrace[0].match(/(.*?):(\d+):\s(.*)/)[3], :line => err.backtrace[0].match(/(.*?):(\d+):/)[2], :where => err.backtrace[0].match(/(.*?):(\d+):/)[1])
256
250
  end # }}}
257
251
  def inform_manipulate_change(status,changed_dataelements,changed_endpoints,dataelements,endpoints) # {{{
258
252
  unless status.nil?
@@ -326,9 +320,21 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
326
320
  GC.start
327
321
  end #}}}
328
322
 
329
- def prepare(lock,dataelements,endpoints,status,local,additional,code,exec_endpoints,exec_parameters)
323
+ def code_error_handling(ret,where,what=RuntimeError) #{{{
324
+ sig = ret.find{|e| e.name == "signal" }.value
325
+ sigt = ret.find{|e| e.name == "signal_text" }.value
326
+ case sig
327
+ when 'Signal::Again'; throw WEEL::Signal::Again
328
+ when 'Signal::Error'; raise what, '', [where + ' ' + sigt]
329
+ when 'Signal::Stop'; raise WEEL::Signal::Stop
330
+ when 'Signal::SyntaxError'; raise SyntaxError, '', [where + ' ' + sigt]
331
+ else
332
+ raise 'something bad happened, but we dont know what.'
333
+ end
334
+ end #}}}
335
+ def prepare(lock,dataelements,endpoints,status,local,additional,code,exec_endpoints,exec_parameters) #{{{
330
336
  struct = if code
331
- manipulate(true,lock,dataelements,endpoints,status,local,additional,code,'Parameter')
337
+ manipulate(true,lock,dataelements,endpoints,status,local,additional,code,'prepare')
332
338
  else
333
339
  WEEL::ReadStructure.new(dataelements,endpoints,local,additional)
334
340
  end
@@ -353,7 +359,7 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
353
359
  recv = if status >= 200 && status < 300
354
360
  ret[0].value
355
361
  else
356
- nil
362
+ code_error_handling ret, 'Parameter ' + t.value.code
357
363
  end
358
364
  t.value = recv
359
365
  end
@@ -373,7 +379,7 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
373
379
  recv = if status >= 200 && status < 300
374
380
  ret[0].value
375
381
  else
376
- nil
382
+ code_error_handling ret, 'Condition ' + code, WEEL::Signal::Error
377
383
  end
378
384
  recv = 'false' unless recv
379
385
  recv = (recv == 'false' || recv == 'null' || recv == 'nil' ? false : true)
@@ -411,7 +417,7 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
411
417
 
412
418
  struct
413
419
  else
414
- nil
420
+ code_error_handling ret, where
415
421
  end
416
422
  end
417
423
  end #}}}
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cpee
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.67
4
+ version: 2.1.69
5
5
  platform: ruby
6
6
  authors:
7
7
  - Juergen eTM Mangler
@@ -35,7 +35,7 @@ dependencies:
35
35
  version: '1.99'
36
36
  - - ">="
37
37
  - !ruby/object:Gem::Version
38
- version: 1.99.124
38
+ version: 1.99.125
39
39
  type: :runtime
40
40
  prerelease: false
41
41
  version_requirements: !ruby/object:Gem::Requirement
@@ -45,7 +45,7 @@ dependencies:
45
45
  version: '1.99'
46
46
  - - ">="
47
47
  - !ruby/object:Gem::Version
48
- version: 1.99.124
48
+ version: 1.99.125
49
49
  - !ruby/object:Gem::Dependency
50
50
  name: highline
51
51
  requirement: !ruby/object:Gem::Requirement
@@ -167,7 +167,7 @@ dependencies:
167
167
  version: '1.0'
168
168
  - - ">="
169
169
  - !ruby/object:Gem::Version
170
- version: 1.0.1
170
+ version: 1.0.4
171
171
  type: :runtime
172
172
  prerelease: false
173
173
  version_requirements: !ruby/object:Gem::Requirement
@@ -177,7 +177,7 @@ dependencies:
177
177
  version: '1.0'
178
178
  - - ">="
179
179
  - !ruby/object:Gem::Version
180
- version: 1.0.1
180
+ version: 1.0.4
181
181
  description: see http://cpee.org
182
182
  email: juergen.mangler@gmail.com
183
183
  executables: