process_safe_logger 0.1.0 → 0.2.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 85efddfa248dd513471e22b9f6bcd61f10cc831c
4
- data.tar.gz: acebb65714e21fd05b62ce88fef2deb907aef1ed
3
+ metadata.gz: f7ade1c071ef1a702223be22f4267052372b9193
4
+ data.tar.gz: d1804c630f082f57a277892f763209ad2fcc52e2
5
5
  SHA512:
6
- metadata.gz: 68ee62bad0557f9fab0f3667e3349efb27e2eebcd0d95cbc586bccc958f3d2f54968d7c50a65af67efe6d28fb32c4a31c7c8b48a2ab311e1802860d07a526f30
7
- data.tar.gz: 3e83568c498d45670e7583f2aa3bcec9913fd09948408e7e4942d55121009199e886edff011c8edfa0abe0e0fe8a44f44a3e4ac866f586b61284e8aa7fbbf40d
6
+ metadata.gz: bf503f2c5c7b03ea181bb4a9d2fa3017281e8319d15b2f15d43b854bdf6bda6ca77bb86056357f0b57844f9b5a9dfba32a168555b4259a652dea4f0e09ca7d99
7
+ data.tar.gz: d533e1a6c423bc18145b23a6435bf6ce1d73d61c0b75dc1b1bb71867c31d12256e2b22f0440e80a37bf950bc3238319dcd93af500d114b5c8277992de8d5db16
data/.gitignore CHANGED
@@ -10,3 +10,4 @@ vendor
10
10
  doc/*
11
11
  tmp/*
12
12
  .yardoc
13
+ pkg/
data/CHANGELOG.md CHANGED
@@ -1,3 +1,9 @@
1
- # 0.0.1
1
+ # 0.2.0
2
+
3
+ Fixes:
4
+
5
+ * Apply fix from https://bugs.ruby-lang.org/issues/9133 (@daifu)
6
+
7
+ # 0.1.0
2
8
 
3
9
  Initial Release
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Process Safe Logger [![Build Status](https://secure.travis-ci.org/sonots/process_safe_logger.png?branch=master)](http://travis-ci.org/sonots/process_safe_logger) [![Dependency Status](https://gemnasium.com/sonots/process_safe_logger.png)](https://gemnasium.com/sonots/process_safe_logger)
2
2
 
3
- testing ruby: 1.9.2, 1.9.3, 2.0.0;
3
+ testing ruby: 1.9.3, 2.0.0;
4
4
 
5
5
  ## About Process Safe Logger
6
6
 
@@ -10,7 +10,7 @@ Process Safe Logger supports log rotations in multi-processes *safely*.
10
10
 
11
11
  Ruby's standard Logger class originally have had a problem that it's log rotation function does not work safely in multi process environment. This gem fixes the problem.
12
12
 
13
- The patch is already pull requested to the [githb.com:ruby/ruby](https://github.com/ruby/ruby/pull/428) and will be released with ruby 2.1.0.
13
+ The patch is already pull requested to the [github.com:ruby/ruby](https://github.com/ruby/ruby/pull/428) and will be released with ruby 2.1.0.
14
14
 
15
15
  ## Installation
16
16
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.0
1
+ 0.2.0
@@ -75,8 +75,7 @@ else
75
75
  begin
76
76
  File.open(@filename, File::WRONLY | File::APPEND) do |lock|
77
77
  lock.flock(File::LOCK_EX) # inter-process locking. will be unlocked at closing file
78
- ino = lock.stat.ino
79
- if ino == File.stat(@filename).ino
78
+ if File.identical?(@filename, lock) and File.identical?(lock, @dev)
80
79
  yield # log shifting
81
80
  else
82
81
  # log shifted by another process (i-node before locking and i-node after locking are different)
metadata CHANGED
@@ -1,69 +1,69 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: process_safe_logger
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Naotoshi Seo
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-11-04 00:00:00.000000000 Z
11
+ date: 2015-05-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '>='
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: '0'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - '>='
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: '0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rspec
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - ~>
31
+ - - "~>"
32
32
  - !ruby/object:Gem::Version
33
33
  version: '2.11'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - ~>
38
+ - - "~>"
39
39
  - !ruby/object:Gem::Version
40
40
  version: '2.11'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: pry
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - '>='
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
47
  version: '0'
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - '>='
52
+ - - ">="
53
53
  - !ruby/object:Gem::Version
54
54
  version: '0'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: pry-nav
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - '>='
59
+ - - ">="
60
60
  - !ruby/object:Gem::Version
61
61
  version: '0'
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - '>='
66
+ - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
69
  description: Process-safe Logger supports log rotations in multi-processes safely
@@ -73,10 +73,10 @@ executables: []
73
73
  extensions: []
74
74
  extra_rdoc_files: []
75
75
  files:
76
- - .gitignore
77
- - .pryrc
78
- - .rspec
79
- - .travis.yml
76
+ - ".gitignore"
77
+ - ".pryrc"
78
+ - ".rspec"
79
+ - ".travis.yml"
80
80
  - CHANGELOG.md
81
81
  - Gemfile
82
82
  - LICENSE
@@ -99,17 +99,17 @@ require_paths:
99
99
  - lib
100
100
  required_ruby_version: !ruby/object:Gem::Requirement
101
101
  requirements:
102
- - - '>='
102
+ - - ">="
103
103
  - !ruby/object:Gem::Version
104
104
  version: '0'
105
105
  required_rubygems_version: !ruby/object:Gem::Requirement
106
106
  requirements:
107
- - - '>='
107
+ - - ">="
108
108
  - !ruby/object:Gem::Version
109
109
  version: '0'
110
110
  requirements: []
111
111
  rubyforge_project:
112
- rubygems_version: 2.0.3
112
+ rubygems_version: 2.4.5
113
113
  signing_key:
114
114
  specification_version: 4
115
115
  summary: Process-safe Logger supports log rotations in multi-processes safely