threaded_logging 0.2.1 → 0.2.1.15
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +10 -0
- data/.rspec +3 -0
- data/.rubocop.yml +6 -0
- data/.travis.yml +25 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +21 -0
- data/README.md +53 -0
- data/Rakefile +20 -0
- data/lib/threaded_logging/version.rb +5 -0
- data/threaded_logging.gemspec +34 -0
- metadata +17 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 83fd9d2844cd984a696a0afde0df02afa31174c8bf67ada19ce151c736a8ca37
|
4
|
+
data.tar.gz: ae8d0869e34300a72fa23a543d37753b3ec98917ad1ec0083e8112e3b0cfe8ae
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c73983ff3d4096f19de427e76740ce4305e1e0027633670ddef0a73a5df8e1a11eb58dcf995161a2f65c0381a8c6b2442274698a7b4ef13991c1d3d47d6af149
|
7
|
+
data.tar.gz: 33addf073c7f0352610287f1ecf21adf110ddd3b169637aa77df1e235cd7f7bd6fbeb898322d0740716ecec66c3b2dcfdc835f5a0d642936e02c0e7701837dbc
|
data/.gitignore
ADDED
data/.rspec
ADDED
data/.rubocop.yml
ADDED
data/.travis.yml
ADDED
@@ -0,0 +1,25 @@
|
|
1
|
+
language: ruby
|
2
|
+
sudo: false
|
3
|
+
before_install: gem install bundler
|
4
|
+
env: SUITE="rspec"
|
5
|
+
script: bundle exec $SUITE
|
6
|
+
matrix:
|
7
|
+
fast_finish: true
|
8
|
+
include:
|
9
|
+
- rvm: 2.3
|
10
|
+
- rvm: 2.4
|
11
|
+
- rvm: 2.5
|
12
|
+
- rvm: 2.6
|
13
|
+
- rvm: ruby-head
|
14
|
+
- rvm: 2.6
|
15
|
+
env: SUITE="rubocop"
|
16
|
+
allow_failures:
|
17
|
+
- rvm: ruby-head
|
18
|
+
deploy:
|
19
|
+
provider: rubygems
|
20
|
+
api_key:
|
21
|
+
secure: H6Az1Sv4grOcu8CI7+VMwgU0y+o7PVLSQ98S5W2qBWe3amVZ9mXW9Jup7fADY3lQ56hIavprKZ5dIc3cib9XnLtJJuTqh7esC6PtglxGv5HwX+2g8N6OMOTFkmIokOgGwFCncux0FwDn6XNXNTzKEKLLVlCi/wt1ySEpWmY2ywnYUnNQFX/3c+kxD7maPMEYi/iGRdds+j2OHw8hTw4hhCAIkr/xVKwuHAxp7iSuSPoLbqcaH20d+fMTiDZljNgTByGiLmGAXbiv+xNPg9DIXzC5qnBQ3OHqTKBfj1OXwt40p+mbKHSPp2PDQRc9LjaK4oCOOM6ph+8X1guWG+7o66wnzH/lT7Pf83oQf37Van76qjgEAXSASZJXNwELgC3WzIm9xC26Dbwiy3fk4H0TXI7gNrhZlsArzlK4HSHAD1Gqeq0KRSM6O5PfQt/nEDgIKLaK/w9SoGk6EAL9WWsFsnx5EAXTaSpadItezxGO0XpRYyJuBlIfspVeRH7Vi+y06eo3VQeuC3b4mpYv+m/LMGQPvtA3c8vKSI4G8+8L/OKu2yD4Jxm9m81jov5FRnlrd7JQV67SH8HuECVOcoh+mfUuciwOF99NVv5VCR4cDWMfleMQPTxLUQ2z3o3RoOMucJhDXu9gyVHGmBp5DhXY7EnHyNRmSyDBFIvJbuSNtBA=
|
22
|
+
gemspec: threaded_logging.gemspec
|
23
|
+
on:
|
24
|
+
repo: umbrellio/threaded_logging
|
25
|
+
branch: master
|
data/Gemfile
ADDED
data/LICENSE.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2017-2019 Yuri Smirnov
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,53 @@
|
|
1
|
+
# threaded_logging · [![Gem Version](https://badge.fury.io/rb/threaded_logging.svg)](https://badge.fury.io/rb/threaded_logging) [![Build Status](https://travis-ci.org/umbrellio/threaded_logging.svg?branch=master)](https://travis-ci.org/umbrellio/threaded_logging) [![Coverage Status](https://coveralls.io/repos/github/umbrellio/threaded_logging/badge.svg?branch=master)](https://coveralls.io/github/umbrellio/threaded_logging?branch=master)
|
2
|
+
|
3
|
+
This gem patches default Ruby log formatter so that every line includes a digest of current process PID + current thread id so that you can easily grep the logs of every particular thread. It also adds the metadata part to each line of the message in case it is multiline.
|
4
|
+
|
5
|
+
## Installation
|
6
|
+
|
7
|
+
```ruby
|
8
|
+
gem 'threaded_logging'
|
9
|
+
```
|
10
|
+
|
11
|
+
```shell
|
12
|
+
$ bundle install
|
13
|
+
# --- or ---
|
14
|
+
$ gem install 'threaded_logging'
|
15
|
+
```
|
16
|
+
|
17
|
+
```ruby
|
18
|
+
require 'threaded_logging'
|
19
|
+
```
|
20
|
+
|
21
|
+
## Usage
|
22
|
+
|
23
|
+
Before:
|
24
|
+
|
25
|
+
```ruby
|
26
|
+
> Logger.new(STDOUT).info("Line 1\nLine 2")
|
27
|
+
I, [2016-05-23T22:33:40.649346 #13604] INFO -- : Line 1
|
28
|
+
Line 2
|
29
|
+
```
|
30
|
+
|
31
|
+
After:
|
32
|
+
|
33
|
+
```ruby
|
34
|
+
> Logger.new(STDOUT).info("Line 1\nLine 2")
|
35
|
+
I [2016-05-23T22:32:30.483767] #bd134bb0: Line 1
|
36
|
+
I [2016-05-23T22:32:30.483767] #bd134bb0: Line 2
|
37
|
+
```
|
38
|
+
|
39
|
+
## Contributing
|
40
|
+
|
41
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/umbrellio/table_sync.
|
42
|
+
|
43
|
+
## License
|
44
|
+
|
45
|
+
Released under MIT License.
|
46
|
+
|
47
|
+
## Authors
|
48
|
+
|
49
|
+
Created by Yuri Smirnov.
|
50
|
+
|
51
|
+
<a href="https://github.com/umbrellio/">
|
52
|
+
<img style="float: left;" src="https://umbrellio.github.io/Umbrellio/supported_by_umbrellio.svg" alt="Supported by Umbrellio" width="439" height="72">
|
53
|
+
</a>
|
data/Rakefile
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "bundler/gem_tasks"
|
4
|
+
require "rspec/core/rake_task"
|
5
|
+
require "rubocop"
|
6
|
+
require "rubocop-rspec"
|
7
|
+
require "rubocop-performance"
|
8
|
+
require "rubocop/rake_task"
|
9
|
+
|
10
|
+
RuboCop::RakeTask.new(:rubocop) do |t|
|
11
|
+
config_path = File.expand_path(File.join(".rubocop.yml"), __dir__)
|
12
|
+
|
13
|
+
t.options = ["--config", config_path]
|
14
|
+
t.requires << "rubocop-rspec"
|
15
|
+
t.requires << "rubocop-performance"
|
16
|
+
end
|
17
|
+
|
18
|
+
RSpec::Core::RakeTask.new(:rspec)
|
19
|
+
|
20
|
+
task default: :rspec
|
@@ -0,0 +1,34 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
lib = File.expand_path("lib", __dir__)
|
4
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
5
|
+
require "threaded_logging/version"
|
6
|
+
|
7
|
+
Gem::Specification.new do |spec|
|
8
|
+
spec.required_ruby_version = ">= 2.3.8"
|
9
|
+
|
10
|
+
gem_version = ThreadedLogging::VERSION
|
11
|
+
release_version = ENV["TRAVIS"] ? "#{gem_version}.#{ENV["TRAVIS_BUILD_NUMBER"]}" : gem_version
|
12
|
+
|
13
|
+
spec.name = "threaded_logging"
|
14
|
+
spec.version = release_version
|
15
|
+
spec.authors = ["Yuri Smirnov"]
|
16
|
+
spec.email = ["tycoooon@gmail.com", "oss@umbrellio.biz"]
|
17
|
+
|
18
|
+
spec.summary = "Better formatter for ruby loggers."
|
19
|
+
spec.description = "Add current thread's fingerprint to all your logs."
|
20
|
+
spec.homepage = "https://github.com/umbrellio/threaded_logging"
|
21
|
+
spec.license = "MIT"
|
22
|
+
|
23
|
+
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^spec/}) }
|
24
|
+
spec.require_paths = ["lib"]
|
25
|
+
|
26
|
+
spec.add_development_dependency "bundler"
|
27
|
+
spec.add_development_dependency "coveralls"
|
28
|
+
spec.add_development_dependency "pry"
|
29
|
+
spec.add_development_dependency "rake"
|
30
|
+
spec.add_development_dependency "rspec"
|
31
|
+
spec.add_development_dependency "rubocop-config-umbrellio"
|
32
|
+
spec.add_development_dependency "simplecov"
|
33
|
+
spec.add_development_dependency "timecop"
|
34
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: threaded_logging
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.1
|
4
|
+
version: 0.2.1.15
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Yuri Smirnov
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-06-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -123,12 +123,24 @@ dependencies:
|
|
123
123
|
- !ruby/object:Gem::Version
|
124
124
|
version: '0'
|
125
125
|
description: Add current thread's fingerprint to all your logs.
|
126
|
-
email:
|
126
|
+
email:
|
127
|
+
- tycoooon@gmail.com
|
128
|
+
- oss@umbrellio.biz
|
127
129
|
executables: []
|
128
130
|
extensions: []
|
129
131
|
extra_rdoc_files: []
|
130
132
|
files:
|
133
|
+
- ".gitignore"
|
134
|
+
- ".rspec"
|
135
|
+
- ".rubocop.yml"
|
136
|
+
- ".travis.yml"
|
137
|
+
- Gemfile
|
138
|
+
- LICENSE.txt
|
139
|
+
- README.md
|
140
|
+
- Rakefile
|
131
141
|
- lib/threaded_logging.rb
|
142
|
+
- lib/threaded_logging/version.rb
|
143
|
+
- threaded_logging.gemspec
|
132
144
|
homepage: https://github.com/umbrellio/threaded_logging
|
133
145
|
licenses:
|
134
146
|
- MIT
|
@@ -141,15 +153,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
141
153
|
requirements:
|
142
154
|
- - ">="
|
143
155
|
- !ruby/object:Gem::Version
|
144
|
-
version:
|
156
|
+
version: 2.3.8
|
145
157
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
146
158
|
requirements:
|
147
159
|
- - ">="
|
148
160
|
- !ruby/object:Gem::Version
|
149
161
|
version: '0'
|
150
162
|
requirements: []
|
151
|
-
|
152
|
-
rubygems_version: 2.7.6
|
163
|
+
rubygems_version: 3.0.3
|
153
164
|
signing_key:
|
154
165
|
specification_version: 4
|
155
166
|
summary: Better formatter for ruby loggers.
|