Sha256: 4d2fbb008a7f64877a9fa0349340c6d7daa312998aba1f4c8d0e36266e8840b4

Contents?: true

Size: 783 Bytes

Versions: 2

Compression:

Stored size: 783 Bytes

Contents

module Exlibris
  module Primo
    module WebService
      module Client
        module SavonClient
          require 'savon'

          def client
            # 
            # We're not using WSDL at the moment, since
            # we don't want to make an extra HTTP call.
            # 
            # @client ||= Savon.client(wsdl: wsdl)
            @client ||= Savon.client(client_options)
          end
          protected :client
          
          def client_options
            {
              proxy: proxy_url, 
              endpoint: endpoint, 
              namespace: endpoint, 
              log: false, 
              log_level: :warn
            }.delete_if { |k, v| v.blank? }
          end
          private :client_options
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
exlibris-primo-2.1.1 lib/exlibris/primo/web_service/client/base/savon_client.rb
exlibris-primo-2.1.0 lib/exlibris/primo/web_service/client/base/savon_client.rb