cpee 2.1.62 → 2.1.64
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/cockpit/templates/Coopis 2010 Ext.xml +193 -0
- data/cpee.gemspec +3 -3
- data/server/executionhandlers/ruby/connection.rb +39 -53
- data/server/executionhandlers/rubyext/connection.rb +45 -56
- data/server/resources/topics.xml +1 -0
- data/server/routing/end.pid +1 -1
- data/server/routing/forward-events-00.pid +1 -1
- data/server/routing/forward-votes.pid +1 -1
- data/server/routing/persist.pid +1 -1
- metadata +11 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6d5e5c7b5da8458c5a7e2101d018337ba353c6a5d5e3fe5e359456aba9693f02
|
4
|
+
data.tar.gz: f74517ec8299ce372750c0d4e6cce29d678ae328a96942cac80c3e86d73f9a1b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2a382615beced6f3af27bee42068b8000d22bc1d9694351659d97b7013ac11b6c8ab34bcadb29789b3f8f46d29b1e19a9f380903f7a04bf19a03c10b70557a96
|
7
|
+
data.tar.gz: 003f97f1487e72749878bf00e34c1d557da3381b325879e3575f2b690584baf65a0b81c0e57490345e289a6c42108a319761bf5a5ec38ce796665ed273fdcc5d
|
@@ -0,0 +1,193 @@
|
|
1
|
+
<?xml version="1.0"?>
|
2
|
+
<testset xmlns="http://cpee.org/ns/properties/2.0">
|
3
|
+
<executionhandler>rubyext</executionhandler>
|
4
|
+
<dataelements>
|
5
|
+
<persons>3</persons>
|
6
|
+
<card>Visa_12345</card>
|
7
|
+
<airline/>
|
8
|
+
<hotels>[]</hotels>
|
9
|
+
<from>Vienna</from>
|
10
|
+
<to>Prague</to>
|
11
|
+
<costs>0</costs>
|
12
|
+
</dataelements>
|
13
|
+
<endpoints>
|
14
|
+
<bookAir>http://gruppe.wst.univie.ac.at/~mangler/services/airline.php</bookAir>
|
15
|
+
<user>https-post://cpee.org/services/timeout-user.php</user>
|
16
|
+
<auto>https-post://cpee.org/services/timeout-auto.php</auto>
|
17
|
+
<timeout>https://cpee.org/services/timeout.php</timeout>
|
18
|
+
<bookHotel>http://gruppe.wst.univie.ac.at/~mangler/services/hotel.php</bookHotel>
|
19
|
+
<subprocess>https://cpee.org/flow/start/url/</subprocess>
|
20
|
+
<approve>http://gruppe.wst.univie.ac.at/~mangler/services/approval.php</approve>
|
21
|
+
<send>https-post://cpee.org/ing/correlators/message/send/</send>
|
22
|
+
<receive>https-get://cpee.org/ing/correlators/message/receive/</receive>
|
23
|
+
</endpoints>
|
24
|
+
<attributes>
|
25
|
+
<theme>extended</theme>
|
26
|
+
<info>Coopis 2010 Ext</info>
|
27
|
+
<creator>Christine Ashcreek</creator>
|
28
|
+
<author>Christine Ashcreek</author>
|
29
|
+
<modeltype>CPEE</modeltype>
|
30
|
+
<design_stage>development</design_stage>
|
31
|
+
<guarded>none</guarded>
|
32
|
+
<design_dir>Templates.dir/</design_dir>
|
33
|
+
<guarded_id/>
|
34
|
+
<model_uuid>1cdc1bc1-6cf9-4f52-a227-8c87a7b9120a</model_uuid>
|
35
|
+
</attributes>
|
36
|
+
<description>
|
37
|
+
<description xmlns="http://cpee.org/ns/description/1.0">
|
38
|
+
<call id="a1" endpoint="bookAir">
|
39
|
+
<parameters>
|
40
|
+
<label>Book Airline 1</label>
|
41
|
+
<method>:post</method>
|
42
|
+
<arguments>
|
43
|
+
<from>!data.from</from>
|
44
|
+
<to>!data.to</to>
|
45
|
+
<persons>!data.persons</persons>
|
46
|
+
</arguments>
|
47
|
+
</parameters>
|
48
|
+
<code>
|
49
|
+
<prepare/>
|
50
|
+
<finalize output="result">data.airline = result.value('id')
|
51
|
+
data.costs += result.value('costs').to_f
|
52
|
+
status.update 1, 'Hotel'</finalize>
|
53
|
+
<update output="result"/>
|
54
|
+
<rescue output="result"/>
|
55
|
+
</code>
|
56
|
+
<annotations>
|
57
|
+
<_timing>
|
58
|
+
<_timing_weight/>
|
59
|
+
<_timing_avg/>
|
60
|
+
<explanations/>
|
61
|
+
</_timing>
|
62
|
+
<_shifting>
|
63
|
+
<_shifting_type>Duration</_shifting_type>
|
64
|
+
</_shifting>
|
65
|
+
<_context_data_analysis>
|
66
|
+
<probes/>
|
67
|
+
<ips/>
|
68
|
+
</_context_data_analysis>
|
69
|
+
<report>
|
70
|
+
<url/>
|
71
|
+
</report>
|
72
|
+
<_notes>
|
73
|
+
<_notes_general/>
|
74
|
+
</_notes>
|
75
|
+
</annotations>
|
76
|
+
<documentation>
|
77
|
+
<input/>
|
78
|
+
<output/>
|
79
|
+
<implementation>
|
80
|
+
<description/>
|
81
|
+
</implementation>
|
82
|
+
<code>
|
83
|
+
<description/>
|
84
|
+
</code>
|
85
|
+
</documentation>
|
86
|
+
</call>
|
87
|
+
<parallel wait="-1" cancel="last">
|
88
|
+
<loop mode="pre_test" condition="data.persons > 0">
|
89
|
+
<parallel_branch>
|
90
|
+
<call id="a2" endpoint="bookHotel">
|
91
|
+
<parameters>
|
92
|
+
<label>Book Hotel</label>
|
93
|
+
<method>:post</method>
|
94
|
+
<arguments>
|
95
|
+
<to>!data.to</to>
|
96
|
+
</arguments>
|
97
|
+
</parameters>
|
98
|
+
<code>
|
99
|
+
<prepare/>
|
100
|
+
<finalize output="result">data.hotels << result.value('id')
|
101
|
+
data.costs += result.value('costs').to_f</finalize>
|
102
|
+
<update output="result"/>
|
103
|
+
<rescue output="result"/>
|
104
|
+
</code>
|
105
|
+
<annotations>
|
106
|
+
<_timing>
|
107
|
+
<_timing_weight/>
|
108
|
+
<_timing_avg/>
|
109
|
+
<explanations/>
|
110
|
+
</_timing>
|
111
|
+
<_shifting>
|
112
|
+
<_shifting_type>Duration</_shifting_type>
|
113
|
+
</_shifting>
|
114
|
+
<_context_data_analysis>
|
115
|
+
<probes/>
|
116
|
+
<ips/>
|
117
|
+
</_context_data_analysis>
|
118
|
+
<report>
|
119
|
+
<url/>
|
120
|
+
</report>
|
121
|
+
<_notes>
|
122
|
+
<_notes_general/>
|
123
|
+
</_notes>
|
124
|
+
</annotations>
|
125
|
+
<documentation>
|
126
|
+
<input/>
|
127
|
+
<output/>
|
128
|
+
<implementation>
|
129
|
+
<description/>
|
130
|
+
</implementation>
|
131
|
+
<code>
|
132
|
+
<description/>
|
133
|
+
</code>
|
134
|
+
</documentation>
|
135
|
+
</call>
|
136
|
+
</parallel_branch>
|
137
|
+
<manipulate id="a3">data.persons -= 1</manipulate>
|
138
|
+
</loop>
|
139
|
+
</parallel>
|
140
|
+
<choose mode="exclusive">
|
141
|
+
<alternative condition="data.costs > 700">
|
142
|
+
<_probability>
|
143
|
+
<_probability_min/>
|
144
|
+
<_probability_max/>
|
145
|
+
<_probability_avg/>
|
146
|
+
</_probability>
|
147
|
+
<call id="a4" endpoint="approve">
|
148
|
+
<parameters>
|
149
|
+
<label>Approve Hotel</label>
|
150
|
+
<method>:post</method>
|
151
|
+
<arguments>
|
152
|
+
<costs>!data.costs</costs>
|
153
|
+
</arguments>
|
154
|
+
</parameters>
|
155
|
+
<annotations>
|
156
|
+
<_timing>
|
157
|
+
<_timing_weight/>
|
158
|
+
<_timing_avg/>
|
159
|
+
<explanations/>
|
160
|
+
</_timing>
|
161
|
+
<_shifting>
|
162
|
+
<_shifting_type>Duration</_shifting_type>
|
163
|
+
</_shifting>
|
164
|
+
<_context_data_analysis>
|
165
|
+
<probes/>
|
166
|
+
<ips/>
|
167
|
+
</_context_data_analysis>
|
168
|
+
<report>
|
169
|
+
<url/>
|
170
|
+
</report>
|
171
|
+
<_notes>
|
172
|
+
<_notes_general/>
|
173
|
+
</_notes>
|
174
|
+
</annotations>
|
175
|
+
<documentation>
|
176
|
+
<input/>
|
177
|
+
<output/>
|
178
|
+
<implementation>
|
179
|
+
<description/>
|
180
|
+
</implementation>
|
181
|
+
</documentation>
|
182
|
+
</call>
|
183
|
+
</alternative>
|
184
|
+
<otherwise/>
|
185
|
+
</choose>
|
186
|
+
</description>
|
187
|
+
</description>
|
188
|
+
<transformation>
|
189
|
+
<description type="copy"/>
|
190
|
+
<dataelements type="none"/>
|
191
|
+
<endpoints type="none"/>
|
192
|
+
</transformation>
|
193
|
+
</testset>
|
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.
|
3
|
+
s.version = "2.1.64"
|
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.
|
25
|
+
s.add_runtime_dependency 'weel', '~> 1.99', '>= 1.99.123'
|
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'
|
34
|
+
s.add_runtime_dependency 'cpee-eval-ruby', '~> 1.0', '>= 1.0.1'
|
35
35
|
end
|
@@ -68,24 +68,6 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
68
68
|
@guard_items = []
|
69
69
|
end # }}}
|
70
70
|
|
71
|
-
def prepare(readonly, endpoints, parameters) #{{{
|
72
|
-
@handler_endpoint = endpoints.is_a?(Array) ? endpoints.map{ |ep| readonly.endpoints[ep] }.compact : readonly.endpoints[endpoints]
|
73
|
-
if @controller.attributes['twin_engine']
|
74
|
-
@handler_endpoint_orig = @handler_endpoint
|
75
|
-
@handler_endpoint = @controller.attributes['twin_engine'].to_s + '?original_endpoint=' + Riddl::Protocols::Utils::escape(@handler_endpoint)
|
76
|
-
end
|
77
|
-
params = parameters.dup
|
78
|
-
params[:arguments] = params[:arguments].dup if params[:arguments]
|
79
|
-
params[:arguments]&.map! do |ele|
|
80
|
-
t = ele.dup
|
81
|
-
if t.value.is_a?(Proc)
|
82
|
-
t.value = readonly.instance_exec &t.value
|
83
|
-
end
|
84
|
-
t
|
85
|
-
end
|
86
|
-
params
|
87
|
-
end #}}}
|
88
|
-
|
89
71
|
def additional #{{{
|
90
72
|
{
|
91
73
|
:attributes => @controller.attributes,
|
@@ -256,9 +238,9 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
256
238
|
true
|
257
239
|
end # }}}
|
258
240
|
|
259
|
-
def activity_uuid
|
241
|
+
def activity_uuid #{{{
|
260
242
|
@handler_activity_uuid
|
261
|
-
end
|
243
|
+
end #}}}
|
262
244
|
|
263
245
|
def inform_activity_done # {{{
|
264
246
|
@controller.notify("activity/done", :'activity-uuid' => @handler_activity_uuid, :endpoint => @handler_endpoint, :label => @label, :activity => @handler_position)
|
@@ -292,7 +274,7 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
292
274
|
@controller.vote("activity/syncing_before", :'activity-uuid' => @handler_activity_uuid, :endpoint => @handler_endpoint, :activity => @handler_position, :label => @label, :parameters => parameters)
|
293
275
|
end # }}}
|
294
276
|
|
295
|
-
def callback(result=nil,options={})
|
277
|
+
def callback(result=nil,options={}) #{{{
|
296
278
|
recv = CPEE::EvalRuby::Translation::structurize_result(result)
|
297
279
|
@controller.notify("activity/receiving", :'activity-uuid' => @handler_activity_uuid, :label => @label, :activity => @handler_position, :endpoint => @handler_endpoint, :received => recv, :annotations => @anno)
|
298
280
|
|
@@ -311,7 +293,7 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
311
293
|
@controller.notify("activity/status", :'activity-uuid' => @handler_activity_uuid, :label => @label, :activity => @handler_position, :endpoint => @handler_endpoint, :status => options['CPEE_STATUS'])
|
312
294
|
end
|
313
295
|
if options['CPEE_UPDATE']
|
314
|
-
@handler_continue.continue WEEL::Signal::
|
296
|
+
@handler_continue.continue WEEL::Signal::UpdateAgain
|
315
297
|
else
|
316
298
|
@controller.cancel_callback(@handler_passthrough)
|
317
299
|
@handler_passthrough = nil
|
@@ -323,7 +305,7 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
323
305
|
@handler_continue.continue
|
324
306
|
end
|
325
307
|
end
|
326
|
-
end
|
308
|
+
end #}}}
|
327
309
|
|
328
310
|
def mem_guard() #{{{
|
329
311
|
@guard_files.delete_if do |p|
|
@@ -337,39 +319,43 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
337
319
|
GC.start
|
338
320
|
end #}}}
|
339
321
|
|
340
|
-
def
|
341
|
-
|
342
|
-
|
343
|
-
|
344
|
-
|
345
|
-
|
346
|
-
|
347
|
-
|
348
|
-
|
349
|
-
|
350
|
-
|
351
|
-
|
322
|
+
def prepare(__struct, __endpoints, __parameters) #{{{
|
323
|
+
@handler_endpoint = __endpoints.is_a?(Array) ? __endpoints.map{ |ep| __struct.endpoints[ep] }.compact : __struct.endpoints[__endpoints]
|
324
|
+
if @controller.attributes['twin_engine']
|
325
|
+
@handler_endpoint_orig = @handler_endpoint
|
326
|
+
@handler_endpoint = @controller.attributes['twin_engine'].to_s + '?original_endpoint=' + Riddl::Protocols::Utils::escape(@handler_endpoint)
|
327
|
+
end
|
328
|
+
__params = __parameters.dup
|
329
|
+
__params[:arguments] = __params[:arguments].dup if __params[:arguments]
|
330
|
+
__params[:arguments]&.map! do |__ele|
|
331
|
+
__tmp = __ele.dup
|
332
|
+
if __tmp.value.is_a?(WEEL::ProcString)
|
333
|
+
__tmp.value = __struct.instance_eval __tmp.value.code, 'Parameter', 1
|
334
|
+
end
|
335
|
+
__tmp
|
336
|
+
end
|
337
|
+
__params
|
338
|
+
end #}}}
|
339
|
+
def test_condition(__dataelements,__endpoints,__local,__additional,__code,__args={}) #{{{
|
340
|
+
__struct = WEEL::ReadStructure.new(__dataelements,__endpoints,__local,__additional).instance_eval(__code,'Condition',1)
|
341
|
+
@controller.notify("gateway/decide", :instance_uuid => @controller.uuid, :code => code, :condition => (__struct ? "true" : "false"))
|
342
|
+
__struct
|
343
|
+
end #}}}
|
344
|
+
def manipulate(__readonly,__lock,__dataelements,__endpoints,__status,__local,__additional,__code,__where,__result=nil,__options=nil) #{{{
|
345
|
+
result = CPEE::EvalRuby::Translation::simplify_structurized_result(__result)
|
346
|
+
__struct = if __readonly
|
347
|
+
WEEL::ReadStructure.new(__dataelements,__endpoints,__local,__additional)
|
352
348
|
else
|
353
|
-
WEEL::ManipulateStructure.new(
|
349
|
+
WEEL::ManipulateStructure.new(__dataelements,__endpoints,__status,__local,__additional)
|
354
350
|
end
|
355
|
-
|
356
|
-
|
357
|
-
end
|
351
|
+
__struct.instance_eval(__code,__where,1)
|
352
|
+
__struct
|
353
|
+
end #}}}
|
358
354
|
|
359
|
-
def
|
355
|
+
def split_branches(branches) # factual, so for inclusive or [[a],[b],[c,d,e]]{{{
|
356
|
+
@controller.notify("gateway/split", :instance_uuid => @controller.uuid, :branches => branches)
|
357
|
+
end #}}}
|
358
|
+
def join_branches(branches) # factual, so for inclusive or [[a],[b],[c,d,e]]{{{
|
360
359
|
@controller.notify("gateway/join", :instance_uuid => @controller.uuid, :branches => branches)
|
361
|
-
end
|
362
|
-
|
363
|
-
def simulate(type,nesting,tid,parent,parameters={}) #{{{
|
364
|
-
@controller.vote("simulating/step",
|
365
|
-
:'activity-uuid' => @handler_activity_uuid,
|
366
|
-
:label => @label,
|
367
|
-
:activity => tid,
|
368
|
-
:endpoint => @handler_endpoint,
|
369
|
-
:type => type,
|
370
|
-
:nesting => nesting,
|
371
|
-
:parent => parent,
|
372
|
-
:parameters => parameters
|
373
|
-
)
|
374
360
|
end #}}}
|
375
361
|
end
|
@@ -68,24 +68,6 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
68
68
|
@guard_items = []
|
69
69
|
end # }}}
|
70
70
|
|
71
|
-
def prepare(readonly, endpoints, parameters) #{{{
|
72
|
-
@handler_endpoint = endpoints.is_a?(Array) ? endpoints.map{ |ep| readonly.endpoints[ep] }.compact : readonly.endpoints[endpoints]
|
73
|
-
if @controller.attributes['twin_engine']
|
74
|
-
@handler_endpoint_orig = @handler_endpoint
|
75
|
-
@handler_endpoint = @controller.attributes['twin_engine'].to_s + '?original_endpoint=' + Riddl::Protocols::Utils::escape(@handler_endpoint)
|
76
|
-
end
|
77
|
-
params = parameters.dup
|
78
|
-
params[:arguments] = params[:arguments].dup if params[:arguments]
|
79
|
-
params[:arguments]&.map! do |ele|
|
80
|
-
t = ele.dup
|
81
|
-
if t.value.is_a?(Proc)
|
82
|
-
t.value = readonly.instance_exec &t.value
|
83
|
-
end
|
84
|
-
t
|
85
|
-
end
|
86
|
-
params
|
87
|
-
end #}}}
|
88
|
-
|
89
71
|
def additional #{{{
|
90
72
|
{
|
91
73
|
:attributes => @controller.attributes,
|
@@ -256,9 +238,9 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
256
238
|
true
|
257
239
|
end # }}}
|
258
240
|
|
259
|
-
def activity_uuid
|
241
|
+
def activity_uuid #{{{
|
260
242
|
@handler_activity_uuid
|
261
|
-
end
|
243
|
+
end #}}}
|
262
244
|
|
263
245
|
def inform_activity_done # {{{
|
264
246
|
@controller.notify("activity/done", :'activity-uuid' => @handler_activity_uuid, :endpoint => @handler_endpoint, :label => @label, :activity => @handler_position)
|
@@ -292,7 +274,7 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
292
274
|
@controller.vote("activity/syncing_before", :'activity-uuid' => @handler_activity_uuid, :endpoint => @handler_endpoint, :activity => @handler_position, :label => @label, :parameters => parameters)
|
293
275
|
end # }}}
|
294
276
|
|
295
|
-
def callback(result=nil,options={})
|
277
|
+
def callback(result=nil,options={}) #{{{
|
296
278
|
status, ret, headers = Riddl::Client.new(@controller.url_result_transformation).request 'put' => result
|
297
279
|
recv = if status >= 200 && status < 300
|
298
280
|
JSON::parse(ret[0].value.read)
|
@@ -318,7 +300,7 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
318
300
|
@controller.notify("activity/status", :'activity-uuid' => @handler_activity_uuid, :label => @label, :activity => @handler_position, :endpoint => @handler_endpoint, :status => options['CPEE_STATUS'])
|
319
301
|
end
|
320
302
|
if options['CPEE_UPDATE']
|
321
|
-
@handler_continue.continue WEEL::Signal::
|
303
|
+
@handler_continue.continue WEEL::Signal::UpdateAgain
|
322
304
|
else
|
323
305
|
@controller.cancel_callback(@handler_passthrough)
|
324
306
|
@handler_passthrough = nil
|
@@ -330,7 +312,7 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
330
312
|
@handler_continue.continue
|
331
313
|
end
|
332
314
|
end
|
333
|
-
end
|
315
|
+
end #}}}
|
334
316
|
|
335
317
|
def mem_guard() #{{{
|
336
318
|
@guard_files.delete_if do |p|
|
@@ -344,23 +326,37 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
344
326
|
GC.start
|
345
327
|
end #}}}
|
346
328
|
|
347
|
-
def
|
348
|
-
|
349
|
-
|
350
|
-
|
351
|
-
|
352
|
-
|
353
|
-
|
354
|
-
|
355
|
-
|
356
|
-
|
357
|
-
|
358
|
-
|
359
|
-
|
329
|
+
def prepare(struct, endpoints, parameters) #{{{
|
330
|
+
@handler_endpoint = endpoints.is_a?(Array) ? endpoints.map{ |ep| struct.endpoints[ep] }.compact : struct.endpoints[endpoints]
|
331
|
+
if @controller.attributes['twin_engine']
|
332
|
+
@handler_endpoint_orig = @handler_endpoint
|
333
|
+
@handler_endpoint = @controller.attributes['twin_engine'].to_s + '?original_endpoint=' + Riddl::Protocols::Utils::escape(@handler_endpoint)
|
334
|
+
end
|
335
|
+
params = parameters.dup
|
336
|
+
params[:arguments] = params[:arguments].dup if params[:arguments]
|
337
|
+
params[:arguments]&.map! do |ele|
|
338
|
+
t = ele.dup
|
339
|
+
if t.value.is_a?(WEEL::ProcString)
|
340
|
+
send = []
|
341
|
+
send.push Riddl::Parameter::Simple::new('code',t.value.code)
|
342
|
+
send.push Riddl::Parameter::Complex::new('dataelements','application/json', JSON::generate(struct.data))
|
343
|
+
send.push Riddl::Parameter::Complex::new('local','application/json', JSON::generate(struct.local)) if struct.local
|
344
|
+
send.push Riddl::Parameter::Complex::new('endpoints','application/json', JSON::generate(struct.endpoints))
|
345
|
+
send.push Riddl::Parameter::Complex::new('additional','application/json', JSON::generate(struct.additional))
|
346
|
+
|
347
|
+
status, ret, headers = Riddl::Client.new(@controller.url_code).request 'put' => send
|
348
|
+
recv = if status >= 200 && status < 300
|
349
|
+
ret[0].value
|
350
|
+
else
|
351
|
+
nil
|
352
|
+
end
|
353
|
+
t.value = recv
|
354
|
+
end
|
355
|
+
t
|
360
356
|
end
|
361
|
-
|
362
|
-
end
|
363
|
-
def
|
357
|
+
params
|
358
|
+
end #}}}
|
359
|
+
def test_condition(dataelements,endpoints,local,additional,code,args={}) #{{{
|
364
360
|
send = []
|
365
361
|
send.push Riddl::Parameter::Simple::new('code',code)
|
366
362
|
send.push Riddl::Parameter::Complex::new('dataelements','application/json', JSON::generate(dataelements))
|
@@ -374,9 +370,12 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
374
370
|
else
|
375
371
|
nil
|
376
372
|
end
|
373
|
+
recv = 'false' unless receive
|
374
|
+
recv = (recv == 'false' || recv == 'null' || recv == 'nil' ? false : true)
|
375
|
+
@controller.notify("gateway/decide", :instance_uuid => @controller.uuid, :code => code, :condition => recv)
|
377
376
|
recv
|
378
|
-
end
|
379
|
-
def manipulate(readonly,lock,dataelements,endpoints,status,local,additional,code,where,result=nil,options=nil)
|
377
|
+
end #}}}
|
378
|
+
def manipulate(readonly,lock,dataelements,endpoints,status,local,additional,code,where,result=nil,options=nil) #{{{
|
380
379
|
lock.synchronize do
|
381
380
|
send = []
|
382
381
|
send.push Riddl::Parameter::Simple::new('code',code)
|
@@ -410,22 +409,12 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
|
|
410
409
|
nil
|
411
410
|
end
|
412
411
|
end
|
413
|
-
end
|
412
|
+
end #}}}
|
414
413
|
|
415
|
-
def
|
414
|
+
def split_branches(branches) # factual, so for inclusive or [[a],[b],[c,d,e]]{{{
|
415
|
+
@controller.notify("gateway/split", :instance_uuid => @controller.uuid, :branches => branches)
|
416
|
+
end #}}}
|
417
|
+
def join_branches(branches) # factual, so for inclusive or [[a],[b],[c,d,e]]{{{
|
416
418
|
@controller.notify("gateway/join", :instance_uuid => @controller.uuid, :branches => branches)
|
417
|
-
end
|
418
|
-
|
419
|
-
def simulate(type,nesting,tid,parent,parameters={}) #{{{
|
420
|
-
@controller.vote("simulating/step",
|
421
|
-
:'activity-uuid' => @handler_activity_uuid,
|
422
|
-
:label => @label,
|
423
|
-
:activity => tid,
|
424
|
-
:endpoint => @handler_endpoint,
|
425
|
-
:type => type,
|
426
|
-
:nesting => nesting,
|
427
|
-
:parent => parent,
|
428
|
-
:parameters => parameters
|
429
|
-
)
|
430
419
|
end #}}}
|
431
420
|
end
|
data/server/resources/topics.xml
CHANGED
data/server/routing/end.pid
CHANGED
@@ -1 +1 @@
|
|
1
|
-
|
1
|
+
2750515
|
@@ -1 +1 @@
|
|
1
|
-
|
1
|
+
2750534
|
@@ -1 +1 @@
|
|
1
|
-
|
1
|
+
2750527
|
data/server/routing/persist.pid
CHANGED
@@ -1 +1 @@
|
|
1
|
-
|
1
|
+
2750521
|
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.
|
4
|
+
version: 2.1.64
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Juergen eTM Mangler
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: tools
|
12
12
|
cert_chain: []
|
13
|
-
date: 2024-09-
|
13
|
+
date: 2024-09-18 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: riddl
|
@@ -35,7 +35,7 @@ dependencies:
|
|
35
35
|
version: '1.99'
|
36
36
|
- - ">="
|
37
37
|
- !ruby/object:Gem::Version
|
38
|
-
version: 1.99.
|
38
|
+
version: 1.99.123
|
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.
|
48
|
+
version: 1.99.123
|
49
49
|
- !ruby/object:Gem::Dependency
|
50
50
|
name: highline
|
51
51
|
requirement: !ruby/object:Gem::Requirement
|
@@ -165,6 +165,9 @@ dependencies:
|
|
165
165
|
- - "~>"
|
166
166
|
- !ruby/object:Gem::Version
|
167
167
|
version: '1.0'
|
168
|
+
- - ">="
|
169
|
+
- !ruby/object:Gem::Version
|
170
|
+
version: 1.0.1
|
168
171
|
type: :runtime
|
169
172
|
prerelease: false
|
170
173
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -172,6 +175,9 @@ dependencies:
|
|
172
175
|
- - "~>"
|
173
176
|
- !ruby/object:Gem::Version
|
174
177
|
version: '1.0'
|
178
|
+
- - ">="
|
179
|
+
- !ruby/object:Gem::Version
|
180
|
+
version: 1.0.1
|
175
181
|
description: see http://cpee.org
|
176
182
|
email: juergen.mangler@gmail.com
|
177
183
|
executables:
|
@@ -264,6 +270,7 @@ files:
|
|
264
270
|
- cockpit/templates.legacy/convert_preset.rb
|
265
271
|
- cockpit/templates.legacy/testsets.xml
|
266
272
|
- cockpit/templates.legacy/transformations.xml
|
273
|
+
- cockpit/templates/Coopis 2010 Ext.xml
|
267
274
|
- cockpit/templates/Coopis 2010.xml
|
268
275
|
- cockpit/templates/Frames.xml
|
269
276
|
- cockpit/templates/IUPC arXiv:1104.3609 P34 1.xml
|