fluent-plugin-loggly 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 +4 -4
- data/README.md +5 -16
- data/fluent-plugin-loggly.gemspec +1 -1
- data/lib/fluent-plugin-loggly/version.rb +1 -1
- data/lib/fluent/plugin/out_loggly.rb +1 -1
- data/lib/fluent/plugin/out_loggly_buffered.rb +2 -2
- 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: 761875401f1eb1ee4ac9bc1f3ded3b9b47272a2d
|
4
|
+
data.tar.gz: 8a8af3f4ee035bd7ee8f1db41078d82403796c2f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 445b44a387e1701e4663d0520ca20332a3c167f0049c36c4f4de8c62f7cb3b17c433fa4a81cc6b328059a0d227ed81f5b92ac5695090d2bfb0e02ac107395b75
|
7
|
+
data.tar.gz: 39a8cbbe5778ac4becb889b1258795c43c2ad84a537ff2fd069e138820b0285551d51bde843263eb70fb6f94053fa6057bbeffd6d53662b4db311e15f60fa145
|
data/README.md
CHANGED
@@ -2,7 +2,7 @@ Loggly plugin for [Fluentd](http://www.fluentd.org)
|
|
2
2
|
=============
|
3
3
|
With fluent-plugin-loggly you will be able to use [Loggly](http://loggly.com) as output the logs you collect with Fluentd.
|
4
4
|
|
5
|
-
## Getting Started
|
5
|
+
## Getting Started
|
6
6
|
* Install [Fluentd](http://www.fluentd.org/download)
|
7
7
|
* gem install fluent-plugin-loggly
|
8
8
|
* Make sure you have an account with Loggly.
|
@@ -13,7 +13,7 @@ With fluent-plugin-loggly you will be able to use [Loggly](http://loggly.com) as
|
|
13
13
|
loggly_url https://logs-01.loggly.com/inputs/xxx-xxxx-xxxx-xxxxx-xxxxxxxxxx
|
14
14
|
</match>
|
15
15
|
~~~~~
|
16
|
-
|
16
|
+
or if you want to use buffered plugin:
|
17
17
|
~~~~~
|
18
18
|
<match your_match>
|
19
19
|
type loggly_buffered
|
@@ -24,21 +24,10 @@ With fluent-plugin-loggly you will be able to use [Loggly](http://loggly.com) as
|
|
24
24
|
flush_interval 10s
|
25
25
|
</match>
|
26
26
|
~~~~~
|
27
|
-
|
28
|
-
|
29
|
-
The `xxx-xxxx...` is your Loggly access token.
|
30
|
-
|
31
|
-
## Getting Started for Gen 1
|
32
|
-
|
33
|
-
* Install fluentd http://fluentd.org
|
34
|
-
* gem install fluent-plugin-loggly
|
35
|
-
* Make sure you have an account at loggly.com.
|
36
|
-
* Create a input.
|
37
|
-
* Choose service type: HTTP
|
38
|
-
* JSON logging: true
|
39
|
-
* Get the url that could by used to do HTTPS POST (this will be used for configuration of the plugin).
|
40
|
-
It should be something like https://logs.loggly.com/inputs/xxx-xxxx-xxxx-xxxxx-xxxxxxxxxx
|
27
|
+
|
28
|
+
Note that buffered plugin uses bulk import to improve performance, so make sure to set Bulk endpoint to loggly_url.
|
41
29
|
|
30
|
+
The `xxx-xxxx...` is your Loggly access token.
|
42
31
|
|
43
32
|
## Parameters
|
44
33
|
**loggly_url** the url to your loggly input (string).
|
@@ -3,7 +3,7 @@ $:.push File.expand_path("../lib", __FILE__)
|
|
3
3
|
|
4
4
|
Gem::Specification.new do |s|
|
5
5
|
s.name = "fluent-plugin-loggly"
|
6
|
-
s.version = "0.0.
|
6
|
+
s.version = "0.0.6"
|
7
7
|
s.authors = ["Patrik Antonsson"]
|
8
8
|
s.email = ["patant@gmail.com"]
|
9
9
|
s.homepage = "https://github.com/patant/fluent-plugin-loggly"
|
@@ -34,7 +34,7 @@ class LogglyOutput < Fluent::Output
|
|
34
34
|
super
|
35
35
|
require 'net/http/persistent'
|
36
36
|
@uri = URI @loggly_url
|
37
|
-
@http = Net::HTTP::Persistent.new 'fluentd-plugin-loggly'
|
37
|
+
@http = Net::HTTP::Persistent.new 'fluentd-plugin-loggly', :ENV
|
38
38
|
@http.headers['Content-Type'] = 'application/json'
|
39
39
|
end
|
40
40
|
|
@@ -39,7 +39,7 @@ class LogglyOutputBuffred < Fluent::BufferedOutput
|
|
39
39
|
super
|
40
40
|
require 'net/http/persistent'
|
41
41
|
@uri = URI @loggly_url
|
42
|
-
@http = Net::HTTP::Persistent.new 'fluentd-plugin-loggly'
|
42
|
+
@http = Net::HTTP::Persistent.new 'fluentd-plugin-loggly', :ENV
|
43
43
|
@http.headers['Content-Type'] = 'text'
|
44
44
|
end
|
45
45
|
|
@@ -54,7 +54,7 @@ class LogglyOutputBuffred < Fluent::BufferedOutput
|
|
54
54
|
def write(chunk)
|
55
55
|
records = []
|
56
56
|
chunk.msgpack_each {|tag,time,record|
|
57
|
-
record['timestamp']
|
57
|
+
record['timestamp'] ||= Time.at(time).iso8601 if @output_include_time
|
58
58
|
records.push(record.to_json)
|
59
59
|
}
|
60
60
|
$log.debug "#{records.length} records sent"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fluent-plugin-loggly
|
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
|
- Patrik Antonsson
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-07-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: net-http-persistent
|