wasabi 3.8.0 → 5.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +40 -30
- data/lib/wasabi/parser.rb +7 -5
- data/lib/wasabi/resolver.rb +5 -5
- data/lib/wasabi/version.rb +1 -1
- metadata +11 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 88ab30cac89a56f90092e8797f88b2ad6065e0401631fe6ac2122f186201dfca
|
4
|
+
data.tar.gz: 633de7398ec6c08ca2f225f6bbc5ae4b90def8b8d741aa30843cfb0c23b1322f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 29cb6dbc6ffa1ee29d78ef0edd15c3bbc44bc1398a899d4eebecc0e3ac1e6a9dd539023a48d235cc97f92e11bbbbd3bc1953f85c9d0608050a8d58c5a640b566
|
7
|
+
data.tar.gz: a5d1840f111d05cd56b09c077cfeffdb985d77d9d697e681bcf4f452bc82d53321ace0e40adc762b1e597b651d3738f5c9d01b42c267df1e98e0c579ad78dc1f
|
data/CHANGELOG.md
CHANGED
@@ -4,6 +4,16 @@
|
|
4
4
|
|
5
5
|
- _Your new line here. Mind the style of prefix used in the rest of the document._
|
6
6
|
|
7
|
+
## 5.0.0 (2024-01-08)
|
8
|
+
|
9
|
+
- Drop support for unsupported rubies (2.7 and below)
|
10
|
+
- Update to be compatible with Faraday ([#116](https://github.com/savonrb/wasabi/pull/116))
|
11
|
+
|
12
|
+
## 4.0.0 (2023-03-27)
|
13
|
+
|
14
|
+
- Formally drop support for unsupported rubies (2.6 and below)
|
15
|
+
- Parse Input/Output When Operation Style is Document ([#114](https://github.com/savonrb/wasabi/pull/114))
|
16
|
+
|
7
17
|
## 3.8.0 (2022-10-01)
|
8
18
|
|
9
19
|
- Change: Update HTTPI to 3.0 to remove the socksify dependency. ([savonrb/httpi#225](https://github.com/savonrb/httpi/pull/225))
|
@@ -23,7 +33,7 @@
|
|
23
33
|
|
24
34
|
- Add: Support RPC-encoded WSDL ([#63](https://github.com/savonrb/wasabi/pull/63), [@fernandes][])
|
25
35
|
- Fix: Depend on [addressable](https://github.com/sporkmonger/addressable), for unescape to avoid a Ruby warning ([#81](https://github.com/savonrb/wasabi/pull/81) , [@chaymaeBZ][], [@bvicenzo][])
|
26
|
-
- Fix: [#59](https://github.com/savonrb/wasabi/
|
36
|
+
- Fix: [#59](https://github.com/savonrb/wasabi/pull/59) Turn `String` monkeypatches into `Wasabi` class methods ([@tjarratt][]) (released this version)
|
27
37
|
- Change: Reduced size of gem by focusing the files list ([#89](https://github.com/savonrb/wasabi/pull/89), [@utkarsh2102][])
|
28
38
|
- Remove: No longer tested on Rubinius
|
29
39
|
|
@@ -31,99 +41,99 @@
|
|
31
41
|
|
32
42
|
NB: This version was never released to RubyGems.org.
|
33
43
|
|
34
|
-
|
44
|
+
- Fix: [#59](https://github.com/savonrb/wasabi/pull/59) Stop monkey patching the String class to provide #snakecase
|
35
45
|
|
36
46
|
## 3.5.0 (2015-03-31)
|
37
47
|
|
38
|
-
|
48
|
+
- Formally drop support for ruby 1.8.7
|
39
49
|
|
40
50
|
## 3.4.0 (2015-03-02)
|
41
51
|
|
42
|
-
|
52
|
+
- Fix: [#634](https://github.com/savonrb/savon/issues/634) Reverts PR #46, generates *most* operation names correctly.
|
43
53
|
|
44
54
|
## 3.3.1 (2014-09-25)
|
45
55
|
|
46
|
-
|
56
|
+
- Fix: [#48](https://github.com/savonrb/wasabi/issues/48) Remove dependency on mime-type gem
|
47
57
|
|
48
58
|
## 3.3.0 (2014-05-03)
|
49
|
-
|
59
|
+
- Feature: [#44](https://github.com/savonrb/wasabi/pull/44) adds a feature to specify the HTTPI adapter you'd like to use.
|
50
60
|
|
51
61
|
## 3.2.3 (2013-12-16)
|
52
|
-
|
62
|
+
- Fix [#39](https://github.com/savonrb/wasabi/pull/39) fixes new regression in operation names. Huge thank you to #leoping for investigating this and issuing a pull request.
|
53
63
|
|
54
64
|
## 3.2.2 (2013-12-09)
|
55
65
|
|
56
|
-
|
66
|
+
- Fix: [#32](https://github.com/savonrb/wasabi/issues/32) fixes a regression in operation names that was adversely affecting Savon: https://github.com/savonrb/savon/issues/520
|
57
67
|
|
58
68
|
## 3.2.1 (2013-12-05)
|
59
69
|
|
60
|
-
|
70
|
+
- Feature: Drops requirement for Nokogiri <= 1.6 for modern rubies. This was in place for ruby 1.8 but since support for that is going away, we shouldn't prevent users from using newer versions of Nokogiri.
|
61
71
|
|
62
72
|
## 3.2.0 (2013-07-26)
|
63
73
|
|
64
|
-
|
74
|
+
- Feature: [#20](https://github.com/savonrb/wasabi/issues/20) Limited support for listing an
|
65
75
|
operation's parameters. Please note that if your WSDL defines imports, this method might
|
66
76
|
not return all types.
|
67
77
|
|
68
|
-
|
78
|
+
- Improvement: [#7](https://github.com/savonrb/wasabi/issues/7) Major speed improvements.
|
69
79
|
|
70
|
-
|
80
|
+
- Improvement: [#16](https://github.com/savonrb/wasabi/issues/16) Various improvements regarding
|
71
81
|
element order and type information.
|
72
82
|
|
73
|
-
|
83
|
+
- Fix: [#25](https://github.com/savonrb/wasabi/issues/25) Fixes a problem where Wasabi escaped
|
74
84
|
an already escaped endpoint URL.
|
75
85
|
|
76
|
-
|
86
|
+
- Fix: [#15](https://github.com/savonrb/wasabi/issues/15) Fixes a bug where the operation tag
|
77
87
|
name was not correctly extracted from the WSDL document.
|
78
88
|
|
79
89
|
## 3.1.0 (2013-04-21)
|
80
90
|
|
81
|
-
|
91
|
+
- Feature: [#22](https://github.com/savonrb/wasabi/issues/22) added `Wasabi::Document#service_name`
|
82
92
|
to return the name of the SOAP service. Original issue: [savonrb/savon#408](https://github.com/savonrb/savon/pull/408).
|
83
93
|
|
84
|
-
|
94
|
+
- Fix: [#21](https://github.com/savonrb/wasabi/issues/21) when the Resolver gets an
|
85
95
|
erroneous response (such as a 404), we now raise a more useful HTTPError.
|
86
96
|
|
87
|
-
|
97
|
+
- Fix: [#23](https://github.com/savonrb/wasabi/issues/23) ignore extension base elements
|
88
98
|
defined in imports.
|
89
99
|
|
90
100
|
## 3.0.0 (2012-12-17)
|
91
101
|
|
92
|
-
|
102
|
+
- Updated to HTTPI 2.0 to play nicely with Savon 2.0.
|
93
103
|
|
94
104
|
## 2.5.1 (2012-08-22)
|
95
105
|
|
96
|
-
|
106
|
+
- Fix: [#14](https://github.com/savonrb/wasabi/issues/14) fixes an issue where
|
97
107
|
finding the correct SOAP input tag and namespace identifier fails when portTypes
|
98
108
|
are imported, since imports are currently not supported.
|
99
109
|
|
100
110
|
The bug was introduced in v2.2.0 by [583cf6](https://github.com/savonrb/wasabi/commit/583cf658f1953411a7a7a4c22923fa0a046c8d6d)
|
101
111
|
|
102
|
-
|
112
|
+
- Refactoring: Removed `Object#blank?` core extension.
|
103
113
|
|
104
114
|
## 2.5.0 (2012-06-28)
|
105
115
|
|
106
|
-
|
116
|
+
- Fix: [#10](https://github.com/savonrb/wasabi/issues/10) fixes an issue where
|
107
117
|
Wasabi used the wrong operation name.
|
108
118
|
|
109
119
|
## 2.4.1 (2012-06-18)
|
110
120
|
|
111
|
-
|
121
|
+
- Fix: [savonrb/savon#296](https://github.com/savonrb/savon/issues/296) fixes an issue where
|
112
122
|
the WSDL message element doesn't have part element.
|
113
123
|
|
114
124
|
## 2.4.0 (2012-06-08)
|
115
125
|
|
116
|
-
|
126
|
+
- Feature: `Wasabi::Document` now accepts either a URL of a remote document,
|
117
127
|
a path to a local file or raw XML. The code for this was moved from Savon over
|
118
128
|
here as a first step towards supporting WSDL imports.
|
119
129
|
|
120
130
|
## 2.3.0 (2012-06-07)
|
121
131
|
|
122
|
-
|
132
|
+
- Improvement: [#3](https://github.com/savonrb/wasabi/pull/3) adds object inheritance.
|
123
133
|
|
124
134
|
## 2.2.0 (2012-06-06)
|
125
135
|
|
126
|
-
|
136
|
+
- Improvement: [#5](https://github.com/savonrb/wasabi/pull/5) - Get input from message
|
127
137
|
element or portType input. See [savonrb/savon#277](https://github.com/savonrb/savon/pull/277)
|
128
138
|
to get the full picture on how this all works together, and enables you to pass a single
|
129
139
|
symbol into the `Savon::Client#request` method and get automatic namespace mapping, as well
|
@@ -131,23 +141,23 @@ NB: This version was never released to RubyGems.org.
|
|
131
141
|
|
132
142
|
## 2.1.1 (2012-05-18)
|
133
143
|
|
134
|
-
|
144
|
+
- Fix: [issue 7](https://github.com/savonrb/wasabi/issues/7) - Performance regression.
|
135
145
|
|
136
146
|
## 2.1.0 (2012-02-17)
|
137
147
|
|
138
|
-
|
148
|
+
- Improvement: The value of elementFormDefault can now be manually specified/overwritten.
|
139
149
|
|
140
|
-
|
150
|
+
- Improvement: [issue 2](https://github.com/savonrb/wasabi/issues/2) - Allow symbolic endpoints
|
141
151
|
like "http://server:port".
|
142
152
|
|
143
153
|
## 2.0.0 (2011-07-07)
|
144
154
|
|
145
|
-
|
155
|
+
- Feature: Wasabi can now parse type definitions and namespaces.
|
146
156
|
Thanks to [jkingdon](https://github.com/jkingdon) for implementing this.
|
147
157
|
|
148
158
|
## 1.0.0 (2011-07-03)
|
149
159
|
|
150
|
-
|
160
|
+
- Initial version extracted from the [Savon](http://rubygems.org/gems/savon) library.
|
151
161
|
Use it to build your own SOAP client and help to improve it!
|
152
162
|
|
153
163
|
[@fernandes]: https://github.com/fernandes
|
data/lib/wasabi/parser.rb
CHANGED
@@ -144,8 +144,9 @@ module Wasabi
|
|
144
144
|
# TODO: check for soap namespace?
|
145
145
|
soap_operation = operation.element_children.find { |node| node.name == 'operation' }
|
146
146
|
soap_action = soap_operation['soapAction'] if soap_operation
|
147
|
+
soap_document = soap_operation["style"] if soap_operation
|
147
148
|
|
148
|
-
if soap_action
|
149
|
+
if soap_action || soap_document
|
149
150
|
soap_action = soap_action.to_s
|
150
151
|
action = soap_action && !soap_action.empty? ? soap_action : name
|
151
152
|
|
@@ -247,8 +248,7 @@ module Wasabi
|
|
247
248
|
port_type_operation = @port_type_operations[binding_type][operation_name]
|
248
249
|
end
|
249
250
|
|
250
|
-
port_type_input_output = port_type_operation
|
251
|
-
port_type_operation.element_children.find { |node| node.name == input_output }
|
251
|
+
port_type_input_output = port_type_operation&.element_children&.find { |node| node.name == input_output }
|
252
252
|
|
253
253
|
# TODO: Stupid fix for missing support for imports.
|
254
254
|
# Sometimes portTypes are actually included in a separate WSDL.
|
@@ -260,6 +260,8 @@ module Wasabi
|
|
260
260
|
end
|
261
261
|
|
262
262
|
message_ns_id, message_type = nil
|
263
|
+
message_ns_id = port_message_ns_id
|
264
|
+
message_type = port_message_type
|
263
265
|
|
264
266
|
# When there is a parts attribute in soap:body element, we should use that value
|
265
267
|
# to look up the message part from messages array.
|
@@ -270,8 +272,8 @@ module Wasabi
|
|
270
272
|
end
|
271
273
|
|
272
274
|
message = @messages[port_message_type]
|
273
|
-
port_message_part = message
|
274
|
-
soap_body_parts.nil? ? (node.name ==
|
275
|
+
port_message_part = message&.element_children&.find do |node|
|
276
|
+
soap_body_parts.nil? ? (node.name == "part") : (node.name == "part" && node["name"] == soap_body_parts)
|
275
277
|
end
|
276
278
|
|
277
279
|
if port_message_part && port_element = port_message_part.attribute('element')
|
data/lib/wasabi/resolver.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
require "
|
3
|
+
require "faraday"
|
4
4
|
|
5
5
|
module Wasabi
|
6
6
|
|
@@ -22,7 +22,7 @@ module Wasabi
|
|
22
22
|
|
23
23
|
def initialize(document, request = nil, adapter = nil)
|
24
24
|
@document = document
|
25
|
-
@request = request ||
|
25
|
+
@request = request || Faraday.new
|
26
26
|
@adapter = adapter
|
27
27
|
end
|
28
28
|
|
@@ -41,10 +41,10 @@ module Wasabi
|
|
41
41
|
private
|
42
42
|
|
43
43
|
def load_from_remote
|
44
|
-
request.
|
45
|
-
response =
|
44
|
+
request.adapter *adapter if adapter
|
45
|
+
response = request.get(document)
|
46
46
|
|
47
|
-
raise HTTPError.new("Error: #{response.
|
47
|
+
raise HTTPError.new("Error: #{response.status} for url #{document}", response) unless response.success?
|
48
48
|
|
49
49
|
response.body
|
50
50
|
end
|
data/lib/wasabi/version.rb
CHANGED
metadata
CHANGED
@@ -1,43 +1,43 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: wasabi
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 5.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel Harrington
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-01-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
|
-
name:
|
14
|
+
name: faraday
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '
|
19
|
+
version: '2.8'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '
|
26
|
+
version: '2.8'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: nokogiri
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 1.
|
33
|
+
version: 1.13.9
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: 1.
|
40
|
+
version: 1.13.9
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: addressable
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -73,9 +73,10 @@ licenses:
|
|
73
73
|
- MIT
|
74
74
|
metadata:
|
75
75
|
changelog_uri: https://github.com/savonrb/wasabi/blob/master/CHANGELOG.md
|
76
|
-
documentation_uri: https://www.rubydoc.info/gems/wasabi/
|
76
|
+
documentation_uri: https://www.rubydoc.info/gems/wasabi/5.0.0
|
77
77
|
source_code_uri: https://github.com/savonrb/wasabi
|
78
78
|
bug_tracker_uri: https://github.com/savonrb/wasabi/issues
|
79
|
+
rubygems_mfa_required: 'true'
|
79
80
|
post_install_message:
|
80
81
|
rdoc_options: []
|
81
82
|
require_paths:
|
@@ -84,14 +85,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
84
85
|
requirements:
|
85
86
|
- - ">="
|
86
87
|
- !ruby/object:Gem::Version
|
87
|
-
version:
|
88
|
+
version: '3.0'
|
88
89
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
89
90
|
requirements:
|
90
91
|
- - ">="
|
91
92
|
- !ruby/object:Gem::Version
|
92
93
|
version: '0'
|
93
94
|
requirements: []
|
94
|
-
rubygems_version: 3.3.
|
95
|
+
rubygems_version: 3.3.26
|
95
96
|
signing_key:
|
96
97
|
specification_version: 4
|
97
98
|
summary: A simple WSDL parser
|