act-fluent-logger-rails 0.1.4 → 0.1.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +4 -0
- data/CHANGELOG.md +4 -0
- data/Rakefile +5 -0
- data/lib/act-fluent-logger-rails/logger.rb +2 -2
- data/lib/act-fluent-logger-rails/version.rb +1 -1
- data/spec/logger_spec.rb +7 -5
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b8948529fa64435096f9be2f85e103b34268652a
|
4
|
+
data.tar.gz: 588ce44194197d65ca7528941e931107296bd255
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 207a1c5007dca5360349c02224f70a95398fa9fa17a9d702cb94a2708a2e005cde466011f5df88de16df6a3bc7c995d068268b0f8527b3b589fd39396aa6e994
|
7
|
+
data.tar.gz: 9249a4c66f68484277066328e07e5a457f4a28e411497400cb170a798f8a0bc12992e03859c99e0d9efe96d06736e60352bbe390a6dcfda844fa8576ca6c8e87
|
data/.travis.yml
ADDED
data/CHANGELOG.md
CHANGED
data/Rakefile
CHANGED
@@ -35,8 +35,8 @@ module ActFluentLoggerRails
|
|
35
35
|
params = CGI.parse uri.query
|
36
36
|
|
37
37
|
{
|
38
|
-
|
39
|
-
|
38
|
+
fluent_host: uri.host,
|
39
|
+
fluent_port: uri.port,
|
40
40
|
tag: uri.path[1..-1],
|
41
41
|
messages_type: params["messages_type"].try(:first)
|
42
42
|
}.stringify_keys
|
data/spec/logger_spec.rb
CHANGED
@@ -5,9 +5,11 @@ require 'tempfile'
|
|
5
5
|
describe ActFluentLoggerRails::Logger do
|
6
6
|
before do
|
7
7
|
|
8
|
-
|
9
|
-
|
10
|
-
|
8
|
+
unless self.class.const_defined?(:Rails)
|
9
|
+
Rails = double("Rails", env: "test")
|
10
|
+
Rails.stub_chain(:application, :config, :log_level).and_return(:debug)
|
11
|
+
Rails.stub_chain(:application, :config, :log_tags=)
|
12
|
+
end
|
11
13
|
|
12
14
|
class MyLogger
|
13
15
|
attr_accessor :log
|
@@ -71,8 +73,8 @@ EOF
|
|
71
73
|
describe ".parse_url" do
|
72
74
|
subject { described_class.parse_url(fluentd_url) }
|
73
75
|
it { expect(subject['tag']).to eq 'hoge' }
|
74
|
-
it { expect(subject['
|
75
|
-
it { expect(subject['
|
76
|
+
it { expect(subject['fluent_host']).to eq 'fluentd.example.com' }
|
77
|
+
it { expect(subject['fluent_port']).to eq 42442 }
|
76
78
|
it { expect(subject['messages_type']).to eq 'string' }
|
77
79
|
end
|
78
80
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: act-fluent-logger-rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- TAHARA Yoshinori
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-07-
|
11
|
+
date: 2014-07-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|
@@ -66,6 +66,7 @@ extensions: []
|
|
66
66
|
extra_rdoc_files: []
|
67
67
|
files:
|
68
68
|
- ".gitignore"
|
69
|
+
- ".travis.yml"
|
69
70
|
- CHANGELOG.md
|
70
71
|
- Gemfile
|
71
72
|
- LICENSE.txt
|