key_value_logging 0.0.1 → 0.0.2
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.
- data/README.md +4 -0
- data/key_value_logging.gemspec +1 -0
- data/lib/key_value_logging/railtie.rb +6 -4
- data/lib/key_value_logging/version.rb +1 -1
- metadata +4 -3
data/README.md
CHANGED
@@ -58,3 +58,7 @@ now provide a hash with key and value:
|
|
58
58
|
3. Commit your changes (`git commit -am 'Add some feature'`)
|
59
59
|
4. Push to the branch (`git push origin my-new-feature`)
|
60
60
|
5. Create new Pull Request
|
61
|
+
|
62
|
+
## License
|
63
|
+
|
64
|
+
This gem is released under the [MIT License](http://www.opensource.org/licenses/MIT).
|
data/key_value_logging.gemspec
CHANGED
@@ -6,6 +6,7 @@ require 'key_value_logging/version'
|
|
6
6
|
Gem::Specification.new do |gem|
|
7
7
|
gem.name = "key_value_logging"
|
8
8
|
gem.version = KeyValueLogging::VERSION
|
9
|
+
gem.license = 'MIT'
|
9
10
|
gem.authors = ["Maximilian Schulz"]
|
10
11
|
gem.email = ["m.schulz@kulturfluss.de"]
|
11
12
|
gem.description = %q{KeyValue based replacement for rails TaggedLogging}
|
@@ -9,9 +9,11 @@ module KeyValueLogging
|
|
9
9
|
|
10
10
|
# Add custom logging middleware, after the logger is initialized
|
11
11
|
initializer "key_value_logging_railtie.configure_rails_initialization", after: :initialize_logger do |app|
|
12
|
-
|
13
|
-
|
14
|
-
|
12
|
+
if defined?(ActiveSupport::BufferedLogger)
|
13
|
+
# Apply monkey patch to BufferedLogger to allow to set a formatter
|
14
|
+
require 'formatted_rails_logger'
|
15
|
+
FormattedRailsLogger.patch_rails
|
16
|
+
end
|
15
17
|
|
16
18
|
logger = Rails.logger
|
17
19
|
|
@@ -28,4 +30,4 @@ module KeyValueLogging
|
|
28
30
|
app.middleware.use KeyValueLogging::LoggerMiddleware, config.key_value_logging.tags
|
29
31
|
end
|
30
32
|
end
|
31
|
-
end
|
33
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: key_value_logging
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.2
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-08-
|
12
|
+
date: 2013-08-19 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|
@@ -114,7 +114,8 @@ files:
|
|
114
114
|
- spec/spec_helper.rb
|
115
115
|
- spec/tagged_logging_spec.rb
|
116
116
|
homepage: https://github.com/railslove/key_value_logging
|
117
|
-
licenses:
|
117
|
+
licenses:
|
118
|
+
- MIT
|
118
119
|
post_install_message:
|
119
120
|
rdoc_options: []
|
120
121
|
require_paths:
|