event_logger_rails 0.3.0 → 0.3.1
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 +4 -4
- data/README.md +11 -0
- data/lib/event_logger_rails/json_logger.rb +2 -0
- data/lib/event_logger_rails/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 13e98d21b691d869d533906e17ff9cd6b7cc4dc9fe53c3956233659c7b8f2f5b
|
|
4
|
+
data.tar.gz: e8320f015f1e3840304c532b7bd951676a36e5cedca3d7b2967d3a40119a36a1
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0c892160afbb1b52c6875605bb9c578db3cb03b28b074bdd08d611753b62593edf7cafbf5dbe7928022f4dae22b55a4889ef20711aac6a460bfda2618f383527
|
|
7
|
+
data.tar.gz: af73afed340dcdd9a296fd86fec42574c05f4bb47171c3a0c43d9f0247faba8aebf86d2004d50447074bb89ca956b5bbbc7f1fd8ef2613944ec04e453a7ed842
|
data/README.md
CHANGED
|
@@ -344,6 +344,17 @@ Rails.application.configure do |config|
|
|
|
344
344
|
end
|
|
345
345
|
```
|
|
346
346
|
|
|
347
|
+
You can also configure the Rails logger to use `EventLoggerRails::JsonLogger` to render structured logs in JSON format with the additional app and request data.
|
|
348
|
+
|
|
349
|
+
```ruby
|
|
350
|
+
Rails.application.configure do
|
|
351
|
+
config.colorize_logging = false
|
|
352
|
+
config.log_level = ENV.fetch('RAILS_LOG_LEVEL', :info)
|
|
353
|
+
logger = EventLoggerRails::JsonLogger.new($stdout)
|
|
354
|
+
config.logger = ActiveSupport::TaggedLogging.new(logger)
|
|
355
|
+
end
|
|
356
|
+
```
|
|
357
|
+
|
|
347
358
|
## Contributing
|
|
348
359
|
|
|
349
360
|
Your inputs echo in this realm. Venture forth and materialize your thoughts through a PR.
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: event_logger_rails
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.3.
|
|
4
|
+
version: 0.3.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Dick Davis
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2023-10-
|
|
11
|
+
date: 2023-10-14 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rails
|