splunk-sdk-ruby 1.0.2 → 1.0.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 +9 -9
- data/CHANGELOG.md +9 -0
- data/README.md +2 -1
- data/lib/splunk-sdk-ruby/context.rb +10 -3
- data/lib/splunk-sdk-ruby/entity/job.rb +5 -1
- data/lib/splunk-sdk-ruby/version.rb +1 -1
- data/splunk-sdk-ruby.gemspec +2 -2
- data/test/test_atomfeed.rb +4 -2
- data/test/test_context.rb +12 -0
- data/test/test_index.rb +3 -1
- data/test/test_jobs.rb +7 -0
- data/test/test_namespace.rb +5 -5
- data/test/test_resultsreader.rb +10 -7
- data/test/test_service.rb +1 -1
- metadata +75 -76
- data/examples/run_examples.rb~ +0 -22
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
MDNmYWQwZDZmOTkwODM0NDc3MTJjYWNlODBhZjFkNzAwMzE2NDgwMw==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
7
|
-
|
6
|
+
N2Y0OWM1OTg3ZWVjYmJiYmY1NjZlNzM5YzY4MDA5ZTU0OTYzZDYyNA==
|
7
|
+
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
MjUwYWNkYmM0ZTg2MzA0M2U3YTk0MWJhOTE4ZDFlNmU1NjFkODRhODU2MzY4
|
10
|
+
YjdmNjYzMTYzZWQxZWRhYmQ5MDJlNGRkN2Q0NmE5YTQxMWExZGZiZjA2ZTcz
|
11
|
+
ZDA0MzJjMDgzY2MzZDFmZDYyNmQ0OTdjZjVkMzg3NDg2MjdjODM=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
NjA5N2I4ZDE4ZGQxNDU2MDgxNWM0MGQ1NzlhOTc4OTRlNDE5ZmUzMGJlOTAx
|
14
|
+
ZWIyZmE0MTM0YWVhODM5NWVjMmYzYWUyMmZlZjEzOGQzYjI4MGFhNDA1ZjFj
|
15
|
+
Mjc3OTdmY2NiYjg4ODJkZDUzZmFlNmQ2ZjhjOTg3OGVmODA3Y2I=
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,14 @@
|
|
1
1
|
# Splunk SDK for Ruby Changelog
|
2
2
|
|
3
|
+
## Version 1.0.3
|
4
|
+
|
5
|
+
* Splunk SDK for Ruby now works with Splunk 6.
|
6
|
+
* Fixed URL escaping of owners and apps in namespaces that contain special characters.
|
7
|
+
|
8
|
+
## Version 1.0.2
|
9
|
+
|
10
|
+
* Cosmetic changes to the repository only.
|
11
|
+
|
3
12
|
## Version 1.0.1
|
4
13
|
|
5
14
|
* Fixed Job#results to properly handle arguments.
|
data/README.md
CHANGED
@@ -307,8 +307,11 @@ module Splunk
|
|
307
307
|
url = ""
|
308
308
|
url << "#{(scheme || @scheme).to_s}://"
|
309
309
|
url << "#{host || @host}:#{(port || @port).to_s}/"
|
310
|
+
# You would think that the second argument to URI::encode would be unnecessary
|
311
|
+
# for it to actually escape URI reserved characters. You would be wrong. It does
|
312
|
+
# have to be there, or URI::encode doesn't actually escape any characters.
|
310
313
|
url << (namespace.to_path_fragment() + resource).
|
311
|
-
map {|fragment| URI::encode(fragment)}.
|
314
|
+
map {|fragment| URI::encode(fragment, Regexp.new("[^#{URI::PATTERN::UNRESERVED}]"))}.
|
312
315
|
join("/")
|
313
316
|
|
314
317
|
return request_by_url(:url => url,
|
@@ -394,8 +397,12 @@ module Splunk
|
|
394
397
|
end
|
395
398
|
|
396
399
|
# Issue the request.
|
400
|
+
url_hostname = url.host
|
401
|
+
if url.respond_to?(:hostname)
|
402
|
+
url_hostname = url.hostname
|
403
|
+
end
|
397
404
|
response = Net::HTTP::start(
|
398
|
-
|
405
|
+
url_hostname, url.port,
|
399
406
|
:use_ssl => url.scheme == 'https',
|
400
407
|
# We don't support certificates.
|
401
408
|
:verify_mode => OpenSSL::SSL::VERIFY_NONE
|
@@ -522,4 +529,4 @@ module Splunk
|
|
522
529
|
end
|
523
530
|
|
524
531
|
end
|
525
|
-
end
|
532
|
+
end
|
@@ -167,7 +167,11 @@ module Splunk
|
|
167
167
|
def is_ready?()
|
168
168
|
begin
|
169
169
|
refresh()
|
170
|
-
|
170
|
+
if @state["content"]["dispatchState"] == "QUEUED" || @state["content"]["dispatchState"] == "PARSING"
|
171
|
+
return false
|
172
|
+
else
|
173
|
+
return true
|
174
|
+
end
|
171
175
|
rescue EntityNotReady
|
172
176
|
return false
|
173
177
|
end
|
data/splunk-sdk-ruby.gemspec
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |gem|
|
4
4
|
gem.name = 'splunk-sdk-ruby'
|
5
|
-
gem.version = '1.0.
|
5
|
+
gem.version = '1.0.3'
|
6
6
|
|
7
7
|
gem.authors = ['Splunk']
|
8
8
|
gem.email = ['devinfo@splunk.com']
|
@@ -14,7 +14,7 @@ Gem::Specification.new do |gem|
|
|
14
14
|
gem.required_ruby_version = '>=1.9.2'
|
15
15
|
gem.add_dependency 'jruby-openssl', '~>0.7.7' if RUBY_PLATFORM == "java"
|
16
16
|
gem.add_dependency 'rake', '~>10'
|
17
|
-
gem.add_development_dependency 'test-unit'
|
17
|
+
gem.add_development_dependency 'test-unit', '~> 0'
|
18
18
|
|
19
19
|
gem.files = Dir['{lib,examples,test}/**/*',
|
20
20
|
'CHANGELOG.md',
|
data/test/test_atomfeed.rb
CHANGED
@@ -39,12 +39,14 @@ class TestAtomFeed < Test::Unit::TestCase
|
|
39
39
|
puts "Nokogiri not installed. Skipping."
|
40
40
|
end
|
41
41
|
|
42
|
-
|
42
|
+
data_path = File.dirname(File.expand_path(__FILE__))
|
43
|
+
test_cases = JSON::parse(open(data_path + "/data/atom_test_data.json").read())
|
43
44
|
|
44
45
|
xml_libraries.each do |xml_library|
|
45
46
|
test_cases.each_entry do |filename, expected|
|
46
47
|
define_method("test_#{xml_library}_#{filename}".intern()) do
|
47
|
-
|
48
|
+
|
49
|
+
file = File.open(File.dirname(File.expand_path(__FILE__)) + "/data/atom/#{filename}.xml")
|
48
50
|
Splunk::require_xml_library(xml_library)
|
49
51
|
feed = Splunk::AtomFeed.new(file)
|
50
52
|
|
data/test/test_context.rb
CHANGED
@@ -116,4 +116,16 @@ class TestContext < TestCaseWithSplunkConnection
|
|
116
116
|
assert_true(v.is_a?(Integer))
|
117
117
|
end
|
118
118
|
end
|
119
|
+
|
120
|
+
def test_url_encoding_of_characters_in_usernames
|
121
|
+
name = temporary_name() + "/\441@"
|
122
|
+
begin
|
123
|
+
@service.request(:namespace => Splunk::namespace(:sharing => "user", :owner => name, :app => name))
|
124
|
+
fail("Didn't receive an error.")
|
125
|
+
rescue SplunkHTTPError => err
|
126
|
+
assert_equal(404, err.code)
|
127
|
+
assert_equal("User does not exist: " + name, err.detail)
|
128
|
+
end
|
129
|
+
end
|
130
|
+
|
119
131
|
end
|
data/test/test_index.rb
CHANGED
@@ -42,7 +42,9 @@ class IndexTestCase < TestCaseWithSplunkConnection
|
|
42
42
|
|
43
43
|
def test_disable_enable
|
44
44
|
@index.disable()
|
45
|
-
|
45
|
+
if @service.splunk_version[0] < 6
|
46
|
+
checked_restart(@service)
|
47
|
+
end
|
46
48
|
@index.refresh()
|
47
49
|
assert_equal('1', @index["disabled"])
|
48
50
|
|
data/test/test_jobs.rb
CHANGED
@@ -250,9 +250,11 @@ class JobsTestCase < TestCaseWithSplunkConnection
|
|
250
250
|
begin
|
251
251
|
install_app_from_collection("sleep_command")
|
252
252
|
job = @service.jobs.create("search index=_internal | sleep 2 | join [sleep 2]")
|
253
|
+
|
253
254
|
while !job.is_ready?()
|
254
255
|
sleep(0.1)
|
255
256
|
end
|
257
|
+
|
256
258
|
assert_equal("0", job["isPreviewEnabled"])
|
257
259
|
job.enable_preview()
|
258
260
|
assert_eventually_true(1000) do
|
@@ -340,6 +342,11 @@ class LongJobTestCase < JobsTestCase
|
|
340
342
|
end
|
341
343
|
|
342
344
|
def test_touch
|
345
|
+
# Any request resets the TTL in Splunk 6.0. This was an error that
|
346
|
+
# has been filed and will be reverted (TODO: Insert Jira number once dnoble logs it).
|
347
|
+
if @service.splunk_version[0,2] == [6,0]
|
348
|
+
return
|
349
|
+
end
|
343
350
|
i = 2
|
344
351
|
while i < 20
|
345
352
|
sleep(i)
|
data/test/test_namespace.rb
CHANGED
@@ -117,16 +117,16 @@ class TestNamespaces < Test::Unit::TestCase
|
|
117
117
|
Splunk::namespace(:sharing => "global").to_path_fragment)
|
118
118
|
assert_equal(["servicesNS", "nobody", "system"],
|
119
119
|
Splunk::namespace(:sharing => "system").to_path_fragment)
|
120
|
-
assert_equal(["servicesNS", "nobody", "search"],
|
121
|
-
Splunk::namespace(:sharing => "app", :app => "search").to_path_fragment)
|
120
|
+
assert_equal(["servicesNS", "nobody", "search/@!"],
|
121
|
+
Splunk::namespace(:sharing => "app", :app => "search/@!").to_path_fragment)
|
122
122
|
assert_equal(["servicesNS", "nobody", "-"],
|
123
123
|
Splunk::namespace(:sharing => "app", :app => "-").to_path_fragment)
|
124
124
|
assert_equal(["services"], Splunk::namespace(:sharing => "app",
|
125
125
|
:app => "").to_path_fragment)
|
126
|
-
assert_equal(["servicesNS", "boris", "search"],
|
126
|
+
assert_equal(["servicesNS", "boris/@!", "search/@!"],
|
127
127
|
Splunk::namespace(:sharing => "user",
|
128
|
-
:app => "search",
|
129
|
-
:owner => "boris").to_path_fragment)
|
128
|
+
:app => "search/@!",
|
129
|
+
:owner => "boris/@!").to_path_fragment)
|
130
130
|
end
|
131
131
|
|
132
132
|
def test_eai_acl_to_namespace
|
data/test/test_resultsreader.rb
CHANGED
@@ -4,6 +4,8 @@ require 'json'
|
|
4
4
|
|
5
5
|
include Splunk
|
6
6
|
|
7
|
+
TEST_PATH = File.dirname(File.expand_path(__FILE__))
|
8
|
+
|
7
9
|
class TestResultsReader < Test::Unit::TestCase
|
8
10
|
if nokogiri_available?
|
9
11
|
xml_libraries = [:nokogiri, :rexml]
|
@@ -34,8 +36,9 @@ class TestResultsReader < Test::Unit::TestCase
|
|
34
36
|
assert_equal(expected["results"].length, n_results)
|
35
37
|
end
|
36
38
|
|
37
|
-
|
38
|
-
|
39
|
+
data_path = File.dirname(File.expand_path(__FILE__))
|
40
|
+
test_data = JSON::parse(open(data_path + "/data/resultsreader_test_data.json").read())
|
41
|
+
export_data = JSON::parse(open(data_path + "/data/export_test_data.json").read())
|
39
42
|
|
40
43
|
xml_libraries.each do |xml_library|
|
41
44
|
test_data.each_entry do |version, tests|
|
@@ -43,7 +46,7 @@ class TestResultsReader < Test::Unit::TestCase
|
|
43
46
|
test_name = "test_#{xml_library}_#{version.gsub(/\./, "_")}_#{name}"
|
44
47
|
define_method(test_name.intern()) do
|
45
48
|
Splunk::require_xml_library(xml_library)
|
46
|
-
file = File.open("
|
49
|
+
file = File.open(TEST_PATH + "/data/results/#{version}/#{name}.xml")
|
47
50
|
reader = ResultsReader.new(file)
|
48
51
|
assert_results_reader_equals(expected, reader)
|
49
52
|
end
|
@@ -55,7 +58,7 @@ class TestResultsReader < Test::Unit::TestCase
|
|
55
58
|
test_name = "test_#{xml_library}_#{version.gsub(/\./, "_")}_export_via_results_reader"
|
56
59
|
define_method(test_name.intern) do
|
57
60
|
Splunk::require_xml_library(xml_library)
|
58
|
-
raw_file = File.open("
|
61
|
+
raw_file = File.open(TEST_PATH + "/data/export/#{version}/export_results.xml")
|
59
62
|
file = Splunk::ExportStream.new(raw_file)
|
60
63
|
found = ResultsReader.new(file)
|
61
64
|
expected = tests["without_preview"]
|
@@ -66,7 +69,7 @@ class TestResultsReader < Test::Unit::TestCase
|
|
66
69
|
test_name = "test_#{xml_library}_#{version.gsub(/\./, "_")}_sans_preview"
|
67
70
|
define_method(test_name.intern) do
|
68
71
|
Splunk::require_xml_library(xml_library)
|
69
|
-
raw_file = File.open("
|
72
|
+
raw_file = File.open(TEST_PATH + "/data/export/#{version}/export_results.xml")
|
70
73
|
file = Splunk::ExportStream.new(raw_file)
|
71
74
|
reader = MultiResultsReader.new(file)
|
72
75
|
found = reader.final_results()
|
@@ -78,7 +81,7 @@ class TestResultsReader < Test::Unit::TestCase
|
|
78
81
|
test_name = "test_#{xml_library}_#{version.gsub(/\./, "_")}_with_preview"
|
79
82
|
define_method(test_name.intern) do
|
80
83
|
Splunk::require_xml_library(xml_library)
|
81
|
-
raw_file = File.open("
|
84
|
+
raw_file = File.open(TEST_PATH + "/data/export/#{version}/export_results.xml")
|
82
85
|
file = Splunk::ExportStream.new(raw_file)
|
83
86
|
multireader = MultiResultsReader.new(file)
|
84
87
|
n_results_sets = 0
|
@@ -100,7 +103,7 @@ class TestResultsReader < Test::Unit::TestCase
|
|
100
103
|
if tests.has_key?("nonreporting")
|
101
104
|
define_method(test_name.intern) do
|
102
105
|
Splunk::require_xml_library(xml_library)
|
103
|
-
file = File.open("
|
106
|
+
file = File.open(TEST_PATH + "/data/export/#{version}/nonreporting.xml")
|
104
107
|
multireader = MultiResultsReader.new(file)
|
105
108
|
n_results_sets = 0
|
106
109
|
readers = []
|
data/test/test_service.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: splunk-sdk-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Splunk
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2014-01-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -28,14 +28,14 @@ dependencies:
|
|
28
28
|
name: test-unit
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- -
|
31
|
+
- - ~>
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '0'
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- -
|
38
|
+
- - ~>
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
41
|
description: Splunk SDK for Ruby
|
@@ -45,94 +45,93 @@ executables: []
|
|
45
45
|
extensions: []
|
46
46
|
extra_rdoc_files: []
|
47
47
|
files:
|
48
|
+
- CHANGELOG.md
|
49
|
+
- Gemfile
|
50
|
+
- LICENSE
|
51
|
+
- README.md
|
52
|
+
- Rakefile
|
53
|
+
- examples/1_connect.rb
|
54
|
+
- examples/2_manage.rb
|
55
|
+
- examples/3_blocking_searches.rb
|
56
|
+
- examples/4_asynchronous_searches.rb
|
57
|
+
- examples/5_stream_data_to_splunk.rb
|
58
|
+
- examples/6_work_with_modular_inputs.rb
|
59
|
+
- examples/example_modular_inputs.spl
|
60
|
+
- examples/run_examples.rb
|
61
|
+
- lib/splunk-sdk-ruby.rb
|
62
|
+
- lib/splunk-sdk-ruby/ambiguous_entity_reference.rb
|
48
63
|
- lib/splunk-sdk-ruby/atomfeed.rb
|
64
|
+
- lib/splunk-sdk-ruby/collection.rb
|
65
|
+
- lib/splunk-sdk-ruby/collection/apps.rb
|
66
|
+
- lib/splunk-sdk-ruby/collection/case_insensitive_collection.rb
|
67
|
+
- lib/splunk-sdk-ruby/collection/configuration_file.rb
|
68
|
+
- lib/splunk-sdk-ruby/collection/configurations.rb
|
69
|
+
- lib/splunk-sdk-ruby/collection/input_kinds.rb
|
70
|
+
- lib/splunk-sdk-ruby/collection/jobs.rb
|
71
|
+
- lib/splunk-sdk-ruby/collection/messages.rb
|
49
72
|
- lib/splunk-sdk-ruby/context.rb
|
50
|
-
- lib/splunk-sdk-ruby/
|
73
|
+
- lib/splunk-sdk-ruby/entity.rb
|
74
|
+
- lib/splunk-sdk-ruby/entity/index.rb
|
75
|
+
- lib/splunk-sdk-ruby/entity/job.rb
|
76
|
+
- lib/splunk-sdk-ruby/entity/message.rb
|
77
|
+
- lib/splunk-sdk-ruby/entity/modular_input_kind.rb
|
78
|
+
- lib/splunk-sdk-ruby/entity/saved_search.rb
|
79
|
+
- lib/splunk-sdk-ruby/entity/stanza.rb
|
80
|
+
- lib/splunk-sdk-ruby/entity_not_ready.rb
|
51
81
|
- lib/splunk-sdk-ruby/illegal_operation.rb
|
52
|
-
- lib/splunk-sdk-ruby/version.rb
|
53
82
|
- lib/splunk-sdk-ruby/namespace.rb
|
54
|
-
- lib/splunk-sdk-ruby/
|
83
|
+
- lib/splunk-sdk-ruby/resultsreader.rb
|
84
|
+
- lib/splunk-sdk-ruby/service.rb
|
55
85
|
- lib/splunk-sdk-ruby/splunk_http_error.rb
|
56
|
-
- lib/splunk-sdk-ruby/ambiguous_entity_reference.rb
|
57
|
-
- lib/splunk-sdk-ruby/entity_not_ready.rb
|
58
86
|
- lib/splunk-sdk-ruby/synonyms.rb
|
59
|
-
- lib/splunk-sdk-ruby/
|
87
|
+
- lib/splunk-sdk-ruby/version.rb
|
60
88
|
- lib/splunk-sdk-ruby/xml_shim.rb
|
61
|
-
-
|
62
|
-
-
|
63
|
-
-
|
64
|
-
-
|
65
|
-
-
|
66
|
-
-
|
67
|
-
-
|
68
|
-
-
|
69
|
-
- lib/splunk-sdk-ruby/collection/jobs.rb
|
70
|
-
- lib/splunk-sdk-ruby/collection/messages.rb
|
71
|
-
- lib/splunk-sdk-ruby/collection/apps.rb
|
72
|
-
- lib/splunk-sdk-ruby/collection/configuration_file.rb
|
73
|
-
- lib/splunk-sdk-ruby/collection/input_kinds.rb
|
74
|
-
- lib/splunk-sdk-ruby/collection.rb
|
75
|
-
- lib/splunk-sdk-ruby.rb
|
76
|
-
- examples/1_connect.rb
|
77
|
-
- examples/2_manage.rb
|
78
|
-
- examples/run_examples.rb
|
79
|
-
- examples/example_modular_inputs.spl
|
80
|
-
- examples/4_asynchronous_searches.rb
|
81
|
-
- examples/run_examples.rb~
|
82
|
-
- examples/5_stream_data_to_splunk.rb
|
83
|
-
- examples/3_blocking_searches.rb
|
84
|
-
- examples/6_work_with_modular_inputs.rb
|
85
|
-
- test/test_restarts.rb
|
86
|
-
- test/test_jobs.rb
|
87
|
-
- test/test_helper.rb
|
88
|
-
- test/test_service.rb
|
89
|
-
- test/test_configuration_file.rb
|
90
|
-
- test/test_saved_searches.rb
|
91
|
-
- test/test_users.rb
|
92
|
-
- test/test_context.rb
|
89
|
+
- splunk-sdk-ruby.gemspec
|
90
|
+
- test/data/atom/atom_feed_with_message.xml
|
91
|
+
- test/data/atom/atom_with_feed.xml
|
92
|
+
- test/data/atom/atom_with_several_entries.xml
|
93
|
+
- test/data/atom/atom_with_simple_entries.xml
|
94
|
+
- test/data/atom/atom_without_feed.xml
|
95
|
+
- test/data/atom_test_data.json
|
96
|
+
- test/data/export/4.2.5/export_results.xml
|
93
97
|
- test/data/export/4.3.5/export_results.xml
|
94
98
|
- test/data/export/5.0.1/export_results.xml
|
95
99
|
- test/data/export/5.0.1/nonreporting.xml
|
96
|
-
- test/data/
|
97
|
-
- test/data/results/
|
98
|
-
- test/data/results/5.0.2/results.xml
|
99
|
-
- test/data/results/5.0.2/results-empty.xml
|
100
|
-
- test/data/results/5.0.2/results-empty_preview.xml
|
101
|
-
- test/data/results/4.3.5/results-preview.xml
|
102
|
-
- test/data/results/4.3.5/results.xml
|
103
|
-
- test/data/results/4.3.5/results-empty.xml
|
100
|
+
- test/data/export_test_data.json
|
101
|
+
- test/data/results/4.2.5/results-empty.xml
|
104
102
|
- test/data/results/4.2.5/results-preview.xml
|
105
103
|
- test/data/results/4.2.5/results.xml
|
106
|
-
- test/data/results/4.
|
104
|
+
- test/data/results/4.3.5/results-empty.xml
|
105
|
+
- test/data/results/4.3.5/results-preview.xml
|
106
|
+
- test/data/results/4.3.5/results.xml
|
107
|
+
- test/data/results/5.0.2/results-empty.xml
|
108
|
+
- test/data/results/5.0.2/results-empty_preview.xml
|
109
|
+
- test/data/results/5.0.2/results-preview.xml
|
110
|
+
- test/data/results/5.0.2/results.xml
|
107
111
|
- test/data/resultsreader_test_data.json
|
108
|
-
- test/
|
109
|
-
- test/data/atom/atom_with_feed.xml
|
110
|
-
- test/data/atom/atom_with_several_entries.xml
|
111
|
-
- test/data/atom/atom_feed_with_message.xml
|
112
|
-
- test/data/atom/atom_with_simple_entries.xml
|
113
|
-
- test/data/atom_test_data.json
|
114
|
-
- test/data/export_test_data.json
|
115
|
-
- test/test_collection.rb
|
116
|
-
- test/test_roles.rb
|
117
|
-
- test/test_xml_shim.rb
|
118
|
-
- test/test_atomfeed.rb
|
119
|
-
- test/testfile.txt
|
112
|
+
- test/services.server.info.xml
|
120
113
|
- test/services.xml
|
121
|
-
- test/
|
122
|
-
- test/
|
123
|
-
- test/
|
124
|
-
- test/
|
125
|
-
- test/test_inputs.rb
|
114
|
+
- test/test_atomfeed.rb
|
115
|
+
- test/test_collection.rb
|
116
|
+
- test/test_configuration_file.rb
|
117
|
+
- test/test_context.rb
|
126
118
|
- test/test_entity.rb
|
119
|
+
- test/test_helper.rb
|
120
|
+
- test/test_http_error.rb
|
127
121
|
- test/test_index.rb
|
128
|
-
- test/
|
122
|
+
- test/test_inputs.rb
|
123
|
+
- test/test_jobs.rb
|
129
124
|
- test/test_messages.rb
|
130
|
-
-
|
131
|
-
-
|
132
|
-
-
|
133
|
-
-
|
134
|
-
-
|
135
|
-
-
|
125
|
+
- test/test_modular_input_kinds.rb
|
126
|
+
- test/test_namespace.rb
|
127
|
+
- test/test_restarts.rb
|
128
|
+
- test/test_resultsreader.rb
|
129
|
+
- test/test_roles.rb
|
130
|
+
- test/test_saved_searches.rb
|
131
|
+
- test/test_service.rb
|
132
|
+
- test/test_users.rb
|
133
|
+
- test/test_xml_shim.rb
|
134
|
+
- test/testfile.txt
|
136
135
|
homepage: http://dev.splunk.com
|
137
136
|
licenses:
|
138
137
|
- APL2
|
@@ -153,7 +152,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
153
152
|
version: '0'
|
154
153
|
requirements: []
|
155
154
|
rubyforge_project:
|
156
|
-
rubygems_version: 2.
|
155
|
+
rubygems_version: 2.2.1
|
157
156
|
signing_key:
|
158
157
|
specification_version: 4
|
159
158
|
summary: Ruby bindings to Splunk REST layer
|
data/examples/run_examples.rb~
DELETED
@@ -1,22 +0,0 @@
|
|
1
|
-
#--
|
2
|
-
# Copyright 2011-2012 Splunk, Inc.
|
3
|
-
#
|
4
|
-
# Licensed under the Apache License, Version 2.0 (the "License"): you may
|
5
|
-
# not use this file except in compliance with the License. You may obtain
|
6
|
-
# a copy of the License at
|
7
|
-
#
|
8
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
9
|
-
#
|
10
|
-
# Unless required by applicable law or agreed to in writing, software
|
11
|
-
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
12
|
-
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
13
|
-
# License for the specific language governing permissions and limitations
|
14
|
-
# under the License.
|
15
|
-
#++
|
16
|
-
|
17
|
-
# This script runs all the examples shipped with the SDK, one after another,
|
18
|
-
# editing their source on the fly to set the correct login parameters for
|
19
|
-
# your Splunk instance. It pauses between each to ask if this was correct.
|
20
|
-
|
21
|
-
example_path = File.dirname(File.expand_path(__FILE__))
|
22
|
-
example_files = Dir.entries(example_path).filter() {|s| s.match('^\\d_')}
|