soar_sr 0.1.7 → 0.1.8

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +126 -16
  3. data/lib/soar_sr/version.rb +1 -1
  4. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 7a81f40d80e885c259c37c7634558069df0eea50
4
- data.tar.gz: ca96964491c938cbb08ef2afb84cc70d0bb939aa
3
+ metadata.gz: a50576eb7396eb8cf8a40e9c7246934c6de0e297
4
+ data.tar.gz: 9039c07c746dbdbe0057436c657462f16ae434fd
5
5
  SHA512:
6
- metadata.gz: f8a94c966ac25a99fbf580a5949279d8ec8c823e8aba206dad8364471d34a1dfa22cb3a10f43f0ef2b30a7fd77f133d606824d9d63ccea4312adc91593d7f44e
7
- data.tar.gz: 24b7d84430cfa5b489079e53aa8f5d547e66b507ef8dd2771d051c7e3558d7cb7bc7d95b4178b4fe6ae0d91c8ae92d95885cc3db697d463a9fbb15d685b84ba6
6
+ metadata.gz: 98fecb4c6ad7136fc2a1bec412cf11be01b5004291370fad816c0858b75bed646e870dc7e3ebc96bbf3381e3cfa13d4aa3853290e47418dd82d0417787347f80
7
+ data.tar.gz: c3ae094887243bef158adc52da348a2a66afe1e797e8d91581e495772c2c5add21e0898eb8b95a0dbe37205de7f17964542b92e212f244d12354757e95ff84ea
data/README.md CHANGED
@@ -1,38 +1,148 @@
1
1
  # SoarSr
2
2
 
3
- Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/soar_sr`. To experiment with that code, run `bin/console` for an interactive prompt.
3
+ SoarSr is a client library for accessing the features of a jUDDI registry. SoarSr translates jUDDI concepts into a SOA architectural view on UDDI storage. Services are concise singly responsible functional units. Service components are devices and application servers that offer services on a URI. Domain perspectives are functional grouping of services et al in pursuit of business goals. Teams are a kind of domain perspective. Services are described by wadl service definitions. Associating services or service components with domain perspectvice indicates functional association. Associating services or service components with teams indicate ownership. Domain perspectives (and so also teams) have one or more contacts associated.
4
4
 
5
- TODO: Delete this and the text above, and describe your gem
5
+ This is accomplished by translating as follows:
6
+
7
+ Teams and Domain perspectives => jUDDI businesses
8
+ Service components and services => jUDDI services
9
+ Associations => ruby Hashes, url encoded in an entity's description
6
10
 
7
11
  ## Installation
8
12
 
9
13
  Add this line to your application's Gemfile:
10
14
 
11
- ```ruby
12
- gem 'soar_sr'
13
- ```
15
+ gem 'soar_sr'
14
16
 
15
17
  And then execute:
16
18
 
17
- $ bundle
19
+ bundle
18
20
 
19
21
  Or install it yourself as:
20
22
 
21
- $ gem install soar_sr
23
+ gem install soar_sr
22
24
 
23
25
  ## Usage
24
-
25
- TODO: Write usage instructions here
26
-
27
- ## Development
28
-
29
- After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
30
-
31
- To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
26
+ spec.add_development_dependency 'soar_sr'
27
+ bundle exec irb
28
+
29
+ ### Helpers
30
+ require 'soar_sr'
31
+ credentials = { 'username' => 'uddi', 'password' => 'uddi' }
32
+ freshness = 0 # > 0 to enable cache
33
+ @soar_sr = SoarSr::ServiceRegistry.new('http://localhost:8080', 'hetzner.co.za', 'hetzner', credentials, freshness)
34
+ ds = @soar_sr.domain_perspectives
35
+ sv = @soar_sr.services
36
+ sc = @soar_sr.service_components
37
+ sd = @soar_sr.service_definitions
38
+ ts = @soar_sr.teams
39
+ cc = @soar_sr.contacts
40
+ as = @soar_sr.associations
41
+ ss = @soar_sr.search
42
+
43
+ ### Domain perspectives
44
+ ds.delete_all_domain_perspectives
45
+ ds.list_domain_perspectives
46
+ ds.domain_perspective_by_name('domains', 'my domain')
47
+ ds.domain_perspective_registered?('my domain')
48
+ ds.register_domain_perspective('my domain')
49
+ ds.domain_perspective_registered?('my domain')
50
+ ds.deregister_domain_perspective('my domain')
51
+ ds.list_domain_perspectives
52
+
53
+ ### Services
54
+ sv.register_service({'name' => 'my service', 'description' => 'a new service', 'definition' => 'http://de.finiti.on'})
55
+ sv.service_registered?('my service')
56
+ sv.add_service_uri('my service', 'http://one-uri.com/my_service')
57
+ sv.add_service_uri('my service', 'http://find-me-here.com/my_service')
58
+ sv.remove_uri_from_service('my service', 'http://one-uri.com/my_service')
59
+ sv.service_uris('my service')
60
+ sv.configure_meta_for_service('my service', {'some' => 'meta'})
61
+ sv.meta_for_service('my service')
62
+ sv.service_by_name('my service')
63
+ sv.deregister_service('my service')
64
+ sv.service_by_name('my service')
65
+
66
+ ### Service components
67
+ sc.delete_all_service_components
68
+ sc.list_service_components
69
+ sc.register_service_component('my sc')
70
+ sc.service_component_registered?('my sc')
71
+ sc.configure_service_component_uri('my sc', 'http://my-sc.com')
72
+ sc.service_component_uri('my sc')
73
+ sc.deregister_service_component('my sc')
74
+ sc.service_component_registered?('my sc')
75
+
76
+ ### Service definitions
77
+ sv.register_service({'name' => 'my service', 'description' => 'a new service', 'definition' => 'http://de.finiti.on'})
78
+ sd.service_definition_for_service('my service')
79
+ sd.deregister_service_definition('my service')
80
+ sd.service_definition_for_service('my service')
81
+ sd.register_service_definition('my service', 'http://github.com/myservice/def.wadl')
82
+ sd.service_definition_for_service('my service')
83
+
84
+ ### Teams
85
+ ts.team_registered?('my team')
86
+ ts.register_team('my team')
87
+ ds.domain_perspective_by_name('teams', 'my team')
88
+ ts.team_registered?('my team')
89
+ ts.deregister_team('my team')
90
+ ts.team_registered?('my team')
91
+
92
+ ### Contacts
93
+ contact = { 'name' => 'Peter Umpkin', 'email' => 'p.umpkin@ppatch.com', 'description' => 'Director of operations', 'phone' => '0917872413'}
94
+ contact2 = { 'name' => 'Bruce Atman', 'email' => 'b.atman@marvelling.com', 'description' => 'Head of sales'}
95
+ ds.register_domain_perspective('my domain')
96
+ cc.add_contact_to_domain_perspective('my domain', contact)
97
+ cc.add_contact_to_domain_perspective('my domain', contact2)
98
+ cc.contact_details_for_domain('my domain')
99
+ cc.remove_contact_from_domain_perspective('my domain', contact)
100
+ ts.register_team('my team')
101
+ cc.add_contact_to_domain_perspective('my team', contact2)
102
+ cc.contact_details_for_domain('my team')
103
+
104
+ ### Associations
105
+ ds.register_domain_perspective('my domain')
106
+ as.delete_all_domain_perspective_associations('my domain')
107
+ sc.register_service_component('my sc')
108
+ as.associate_service_component_with_domain_perspective('my sc', 'my domain')
109
+ as.service_component_has_domain_perspective_associations?('my sc')
110
+ as.domain_perspective_associations('my domain')
111
+ as.domain_perspective_has_associations?('my domain')
112
+ as.disassociate_service_component_from_domain_perspective('my domain', 'my sc')
113
+ as.service_component_has_domain_perspective_associations?('my sc')
114
+ as.domain_perspective_has_associations?('my domain')
115
+
116
+ ds.register_domain_perspective('my domain')
117
+ as.delete_all_domain_perspective_associations('my domain')
118
+ sv.register_service({'name' => 'my service', 'description' => 'a new service', 'definition' => 'http://de.finiti.on'})
119
+ as.associate_service_with_domain_perspective('my service', 'my domain')
120
+ as.domain_perspective_has_associations?('my domain')
121
+ as.domain_perspective_associations('my domain')
122
+ as.disassociate_service_from_domain_perspective('my domain', 'my service')
123
+ as.domain_perspective_associations('my domain')
124
+
125
+ ### Search
126
+ sv.register_service({'name' => 'search me', 'description' => 'pretty please', 'definition' => 'http://de.finiti.on'})
127
+ sv.add_service_uri('search me', 'https://this.is.another.one/ybo')
128
+ sv.add_service_uri('search me', 'http://some.where.net/smoothies')
129
+ sv.service_uris('search me')
130
+ sv.remove_uri_from_service('search me', 'https://this.is.another.one/ybo')
131
+ ss.search_for_service('search')
132
+ ss.search_for_service('please')
133
+ ss.search_for_service('ti.on')
134
+ ds.register_domain_perspective('my domain')
135
+ as.associate_service_with_domain_perspective('search me', 'my domain')
136
+ ss.search_domain_perspective('my domain', 'search')
137
+ ss.search_domain_perspective('my domain', 'please')
138
+ ss.search_domain_perspective('my domain', 'ti.on')
139
+ ss.search_for_service_by_name('search')
140
+ ss.search_for_service_by_name('please')
141
+ ss.search_for_service_by_name('ti.on')
32
142
 
33
143
  ## Contributing
34
144
 
35
- Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/soar_sr. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](contributor-covenant.org) code of conduct.
145
+ Bug reports and feature requests are welcome by email to ernstv dot van dot graan at hetzner dot co dot za. This gem is sponsored by Hetzner (Pty) Ltd (http://hetzner.co.za)
36
146
 
37
147
 
38
148
  ## License
@@ -1,3 +1,3 @@
1
1
  module SoarSr
2
- VERSION = "0.1.7"
2
+ VERSION = "0.1.8"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: soar_sr
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.7
4
+ version: 0.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ernst van Graan
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2015-12-17 00:00:00.000000000 Z
11
+ date: 2015-12-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: persistent-cache