samanage 1.9.2 → 1.9.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/changelog.md +3 -0
- data/lib/samanage/api.rb +1 -1
- data/lib/samanage/api/incidents.rb +5 -3
- data/lib/samanage/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: a2546bcfadc5336181263358272703e0d622350a
|
|
4
|
+
data.tar.gz: 2ca8fd46211877fd877c2a52c015df8f4364af66
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: cf23a86735c95112bb0a02d7c5e7c3fe8868870814684105ef31455e5cfbb0083b909285882ec796452f110aec1cbb5baf086efcd3533fdb7a21f18c824a9ed8
|
|
7
|
+
data.tar.gz: e7d3f6dc216f39f6ad33bba025dc8c13135cf94668503d1a709bb7957038814ea0b10cb9b0117c8040f939a3e53b9f3dfae6a8d797e4250b77f1307961fd09e0
|
data/changelog.md
CHANGED
data/lib/samanage/api.rb
CHANGED
|
@@ -93,7 +93,7 @@ module Samanage
|
|
|
93
93
|
else
|
|
94
94
|
raise Samanage::Error.new(response: {response: 'Unknown HTTP method'})
|
|
95
95
|
end
|
|
96
|
-
rescue Errno::ECONNREFUSED, Net::OpenTimeout, Errno::ETIMEDOUT, OpenSSL::SSL::SSLError => e
|
|
96
|
+
rescue Errno::ECONNREFUSED, Net::OpenTimeout, Net::ReadTimeout, Errno::ETIMEDOUT, OpenSSL::SSL::SSLError => e
|
|
97
97
|
puts "Error: #{e} - #{e.class}"
|
|
98
98
|
puts "Retry: #{retries}/#{self.max_retries}"
|
|
99
99
|
sleep 3
|
|
@@ -14,8 +14,8 @@ module Samanage
|
|
|
14
14
|
# - layout: 'long'
|
|
15
15
|
def collect_incidents(options: {})
|
|
16
16
|
incidents = Array.new
|
|
17
|
-
total_pages = self.get_incidents[:total_pages]
|
|
18
|
-
puts "Pulling Incidents with Audit Archives (this may take
|
|
17
|
+
total_pages = self.get_incidents(options: options)[:total_pages]
|
|
18
|
+
puts "Pulling Incidents with Audit Archives (this may take some time)" if options[:audit_archives] && options[:verbose]
|
|
19
19
|
1.upto(total_pages) do |page|
|
|
20
20
|
puts "Collecting Incidents page: #{page}/#{total_pages}" if options[:verbose]
|
|
21
21
|
if options[:audit_archives]
|
|
@@ -27,7 +27,9 @@ module Samanage
|
|
|
27
27
|
end
|
|
28
28
|
else
|
|
29
29
|
layout = options[:layout] == 'long' ? '&layout=long' : nil
|
|
30
|
-
|
|
30
|
+
options[:page] = page
|
|
31
|
+
puts "options: #{options}"
|
|
32
|
+
incidents += self.get_incidents(options: options)[:data]
|
|
31
33
|
end
|
|
32
34
|
end
|
|
33
35
|
incidents
|
data/lib/samanage/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: samanage
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.9.
|
|
4
|
+
version: 1.9.3
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Chris Walls
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2018-01-
|
|
11
|
+
date: 2018-01-26 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: httparty
|