- MTOM attachment support by @ekzobrain in #1012
- Fix: request logging when message contains non-ascii characters
- Fix: when xml option is provided, attachments option was ignored
- Add your PR changelog line here
- Use Faraday instead of HTTPI
- BC BREAKING Cookies are handled differently now
- BC BREAKING Multiple pieces of functionality will rely on faraday libraries to be provided by the consuming codebase
- BC BREAKING Adapter overrides now utilize the faraday model
- BC BREAKING Multiple hard deprecations due to a lack of feature parity between Faraday and HTTPI
- Deprecates digest auth
- Deprecates ssl_cert_key_file auth, upgrade path is to read the key in and provide it
- Deprecates encrypted ssl keys, upgrade path is to decrypt the key and pass it to faraday in code
- Deprecates providing a ca cert, upgrade path is to provide a ca cert file
- deprecates overriding ssl ciphers, as faraday does not support this
- Ruby 3.0+ is required in the gemspec.
- Require httpi 4.x - older versions rely on
Rack::Utils::HeaderHash
which is removed in Rack 3.0.
- Drop support for ruby 2.7 and below. Added Ruby 3.2 and 3.3 to test matrix.
- Allows wasabi v5.x, which now supports faraday
- BC BREAKING Fix: #985 Renamed
Savon::Response#hash
toSavon::Response#full_hash
- BC BREAKING Fix: #988 Savon no longer monkeypatches
String#snakecase
- Fix: #989 Do not include xmlns from WSDL, which breaks some servers
- Fix: #977 Prevent "xmlns:xmlns" namespace but allow "xmlns" namespace.
- Change: Require Ruby 2.7.0+ in the gemspec. 0e0d695f
- Drop support for ruby 2.6 and below. Added Ruby 3.0 and 3.1 to test matrix.
- Fix: #868 Remove
xmlns:wsa
's already added elsewhere; select Content-Type HTTP header based on SOAP version. - Fix: #943 Read all namespaces from wsdl definition if document exists
- Feature: #920 Add a
write_timeout
setter for HTTP requests - Feature: #930 Add options for SSL min_version/max_version support
- Feature: #931 Add
log_headers
option
- Fix: #917 elementFormDefault="qualified" regression
- Fix: #875 Fix detecting Soap 1.1 Fault when faultcode and faultstring are empty
- Drop support for ruby 2.1 and below.
- Fix: #822 Raise correct error when SOAP envelope only contains a string
- Fix: #833 Fixes boolean handling regression introduced in 2.11.2
- Feature: #794, add global option ssl_ciphers.
- Feature: #753 Add headers configuration to WSDLRequest#build
- Feature: #812 Allow
proxy
option to benil
. - Feature: #838 Added ssl_ca_path and ssl_cert_store to globals
- Fix: #676 Fixes handling of
content!
andattributes!
- Fix: #800 Fix exception calling
SOAPFault#to_s
when http.body is empty - Fix: #757 Logging: Use filter without automatic pretty printing
- Fix: #771 Restore support for cookies when using custom headers
- Feature: #744 Add support for rpc encoded wsdl
- Feature: #742 Add support for local request headers
- Feature: #704 Add possibility to pass attribute delete_namespace_attributes to Nori
- Replace dependency on uuid, using SecureRandom.uuid instead.
- Formally drop support for 1.8.7.
- Feature: #673 Adds an :unwrap option that is passed to Gyoku.
- Fix: This reverts a purported "fix" to operation names.
- Feature: [#655] Wasabi exceptions should be rethrown as Savon errors. This should make it easier to catch errors thrown by Savon::Client.
- Feature: [#630] ServiceFaults are correctly identified as Soap Faults.
- Feature : #620 add #build_request method that builds the actual XML request body, but does not submit it. Useful for debugging, possibly.
- Fix : Loosened dependencies on Gyoku, Nori, Akami, and other Savon-dependency gems
- Feature: #636 Set HTTPI.logger when Savon's logger is configured.
- Feature: #639 Allow setting any SSL version that OpenSSL provides. See the relevant HTTPI issue for more information.
Fix : Preserve false values (#321)
- Fix : Fix a crash in builder when request headers do not contain WSA headers
- Feature: Signing requests. Added wsse_signature.
client = Savon.client(wsdl: 'http://service.example.com?wsdl') do
wsse_signature Akami::WSSE::Signature.new(Akami::WSSE::Certs.new(:cert_file => 'c.pem', :private_key_file => 'p.pem'))
end
-
Feature: #573 Add an
all_operations
method toSavon::Model
that automatically adds all available operations to the model. -
Feature: #566 Allow specifying HTTPI adapter per client.
curb_client = Savon.client(wsdl: "http://example.com/service.wsdl", adapter: :curb)
http_client = Savon.client(wsdl: "http://example.com/service.wsdl", adapter: :httpclient)
-
Logging is off by default. To enable this behavior, set the :log option to true
client = Savon.client(wsdl: "http://example.com/service.wsdl", log: true)
- Fix: #520 Fixes a regression in message tags in requests and responses.
- Removed dependency on Nokogiri <= 1.4 -- This improves support for ruby 1.9.3 and 2.0.0 and officially begins the end of support for ruby 1.8.7 See issue #487
Combined release ticket: #481
-
Feature: #405 Improved NTLM support based on HTTPI v2.1.0.
-
Feature: #424 Adds support for multipart responses through the updated savon-multipart gem. You can now specify
multipart: true
either as a global or local option. Please make sure you have the updatedsavon-multipart
gem installed and loaded, as it is not a direct dependency of Savon.require 'savon' require 'savon-multipart' # expect multipart responses for every operation client = Savon.client(wsdl: wsdl, multipart: true) # only expect a multipart response for this operation client.call(:my_operation, multipart: true)
-
Feature: #470 Added a local
:soap_header
option to allow setting the SOAP header per request. -
Feature: #402 Makes it possible to create mocks that don't care about the message sent by using
:any
for the:message
option.savon.expects(:authenticate).with(message: :any)
-
Fix: #450 Added
Savon::Response#soap_fault
andSavon::Response#http_error
which were present in version 1. -
Fix: #474 Changed
Savon::Response#header
andSavon::Response#body
to respect the global:convert_response_tags_to
and:strip_namespaces
options and return the expected result instead of raising aSavon::InvalidResponseError
. -
Fix: #461 Fixed two problems related to namespace qualified messages and the element
:order!
. -
Fix: #476 fixes a problem where the namespace for the message tag was not correctly determined from the WSDL.
-
Fix: #468 Changed the dependency on Nokogiri to < 1.6, because Nokogiri 1.6 dropped support for Ruby 1.8.
-
Feature: #416 The global
namespace_identifier
option can now be set tonil
to not add a namespace identifier to the message tag. -
Feature: #408 Added
Savon::Client#service_name
to return the name of the SOAP service. -
Improvement: When mistyping an option name, Savon used to raise a simple
NoMethodError
. This is because regardless of whether you're using the Hash or block syntax to pass global or local options, both are just method calls on some options object.NoMethodError: undefined method 'wsdk' for #<Savon::GlobalOptions:0x007fed95a55228>
As of this change, Savon now catches those errors and raise a
Savon::UnknownOptionError
with a slightly more helpful error message instead.Savon::UnknownOptionError: Unknown global option: :wsdk
-
Improvement: #385 Instead of raising an
ArgumentError
when Wasabi can't find any operations in the WSDL. Savon now raises aSavon::UnknownOperationError
. This might happen when Wasabi fails to parse the WSDL because of imports for example. -
Fix: #430 allows you to rescue and ignore
Savon::Error
errors in production while still having mocks trigger test failures. -
Fix: #393 changed
Savon::SOAPFault
to work with generic response Hash keys. -
Fix: #423 fixes a problem where Wasabi was not able to find extension base elements defined in imports it didn't follow.
-
Feature: #372 added global
ssl_cert_key_password
option. -
Feature: #361 added the local
:attributes
option to allow adding XML attributes to the SOAP message tag. -
Improvement: #363 Savon 2.0 remembers the cookies from the last response and passes it to the next request, which is not a proper way to handle cookies. I removed this behavior and introduced an easy way to handle cookies manually instead.
-
Improvement: #380 changed the gemspec to not rely on git.
-
Fix: #378 use the proxy option for WSDL requests.
-
Fix: #369 use HTTP basic and digest authentication credentials to retrieve WSDL files. Fixes #367.
-
Fix: #349 global timeout and SSL options are now used to retrieve a remote WSDL document.
-
Fix: #353 simplified logging. the global
:log
option is now only used to store whether Savon should log instead of creating a newLogger
and changing its logdev to$stdout
or/dev/null
depending on the what was passed.This also fixes rubiii/savon#2 and #379.
-
Fix: #376 added a global
namespaces
option for adding namespaces to the SOAP envelope.
- Upgraded Nori dependency to prevent people from using a version that is vulnerable to the recent remote code execution bug.
-
Fix: #297 added the global
:ssl_verify_mode
and:ssl_version
options which were missing. -
Fix: #344 added missing global ssl cert options
:ssl_cert_file
,:ssl_cert_key_file
and:ssl_ca_cert_file
.
- Fix #342 fixes an issue where namespaces could
not be resolved if the actual operation name to call did not match the operation name passed
to the client's
#call
method. For example::get_stations
for agetStations
operation.
-
Read about all the changes in the updated documentation.
-
Fix: #322 use the builder's state instead of the block's return value to set the soap body/xml values.
-
Fix: #327
response.to_array
now properly returns FalseClass values. -
Fix: 320 use the correct SOAP namespace when the SOAP version changes between requests.
-
Fix: 321 preserve
[false]
values in Hashes.
-
Fix: #312 recursively determines the proper namespaces for SOAP body Hashes with nested Arrays of Hashes.
-
Improvement: #318 isolates building the request to improve threadsafety.
-
Refactoring: Use the
Wasabi::Document
with resolver instead of the customSavon::Wasabi::Document
.
-
Improvement: Changed Savon's core dependencies to be more strict and only allow bug fix changes. Major or minor releases of these dependencies now need a release of Savon so they can be used. This should improve the stability of the library and make it easier to update, because changes to these core dependencies will be documented here as well.
-
Fix: The latest version of Wasabi should now correctly detect the names of your operations. So you should be able to just get the names of some operation:
client.wsdl.soap_actions # => [:authenticate, :find_user]
and pass the Symbol to execute a request:
client.request :authenticate, body: { token: "secret" }
If you still pass anything other than a single Symbol to that method, please open an issue! You shouldn't need to specify a namespace or additional attributes for the tag.
-
Refactoring: Moved code that sets the cookies from the last response for the next request to
HTTPI::Request#set_cookies
.
-
Fix:
Savon.client
didn't pass the optional block. -
Improvement: #291 changed the
:soap_request
hook to act like an around filter. The hook now receives a callback block to execute the SOAP call and can return the result of the callback to continue the request. It can also not call the callback block and return someHTTPI::Response
to mock the SOAP request.As this change affects
savon_spec
, you need to updatesavon_spec
to v1.3.0.
- Fix: #292 again
- Fix: #292
-
Re-added the log method setters to the new config object for backwards compatibility. You should be able to configure the logger as you used to do.
Savon.configure do |config| config.log = false # disable logging config.log_level = :info # changing the log level config.logger = Rails.logger # using the Rails logger end
-
Feature: #264 - Thanks to @hoverlover, Savon and Akami now support signed messages through WSSE.
-
Fix: #275 - Add namespaces to keys in both the SOAP body hash as well as any keys specified in a :order! Array instead of having to define them manually.
-
Fix: #257 - Add ability to accept and send multiple cookies.
-
Improvement: #277 automatically namespace the SOAP input tag. Here's an example from the pull request:
client.request :authenticate
Note the automatic namespace identifier on the authenticate element, as well as the proper namespace inclusion in the document:
<env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:tns="http://v1_0.ws.auth.order.example.com/" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"> <tns:authenticate> <tns:user>username</tns:user> <tns:password>password</tns:password> </tns:authenticate> </env:Envelope>
-
Feature: #289 - Allow the SOAP envelope header to be set as a String.
-
Feature: In addition to the global configuration, there's now also one configuration per client. The global config is cloned when a new client is initialized and gets used instead of the global one. In addition, for
Savon::Model
classes, the config is cloned per class.Closes #84 by allowing one logger per client and #270 by allowing to specify error handling per client.
-
Feature: Added an option to pretty print XML in log messages. Closes #256 and #280.
# global Savon.configure do |config| config.pretty_print_xml = true end # per client client.config.pretty_print_xml = true
-
Refactoring:
- Added
Savon.client
as a shortcut for creating a newSavon::Client
- Changed
Savon::Config
from a module to a class. - Moved logging to the new
Savon::Logger
object. - Removed the
blank?
extension fromObject
.
- Added
-
Improvement: pull request 255 - Raise an error if fetching a remote WSDL fails. Possible fix for issue 236.
-
Improvement: The value for elementFormDefault (:unqualified, :qualified) can now be specified when creating a
Savon::Client
. For example:Savon::Client.new do wsdl.element_form_default = :unqualified end
-
Improvement: pull request 263 - The SOAP action can now be set via a
:soap_action
key passed to the#request
method.client.request(:get_user, :soap_action => :test_action)
-
Fix: pull request 265 - Fixes gemspec problems when bundling under JRuby 1.6.5. Also fixes issue 267.
-
Feature: Savon now ships with Savon::Model. Savon::Model is a lightweight DSL to be used inside your domain models. It's been refactored and is now even more useful than before.
-
Feature: Merged pull request 230 to allow filtering values in logged SOAP request XML messages.
Savon.configure do |config| config.log_filter = ["password"] end
-
Feature: Added an option to change the default encoding of the XML directive tag (defaults to UTF-8) to fix issue 234.
client.request(:find_user) do soap.encoding = "UTF-16" soap.body = { :id => 1 } end
-
Improvement: Merged pull request 231 to gracefully handle invalid response bodies by throwing a
Savon::SOAP::InvalidResponseError
. -
Fix: issue 237 - Set the Content-Type and Content-Length headers for every request.
-
Fix: pull request 250 - The Content-Length header should be the size in bytes.
-
Feature: Merged pull request 210 by mboeh to add
Savon::SOAP::Response#doc
andSavon::SOAP::Response#xpath
. -
Feature: Merged pull request 211 by mattkirman to fix issue 202.
-
Feature: You can now pass a block to
Savon::SOAP::XML#body
and use Builder to create the XML:client.request(:find) do soap.body do |xml| xml.user do xml.id 601173 end end end
-
Fix: issue 218 - Savon now correctly handles namespaced Array items in a Hash passed to
Savon::SOAP::XML#body=
. -
Fix: Merged pull request 212 to fix savon_spec issue 2.
-
Improvement: issue 222 - Set the Content-Length header.
-
Improvement/Fix: Updated Savon to use the latest version of Wasabi. This should fix issue 155 - Savon can automatically add namespaces to SOAP requests based on the WSDL. Users shouldn't need to do anything differently or even notice whether their WSDL hits this case; the intention is that this will "Just Work" and follow the WSDL. The SOAP details are that if elementFormDefault is specified as qualified, Savon will automatically prepend the correct XML namespaces to the elements in a SOAP request. Thanks to jkingdon for this.
-
Fix: issue 143 - Updating Wasabi should solve this issue.
- Refactoring: Extracted WSSE authentication out into the akami gem.
- Refactoring: Extracted the WSDL parser out into the wasabi gem. This should isolate upcoming improvements to the parser.
-
Fix: issue 138 - Savon now supports setting a global SOAP header via
Savon.soap_header=
. -
Fixed the namespace for wsse message timestamps from
wsse:Timestamp
towsu:Timestamp
as required by the specification. -
Change: Removed support for NTLM authentication until it's stable. If you need it, you can still add the following line to your Gemfile:
gem "httpi", "0.9.4"
-
Refactoring:
-
Hash#map_soap_response
and some of its helpers are moved to Nori v1.0.0. Along with replacing core extensions with a proper implementation, Nori now contains a number of methods for configuring its default behavior:- The option whether to strip namespaces was moved to Nori.strip_namespaces
- You can disable "advanced typecasting" for SOAP response values
- And you can configure how SOAP response keys should be converted
-
Savon::SOAP::XML.to_hash
,Savon::SOAP::XML.parse
andSavon::SOAP::XML.to_array
are gone. It wasn't worth keeping them around, because they didn't do much. You can simply parse a SOAP response and translate it to a Savon SOAP response Hash via:``` ruby Nori.parse(xml)[:envelope][:body] ```
-
Savon::SOAP::Response#basic_hash
is nowSavon::SOAP::Response#hash
.
-
-
Fix: issue 154 - Timezone format used by Savon now matches the XML schema spec.
-
Improvement: WSSE basic, digest and timestamp authentication are no longer mutually exclusive. Thanks to mleon for solving issue #142.
-
Improvement: Switched from using Crack to translate the SOAP response to a Hash to using Nori. It's based on Crack and comes with pluggable parsers. It defaults to REXML, but you can switch to Nokogiri via:
Nori.parser = :nokogiri
-
Improvement: WSDL parsing now uses Nokogiri instead of REXML.
-
Improvement: if you're only setting the local or remote address of your wsdl document, you can now pass an (optional) String to
Savon::Client.new
to setwsdl.document
.Savon::Client.new "http://example.com/UserService?wsdl"
-
Improvement: instead of calling the
to_hash
method of your response again and again and again, there is now a#[]
shortcut for you.response[:authenticate_response][:return]
-
Feature: issues #158, #169 and #172 configurable "Hash key Symbol to lowerCamelCase" conversion by using the latest version of Gyoku.
Gyoku.convert_symbols_to(:camelcase) Gyoku.xml(:first_name => "Mac") # => "<FirstName></Firstname>"
You can even define your own conversion formular.
Gyoku.convert_symbols_to { |key| key.upcase } Gyoku.xml(:first_name => "Mac") # => "<FIRST_NAME></FIRST_NAME>"
This should also work for the SOAP input tag and SOAPAction header. So if you had to use a String for the SOAP action to call because your services uses CamelCase instead of lowerCamelCase, you can now change the default and use Symbols instead.
Gyoku.convert_symbols_to(:camelcase) # pre Gyoku 0.4.0 client.request(:get_user) # => "<getUser/> client.request("GetUser") # => "<GetUser/>" # post Gyoku 0.4.0 client.request(:get_user) # => "<GetUser/>"
-
Improvement: issues #170 and #173 Savon no longer rescues exceptions raised by
Crack::XML.parse
. If Crack complains about your WSDL document, you should take control and solve the problem instead of getting no response. -
Improvement: issue #172 support for global env_namespace.
Savon.configure do |config| config.env_namespace = :soapenv # changes the default :env namespace end
-
Fix: issue #163 "Savon 0.8.6 not playing nicely with Httpi 0.9.0". Updating HTTPI to v0.9.1 should solve this problem.
-
And if you haven't already seen the new documentation: savonrb.com
- Fix for issues issue #147 and #151 (771194).
-
Fix for issue #146 (98655c).
-
Fix for issue #147 (252670).
-
Fix for issues issue #130 and #134 (4f9847).
-
Fix for issue #135 (c9261d).
-
Moved implementation of
Savon::SOAP::Response#to_array
to a class method atSavon::SOAP::XML.to_array
(05a7d3). -
Fix for issue #131 (4e57b3).
-
Fix for issue #127 (0eb3da).
-
Changed
Savon::WSSE
to be based on a Hash instead of relying on builder (4cebc3).Savon::WSSE
now supports wsse:Timestamp headers (issue #122) by settingSavon::WSSE#timestamp
totrue
:client.request :some_method do wsse.timestamp = true end
or by setting
Savon::WSSE#created_at
orSavon::WSSE#expires_at
:client.request :some_method do wsse.created_at = Time.now wsse.expires_at = Time.now + 60 end
You can also add custom tags to the WSSE header (issue #69):
client.request :some_method do wsse["wsse:Security"]["wsse:UsernameToken"] = { "Organization" => "ACME", "Domain" => "acme.com" } end
-
Update to depend on HTTPI v0.7.5 which comes with a fallback to use Net::HTTP when no other adapter could be required.
-
Loosen dependency on builder. Should be quite stable.
-
Added
Savon::SOAP::XML#env_namespace
(51fa0e) to configure the SOAP envelope namespace. It defaults to :env but can also be set to an empty String for SOAP envelope tags without a namespace. -
Replaced quite a lot of core extensions by moving the Hash to XML translation into a new gem called Gyoku (bac4b4).
-
Fix for issue #107 (1d6eda).
-
Fix for issue #108 (f64400...0aaca2) Thanks fagiani.
-
Replaced
Savon.response_pattern
with a slightly different implementation of theSavon::SOAP::Response#to_array
method (6df6a6). The method now accepts multiple arguments representing the response Hash keys to traverse and returns the result as an Array or an empty Array in case the key is nil or does not exist.response.to_array :get_user_response, :return # => [{ :id => 1, :name => "foo"}, { :id => 2, :name => "bar"}]
- Fix for savon_spec to not send nil to
Savon::SOAP::XML#body
(c34b42).
-
Added
Savon.response_pattern
(0a12fb) to automatically walk deeper into the SOAP response Hash when a pattern (specified as an Array of Regexps and Symbols) matches the response. If for example your response always looks like ".+Response/return" as in:<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Body> <ns2:authenticateResponse xmlns:ns2="http://v1_0.ws.user.example.com"> <return> <some>thing</some> </return> </ns2:authenticateResponse> </soap:Body> </soap:Envelope>
you could set the response pattern to:
Savon.configure do |config| config.response_pattern = [/.+_response/, :return] end
then instead of calling:
response.to_hash[:authenticate_response][:return] # :some => "thing"
to get the actual content, Savon::SOAP::Response#to_hash will try to apply given the pattern:
response.to_hash # :some => "thing"
Please notice, that if you don't specify a response pattern or if the pattern doesn't match the response, Savon will behave like it always did.
-
Added
Savon::SOAP::Response#to_array
(which also uses the response pattern).
-
Changed
Savon::Client.new
to accept a block instead of multiple Hash arguments. You can access the wsdl, http and wsse objects inside the block to configure your client for a particular service.# Instantiating a client to work with a WSDL document client = Savon::Client.new do wsdl.document = "http://example.com?wsdl" end
# Directly accessing the SOAP endpoint client = Savon::Client.new do wsdl.endpoint = "http://example.com" wsdl.namespace = "http://v1.example.com" end
-
Fix for issue #77, which means you can now use local WSDL documents:
client = Savon::Client.new do wsdl.document = "../wsdl/service.xml" end
-
Changed the way SOAP requests are being dispatched. Instead of using method_missing, you now use the new
request
method, which also accepts a block for you to access the wsdl, http, wsse and soap object. Please notice, that a new soap object is created for every request. So you can only access it inside this block.# A simple request to an :authenticate method client.request :authenticate do soap.body = { :id => 1 } end
-
The new
Savon::Client#request
method fixes issues #37, #61 and #64, which report problems with namespacing the SOAP input tag and attaching attributes to it. Some usage examples:client.request :get_user # Input tag: <getUser> client.request :wsdl, "GetUser" # Input tag: <wsdl:GetUser> client.request :get_user :active => true # Input tag: <getUser active="true">
-
Savon's new
request
method respects the given namespace. If you don't give it a namespace, Savon will set the target namespace to "xmlns:wsdl". But if you do specify a namespace, it will be set to the given Symbol. -
Refactored Savon to use the new HTTPI gem.
HTTPI::Request
replaces theSavon::Request
, so please make sure to have a look at the HTTPI library and let me know about any problems. Using HTTPI actually fixes the following two issues. -
Savon now adds both "xmlns:xsd" and "xmlns:xsi" namespaces for you. Thanks Averell. It also properly serializes nil values as xsi:nil = "true".
-
Fix for issue #24. Instead of Net/HTTP, Savon now uses HTTPI to execute HTTP requests. HTTPI defaults to use HTTPClient which supports HTTP digest authentication.
-
Fix for issue #76. You now have to explicitly specify whether to use a WSDL document, when instantiating a client.
-
Fix for issue #75. Both
Savon::SOAP::Fault
andSavon::HTTP::Error
now contain theHTTPI::Response
. They also inherit fromSavon::Error
, making it easier to rescue both at the same time. -
Fix for issue #87. Thanks to Leonardo Borges.
-
Fix for issue #81. Replaced
Savon::WSDL::Document#to_s
with ato_xml
method. -
Fix for issue #80.
-
Fix for issue #60.
-
Fix for issue #96.
-
Removed global WSSE credentials. Authentication needs to be set up for each client instance.
-
Started to remove quite a few core extensions.
- Fix for issue #53.
- Fixed gemspec to include missing files in the gem.
-
SOAP requests now start with a proper XML declaration.
-
Added support for gzipped requests and responses (http://github.com/lucascs). While gzipped SOAP responses are decoded automatically, you have to manually instruct Savon to gzip SOAP requests:
client = Savon::Client.new "http://example.com/UserService?wsdl", :gzip => true
-
Fix for issue #51. Added the :soap_endpoint option to
Savon::Client.new
which lets you specify a SOAP endpoint per client instance:client = Savon::Client.new "http://example.com/UserService?wsdl", :soap_endpoint => "http://localhost/UserService"
-
Fix for issue #50. Savon still escapes special characters in SOAP request Hash values, but you can now append an exclamation mark to Hash keys specifying that it's value should not be escaped.
-
Moved documentation from the Github Wiki to the actual class files and established a much nicer documentation combining examples and implementation (using Hanna) at: http://savon.rubiii.com
-
Added
Savon::Client#call
as a workaround for dispatching calls to SOAP actions named after existing methods. Fix for issue #48. -
Add support for specifying attributes for duplicate tags (via Hash values as Arrays). Fix for issue #45.
-
Fix for issue #41.
-
Fix for issues #39 and #49. Added
Savon::SOAP#xml
which let's you specify completely custom SOAP request XML.
-
Fix for issue #34.
-
Fix for issue #36.
-
Added feature requested in issue #35.
-
Changed the key for specifying the order of tags from :@inorder to :order!
- Fix for issue #33.
-
Added support for Geotrust-style WSDL documents (Julian Kornberger github.corny@digineo.de).
-
Make HTTP requests include path and query only. This was breaking requests via proxy as scheme and host were repeated (Adrian Mugnolo adrian@mugnolo.com)
-
Avoid warning on 1.8.7 and 1.9.1 (Adrian Mugnolo adrian@mugnolo.com).
-
Fix for issue #29. Default to UTC to xs:dateTime value for WSSE authentication.
-
Fix for issue #28.
-
Fix for issue #27. The Content-Type now defaults to UTF-8.
-
Modification to allow assignment of an Array with an input name and an optional Hash of values to soap.input. Patches issue #30 (stanleydrew andrewmbenton@gmail.com).
-
Fix for issue #25.
-
Exposed the
Net::HTTP
response (added by Kevin Ingolfsland). Use thehttp
accessor (response.http
) on yourSavon::Response
to access theNet::HTTP
response object. -
Fix for issue #21.
-
Fix for issue #22.
-
Fix for issue #19.
-
Added support for global header and namespaces. See issue #9.
- The Hash of HTTP headers for SOAP calls is now public via
Savon::Request#headers
. Patch for issue #8.
This version comes with several changes to the public API! Pay attention to the following list and read the updated Wiki: http://wiki.github.com/savonrb/savon
-
Changed how
Savon::WSDL
can be disabled. Instead of disabling the WSDL globally/per request via two different methods, you now simply append an exclamation mark (!) to your SOAP call:client.get_all_users!
Make sure you know what you're doing because when the WSDL is disabled, Savon does not know about which SOAP actions are valid and just dispatches everything. -
The
Net::HTTP
object used bySavon::Request
to retrieve WSDL documents and execute SOAP calls is now public. While this makes the library even more flexible, it also comes with two major changes:-
SSL client authentication needs to be defined directly on the
Net::HTTP
object:client.request.http.client_cert = ...
I added a shortcut method for setting all options through a Hash similar to the previous implementation:
client.request.http.ssl_client_auth :client_cert => ...
-
Open and read timeouts also need to be set on the
Net::HTTP
object:client.request.http.open_timeout = 30 client.request.http.read_timeout = 30
-
Please refer to the
Net::HTTP
documentation for more details: http://www.ruby-doc.org/stdlib/libdoc/net/http/rdoc/index.html
-
-
Thanks to JulianMorrison, Savon now supports HTTP basic authentication:
client.request.http.basic_auth "username", "password"
-
Julian also added a way to explicitly specify the order of Hash keys and values, so you should now be able to work with services requiring a specific order of input parameters while still using Hash input.
client.find_user { |soap| soap.body = { :name => "Lucy", :id => 666, :@inorder => [:id, :name] } }
-
Savon::Response#to_hash
now returns the content inside of "soap:Body" instead of trying to go one level deeper and return it's content. The previous implementation only worked when the "soap:Body" element contained a single child. See issue #17. -
Added
Savon::SOAP#namespace
as a shortcut for setting the "xmlns:wsdl" namespace.soap.namespace = "http://example.com"
-
Improved specifications for various kinds of WSDL documents.
-
Added support for SOAP endpoints which are different than the WSDL endpoint of a service.
-
Changed how SOAP actions and inputs are retrieved from the WSDL documents. This might break a few existing implementations, but makes Savon work well with even more services. If this change breaks your implementation, please take a look at the
action
andinput
methods of theSavon::SOAP
object. One specific problem I know of is working with the createsend WSDL and its namespaced actions.To make it work, call the SOAP action without namespace and specify the input manually:
client.get_api_key { |soap| soap.input = "User.GetApiKey" }
-
Implemented support for a proxy server. The proxy URI can be set through an optional Hash of options passed to instantiating
Savon::Client
(Dave Woodward dave@futuremint.com) -
Implemented support for SSL client authentication. Settings can be set through an optional Hash of arguments passed to instantiating
Savon::Client
(colonhyphenp) -
Patch for issue #10.
- Default to use the name of the SOAP action (the method called in a client) in lowerCamelCase for SOAP action and input when Savon::WSDL is disabled. You still need to specify soap.action and maybe soap.input in case your SOAP actions are named any different.
- Added an
open_timeout
method toSavon::Request
.
-
Refactored specs to be less unit-like.
-
Added a getter for the
Savon::Request
toSavon::Client
and aread_timeout
setter for HTTP requests. -
wsdl.soap_actions
now returns an Array of SOAP actions. For the previous "mapping" please usewsdl.operations
. -
Replaced WSDL document with stream parsing.
Benchmarks (1000 SOAP calls): user system total real 0.6.4 72.180000 8.280000 80.460000 (750.799011) 0.6.3 192.900000 19.630000 212.530000 (914.031865)
-
Removing 2 ruby deprecation warnings for parenthesized arguments. (Dave Woodward dave@futuremint.com)
-
Added global and per request options for disabling
Savon::WSDL
.Benchmarks (1000 SOAP calls): user system total real WSDL 192.900000 19.630000 212.530000 (914.031865) disabled WSDL 5.680000 1.340000 7.020000 (298.265318)
-
Improved XPath expressions for parsing the WSDL document.
Benchmarks (1000 SOAP calls): user system total real 0.6.3 192.900000 19.630000 212.530000 (914.031865) 0.6.2 574.720000 78.380000 653.100000 (1387.778539)
-
Added support for changing the name of the SOAP input node.
-
Added a CHANGELOG.
- Fixed a problem with WSSE credentials, where every request contained a WSSE authentication header.
-
method_missing
now yields the SOAP and WSSE objects to a given block. -
The response_process (which previously was a block passed to method_missing) was replaced by
Savon::Response
. -
Improved SOAP action handling (another problem that came up with issue #1).
- Patch for issue #2.
- Patch for issue #1.
-
Optimized default response process.
-
Added WSSE settings via defaults.
-
Added SOAP fault and HTTP error handling.
-
Improved documentation
-
Added specs
- Complete rewrite and public release.