cobro_digital 1.4.1 → 1.4.2

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: fb2ab648eaab4bbb8d09d2f9e46af668ef853f110cf44f60ce0f7bd394f6f710
4
- data.tar.gz: 8f837e57f9b81d1321c12c4273886ea9a1ca46287c071ddde9e489d0e57cfd19
3
+ metadata.gz: 72af0ffb1e9e86abfb1b0c7aaad4cdd8538cef934b9c862ebae09a05a8b71714
4
+ data.tar.gz: 282710fc8dc2e695f9193a5e41e8e10afc601c6d7b9f813b3d30fe243041e9e8
5
5
  SHA512:
6
- metadata.gz: 7303bc44c0fcb6f13d8f3ad753f77471069b3d787404b6066a8cb1491134b90ef794436b14e8af8959a8bf8f6cb868530b35358204b8987759980d4268540541
7
- data.tar.gz: '05977f4535b8ba420a7e38ea81327ed08b9b9f39f0f808a232cdf71b7937e162659790d82d740b52d2426169adde31fdce892c555652bc836591d435d516e2a2'
6
+ metadata.gz: 1d1f2e2e2bac08d734eb8a4adb12a1bf4edba60943d4889a9a62485c56ee5d4e4942743b7606689d596557cb31f7efc2499e93359017ddfdca87b084d1b769d8
7
+ data.tar.gz: 8866ce3a1f5b9f0097d0235166edf71ed923d6c8ada6bf15fe3c1567741cf8091cd07d0525c8a476369b791a167edfc39c2ceae2518d1ba334a5ec138927d46e
@@ -16,6 +16,7 @@ module CobroDigital
16
16
  CLIENTS = [SOAP, HTTPS]
17
17
  URI = 'https://www.cobrodigital.com:14365/ws3/'
18
18
  WSDL = 'https://www.cobrodigital.com:14365/ws3/?wsdl'
19
+ TIMEOUT = 300
19
20
 
20
21
  module Https
21
22
  POST = 'Post'
@@ -39,10 +40,17 @@ module CobroDigital
39
40
  end
40
41
 
41
42
  def soap_client(params)
42
- client = Savon.client(wsdl: CobroDigital::WSDL, log_level: :debug, pretty_print_xml: true)
43
+ client = Savon.client(
44
+ wsdl: CobroDigital::WSDL,
45
+ log_level: :debug,
46
+ pretty_print_xml: true,
47
+ open_timeout: CobroDigital::TIMEOUT,
48
+ read_timeout: CobroDigital::TIMEOUT
49
+ )
43
50
  operation = client.operation(:webservice_cobrodigital)
44
51
  request = operation.build(message: { 'parametros_de_entrada' => params.to_json })
45
52
  @request_xml = request.pretty
53
+
46
54
  client.call(:webservice_cobrodigital, message: { 'parametros_de_entrada' => params.to_json })
47
55
  end
48
56
 
@@ -57,7 +65,15 @@ module CobroDigital
57
65
  req = "Net::HTTP::#{http_method}".constantize.new(uri)
58
66
  end
59
67
 
60
- Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == CobroDigital::HTTPS) { |http| http.request(req) }
68
+ Net::HTTP.start(
69
+ uri.hostname,
70
+ uri.port,
71
+ use_ssl: uri.scheme == CobroDigital::HTTPS,
72
+ open_timeout: CobroDigital::TIMEOUT,
73
+ read_timeout: CobroDigital::TIMEOUT
74
+ ) do |http|
75
+ http.request(req)
76
+ end
61
77
  end
62
78
 
63
79
  def call(request)
@@ -1,3 +1,3 @@
1
1
  module CobroDigital
2
- VERSION = "1.4.1"
2
+ VERSION = "1.4.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cobro_digital
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.1
4
+ version: 1.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - g.edera
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-06-28 00:00:00.000000000 Z
11
+ date: 2018-09-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -154,7 +154,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
154
154
  version: '0'
155
155
  requirements: []
156
156
  rubyforge_project:
157
- rubygems_version: 2.7.6
157
+ rubygems_version: 2.7.7
158
158
  signing_key:
159
159
  specification_version: 4
160
160
  summary: Adaptador CobroDigital