cpee-instantiation 1.0 → 1.0.1

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: 4da02ad96d0a1feb31755f5217286eed93f5f1beabe3f535a7d749ab55eb8cb3
4
- data.tar.gz: 6b9b6f3ad0f463f050a81759f0685eea7ac69d57f282ec8c9b1f83a0a5bce17f
3
+ metadata.gz: a8179be00caf9485a82cc72f3180439fa8db27a45ee8ff58b7e642534e7397aa
4
+ data.tar.gz: 1d9b5a792f4a95a35c5368c78ba03134ed84a751e873c10751771297998aaf2a
5
5
  SHA512:
6
- metadata.gz: 48cfa7f1a307aabe48cfa73b08d0e9a0d79dc989ecaf30a2d4c871dffe6fcdfd6bb4563bec9da70d2c44c07efe248fe6f2d2a450c96eae47f0d89a791c9852b3
7
- data.tar.gz: 885d19ca953bd56e72cf43ea2fe27ea98f3575a0689dc37293b9f0348111d2735a91fbc909f98d541030308eea4278d631667e24b966baa569000e85fad43af0
6
+ metadata.gz: 852d8a607287b4dfd197c45386ebc9d83bdead3428e454736341586a7166088ac12044000714e91f181c286d8d282c86908b089e9a8a047a2be580f071a29616
7
+ data.tar.gz: 60982f32ca0a4ebef7628de4b8f444022071ae437b8494e6bef310c6e2bf7a1c70fe65fb527fe1ce444a7e40e67228b6440c89f5c9da58d7a62fc083253fa87e
data/README.md CHANGED
@@ -7,9 +7,9 @@ To install the instatiation service go to the commandline
7
7
  cpee-instantiation instantiation
8
8
  cd instantiation
9
9
  ./instantiation start
10
- ```
10
+ ```
11
11
 
12
- The service is running under port 9296. If this port has to be changed (or the
12
+ The service is running under port 9296. If this port has to be changed (or the
13
13
  host, or local-only access, ...), create a file instatiation.conf and add one
14
14
  or many of the following yaml keys:
15
15
 
@@ -28,7 +28,7 @@ To use the service try one of the following:
28
28
  curl -X POST -H "Content-Type: application/x-www-form-urlencoded" -d "behavior=wait_running&url=http%3A%2F%2Flink%2Fto%2Ftestset.xml" http://localhost:9296/url
29
29
  curl -X POST -H "Content-Type: application/x-www-form-urlencoded" -d "behavior=fork_running&url=http%3A%2F%2Flink%2Fto%2Ftestset.xml&init=%7B%20%22a%22%3A%2037%2C%20%22b%22%3A%20%22test%22%20%7D" http://localhost:9296/url
30
30
  curl -X POST -F "behavior=wait_running" -F "xml=@testset.xml" http://localhost:9296/xml
31
- ```
31
+ ```
32
32
 
33
33
  The behavior can be either: the process parent process is waiting (wait_) or is
34
34
  running in parallel (fork_), the subprocesss is either immediately starting
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = "cpee-instantiation"
3
- s.version = "1.0"
3
+ s.version = "1.0.1"
4
4
  s.platform = Gem::Platform::RUBY
5
5
  s.license = "LGPL-3.0"
6
6
  s.summary = "Subprocess instantiation service for the cloud process execution engine (cpee.org)"
@@ -37,7 +37,7 @@ module CPEE
37
37
  doc.register_namespace 'desc', 'http://cpee.org/ns/description/1.0'
38
38
  doc.register_namespace 'prop', 'http://cpee.org/ns/properties/2.0'
39
39
 
40
- srv = Riddl::Client.new(cpee, cpee + '?riddl-description')
40
+ srv = Riddl::Client.new(cpee, File.join(cpee,'?riddl-description'))
41
41
  res = srv.resource('/')
42
42
  if name
43
43
  doc.find('/*/prop:attributes/prop:info').each do |e|
@@ -101,7 +101,7 @@ module CPEE
101
101
 
102
102
  if cb
103
103
  cbk = SecureRandom.uuid
104
- srv = Riddl::Client.new(cpee, cpee + '?riddl-description')
104
+ srv = Riddl::Client.new(cpee, File.join(cpee,'?riddl-description'))
105
105
  status, response = srv.resource("/#{instance}/notifications/subscriptions/").post [
106
106
  Riddl::Parameter::Simple.new('url',File.join(selfurl,'callback',cbk)),
107
107
  Riddl::Parameter::Simple.new('topic','state'),
@@ -118,7 +118,7 @@ module CPEE
118
118
  private :handle_waiting
119
119
  def handle_starting(cpee,instance,behavior) #{{{
120
120
  if behavior =~ /_running$/
121
- srv = Riddl::Client.new(cpee, cpee + '?riddl-description')
121
+ srv = Riddl::Client.new(cpee, File.join(cpee,'?riddl-description'))
122
122
  res = srv.resource("/#{instance}/properties/state")
123
123
  status, response = res.put [
124
124
  Riddl::Parameter::Simple.new('value','running')
@@ -132,7 +132,7 @@ module CPEE
132
132
  JSON::parse(data).each do |k,v|
133
133
  content.root.add(k,v)
134
134
  end
135
- srv = Riddl::Client.new(cpee, cpee + "?riddl-description")
135
+ srv = Riddl::Client.new(cpee, File.join(cpee,'?riddl-description'))
136
136
  res = srv.resource("/#{instance}/properties/dataelements/")
137
137
  status, response = res.patch [
138
138
  Riddl::Parameter::Complex.new('dataelements','text/xml',content.to_s)
@@ -145,7 +145,7 @@ module CPEE
145
145
  JSON::parse(data).each do |k,v|
146
146
  content.root.add(k,v)
147
147
  end
148
- srv = Riddl::Client.new(cpee, cpee + "?riddl-description")
148
+ srv = Riddl::Client.new(cpee, File.join(cpee,'?riddl-description'))
149
149
  res = srv.resource("/#{instance}/properties/endpoints/")
150
150
  status, response = res.patch [
151
151
  Riddl::Parameter::Complex.new('endpoints','text/xml',content.to_s)
@@ -271,7 +271,7 @@ module CPEE
271
271
  cblist = @a[2]
272
272
  instance = @p[1].value
273
273
 
274
- srv = Riddl::Client.new(cpee, cpee + "?riddl-description")
274
+ srv = Riddl::Client.new(cpee, File.join(cpee,'?riddl-description'))
275
275
  res = srv.resource("/#{instance}/properties/attributes/uuid")
276
276
  status, response = res.get
277
277
 
@@ -310,7 +310,7 @@ module CPEE
310
310
 
311
311
  if notification['content']['state'] == condition
312
312
  cblist.del(key)
313
- srv = Riddl::Client.new(cpee, cpee + "?riddl-description")
313
+ srv = Riddl::Client.new(cpee, File.join(cpee,'?riddl-description'))
314
314
  res = srv.resource("/#{instance}/properties/dataelements")
315
315
  status, response = res.get
316
316
  if status >= 200 && status < 300
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cpee-instantiation
3
3
  version: !ruby/object:Gem::Version
4
- version: '1.0'
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Juergen eTM Mangler
8
8
  autorequire:
9
9
  bindir: tools
10
10
  cert_chain: []
11
- date: 2020-09-28 00:00:00.000000000 Z
11
+ date: 2020-10-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: riddl