serverengine 2.0.4 → 2.0.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 +3 -2
- data/Changelog +5 -0
- data/lib/serverengine/socket_manager.rb +3 -1
- data/lib/serverengine/version.rb +1 -1
- data/serverengine.gemspec +2 -1
- data/spec/socket_manager_spec.rb +16 -0
- metadata +7 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1aa31d549d06f57019a2dc0a9d318adaec5f6e49
|
4
|
+
data.tar.gz: 545d61737bcbf890287b2109c6c5109b03eb275e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4727c3d98b63e332184033a03de5b4359a01778053ef84a4bac8e1b82f4f21f952e58947b7e1cd4feb6c393c817e5ffcd4beddf46d078eeeaf7a0055cea9982e
|
7
|
+
data.tar.gz: b1c191dd0844c1b27e91954cf3400d142ae3953e8e86093c38870a13b9c00e53b9b9b1d859eaaa803123601737804586023d65386c8a71ca25cbb978733a9a80
|
data/.travis.yml
CHANGED
data/Changelog
CHANGED
@@ -1,3 +1,8 @@
|
|
1
|
+
2017-03-01 version 2.0.5:
|
2
|
+
|
3
|
+
* Support SERVERENGINE_SOCKETMANAGER_SOCK_DIR environment variable to change
|
4
|
+
base directory of SocketManager's socket path
|
5
|
+
|
1
6
|
2016-11-24 version 2.0.4:
|
2
7
|
|
3
8
|
* Fix bug to crash Ruby VM when SocketManager fails to bind IPv6 addresses on Windows
|
@@ -17,6 +17,7 @@
|
|
17
17
|
#
|
18
18
|
require 'socket'
|
19
19
|
require 'ipaddr'
|
20
|
+
require 'time'
|
20
21
|
|
21
22
|
module ServerEngine
|
22
23
|
module SocketManager
|
@@ -68,7 +69,8 @@ module ServerEngine
|
|
68
69
|
end
|
69
70
|
end
|
70
71
|
else
|
71
|
-
|
72
|
+
base_dir = (ENV['SERVERENGINE_SOCKETMANAGER_SOCK_DIR'] || '/tmp')
|
73
|
+
File.join(base_dir, 'SERVERENGINE_SOCKETMANAGER_' + Time.now.utc.iso8601 + '_' + Process.pid.to_s)
|
72
74
|
end
|
73
75
|
end
|
74
76
|
|
data/lib/serverengine/version.rb
CHANGED
data/serverengine.gemspec
CHANGED
@@ -21,7 +21,8 @@ Gem::Specification.new do |gem|
|
|
21
21
|
|
22
22
|
gem.add_dependency "sigdump", ["~> 0.2.2"]
|
23
23
|
|
24
|
-
|
24
|
+
# rake v12.x doesn't work with rspec 2. rspec should be updated to 3
|
25
|
+
gem.add_development_dependency "rake", ["~> 11.0"]
|
25
26
|
gem.add_development_dependency "rspec", ["~> 2.13.0"]
|
26
27
|
|
27
28
|
gem.add_development_dependency 'rake-compiler-dock', ['~> 0.5.0']
|
data/spec/socket_manager_spec.rb
CHANGED
@@ -19,6 +19,22 @@ describe ServerEngine::SocketManager do
|
|
19
19
|
File.unlink(server_path) if server_path.is_a?(String) && File.exist?(server_path)
|
20
20
|
end
|
21
21
|
|
22
|
+
if !ServerEngine.windows?
|
23
|
+
context 'Server.generate_path' do
|
24
|
+
it 'returns socket path under /tmp' do
|
25
|
+
path = SocketManager::Server.generate_path
|
26
|
+
expect(path).to include('/tmp/SERVERENGINE_SOCKETMANAGER_')
|
27
|
+
end
|
28
|
+
|
29
|
+
it 'can be changed via environment variable' do
|
30
|
+
ENV['SERVERENGINE_SOCKETMANAGER_SOCK_DIR'] = '/tmp/foo'
|
31
|
+
path = SocketManager::Server.generate_path
|
32
|
+
expect(path).to include('/tmp/foo/SERVERENGINE_SOCKETMANAGER_')
|
33
|
+
ENV.delete('SERVERENGINE_SOCKETMANAGER_SOCK_DIR')
|
34
|
+
end
|
35
|
+
end
|
36
|
+
end
|
37
|
+
|
22
38
|
context 'with thread' do
|
23
39
|
context 'using ipv4' do
|
24
40
|
it 'works' do
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: serverengine
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sadayuki Furuhashi
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2017-03-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: sigdump
|
@@ -28,16 +28,16 @@ dependencies:
|
|
28
28
|
name: rake
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - "
|
31
|
+
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 0
|
33
|
+
version: '11.0'
|
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
|
-
version: 0
|
40
|
+
version: '11.0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: rspec
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -154,7 +154,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
154
154
|
version: '0'
|
155
155
|
requirements: []
|
156
156
|
rubyforge_project:
|
157
|
-
rubygems_version: 2.
|
157
|
+
rubygems_version: 2.6.8
|
158
158
|
signing_key:
|
159
159
|
specification_version: 4
|
160
160
|
summary: ServerEngine - multiprocess server framework
|
@@ -169,4 +169,3 @@ test_files:
|
|
169
169
|
- spec/socket_manager_spec.rb
|
170
170
|
- spec/spec_helper.rb
|
171
171
|
- spec/supervisor_spec.rb
|
172
|
-
has_rdoc: false
|