loggerstash 0.0.5 → 0.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/lib/loggerstash.rb +8 -4
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 4f2945f9572e10047201fc9b3ac4422923e8b58b
|
4
|
+
data.tar.gz: 7652bff72a6bb80fe20fcfd1d6ffe7c55679bc8f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3c2c0be50c3a3706dca83b4e7b26c549f920c41c88fb73d0e397c1b5aa5ff99d9d89057d15d5a2adff18b3f4043b835e8a4a4474c69dc34e78a712ff3b20114e
|
7
|
+
data.tar.gz: 81d0b3da5b0ccabd57f6beaa74b43b993f33b11a23a1b2b9bb9aa3b96362043aca95626d3c0bf71ce0ad52021ce74fac3e0e1627a8bb95cca186f175098b3e6d
|
data/lib/loggerstash.rb
CHANGED
@@ -39,11 +39,12 @@ class Loggerstash
|
|
39
39
|
# that any values you've set for logstash_server and metrics_registry
|
40
40
|
# will be ignored.
|
41
41
|
#
|
42
|
-
def initialize(logstash_server:, metrics_registry: nil, formatter: nil, logstash_writer: nil)
|
43
|
-
@logstash_server
|
42
|
+
def initialize(logstash_server:, metrics_registry: nil, formatter: nil, logstash_writer: nil, logger: nil)
|
43
|
+
@logstash_server = logstash_server
|
44
44
|
@metrics_registry = metrics_registry
|
45
|
-
@formatter
|
46
|
-
@logstash_writer
|
45
|
+
@formatter = formatter
|
46
|
+
@logstash_writer = logstash_writer
|
47
|
+
@logger = logger
|
47
48
|
|
48
49
|
@op_mutex = Mutex.new
|
49
50
|
end
|
@@ -123,6 +124,9 @@ class Loggerstash
|
|
123
124
|
if @metrics_registry
|
124
125
|
opts[:metrics_registry] = @metrics_registry
|
125
126
|
end
|
127
|
+
if @logger
|
128
|
+
opts[:logger] = @logger
|
129
|
+
end
|
126
130
|
|
127
131
|
@logstash_writer = LogstashWriter.new(**opts)
|
128
132
|
@logstash_writer.run
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: loggerstash
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Matt Palmer
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-11-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: logstash_writer
|
@@ -232,7 +232,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
232
232
|
version: '0'
|
233
233
|
requirements: []
|
234
234
|
rubyforge_project:
|
235
|
-
rubygems_version: 2.
|
235
|
+
rubygems_version: 2.5.2.1
|
236
236
|
signing_key:
|
237
237
|
specification_version: 4
|
238
238
|
summary: Monkeypatch Logger to send log entries to logstash
|