theine2 1.0.1 → 1.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/theine_start +9 -0
- data/bin/theine_stop +10 -0
- data/lib/theine/config.rb +8 -0
- data/lib/theine/server.rb +4 -4
- data/lib/theine/worker.rb +2 -3
- metadata +7 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c482aaf0dd5830e9f49a584ab4da6b7798efd0d91e8fbf237b28f248b653caa4
|
4
|
+
data.tar.gz: 8e0ced1eab6f3d02736d4407d8849c6003945407f9b906699e1cbfc8f61af3e7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: de82c0ebcbb7bb8e5630ae7eb93edc5b3f44c4a23b3800a30c063b99365b35faeaa02860dcc061e6ec60b546fe573c64b70094fa32e557e78bd97a71e3669ffa
|
7
|
+
data.tar.gz: fc08f09de1348514d6838d0e5e8b0c7a5e183731ea5741894d0bf63fb716c1d1ea7aea81c994b84b2c056a17b3ccc89ef78b303d6c304581224e570de91253f3
|
data/bin/theine_start
ADDED
data/bin/theine_stop
ADDED
data/lib/theine/config.rb
CHANGED
data/lib/theine/server.rb
CHANGED
@@ -26,7 +26,7 @@ module Theine
|
|
26
26
|
def add_worker
|
27
27
|
path = File.expand_path('../worker.rb', __FILE__)
|
28
28
|
port = @workers_mutex.synchronize { @available_ports.shift }
|
29
|
-
puts "(
|
29
|
+
puts "(spawning worker #{"#{port} #{debug}".strip})" if !config.silent
|
30
30
|
spawn("screen", "-d", "-m", "-S", worker_session_name(port),
|
31
31
|
"sh", "-c",
|
32
32
|
"jruby #{debug} #{path} #{config.base_port.to_s} #{port.to_s} #{config.rails_root}")
|
@@ -44,7 +44,7 @@ module Theine
|
|
44
44
|
end
|
45
45
|
|
46
46
|
def worker_boot(port)
|
47
|
-
puts "
|
47
|
+
puts "(booting worker #{port})" if !config.silent
|
48
48
|
|
49
49
|
@workers_mutex.synchronize do
|
50
50
|
@spawning_workers.delete(port)
|
@@ -53,7 +53,7 @@ module Theine
|
|
53
53
|
end
|
54
54
|
|
55
55
|
def worker_done(port)
|
56
|
-
puts "
|
56
|
+
puts "(removing worker #{port})" if !config.silent
|
57
57
|
@workers_mutex.synchronize do
|
58
58
|
@workers_in_use.delete(port)
|
59
59
|
@available_ports << port
|
@@ -104,7 +104,7 @@ module Theine
|
|
104
104
|
end
|
105
105
|
private
|
106
106
|
def kill_worker(port)
|
107
|
-
print "
|
107
|
+
print "(stopping worker - #{port})" if !config.silent
|
108
108
|
worker_pid = @worker_pids[port]
|
109
109
|
worker_pid ||= DRbObject.new_with_uri("druby://localhost:#{port}").pid
|
110
110
|
system("kill -9 #{worker_pid} > /dev/null 2>&1")
|
data/lib/theine/worker.rb
CHANGED
@@ -139,13 +139,12 @@ module Theine
|
|
139
139
|
end
|
140
140
|
|
141
141
|
def rails_reload!
|
142
|
-
if
|
142
|
+
if defined? ActiveSupport::Reloader
|
143
143
|
Rails.application.reloader.reload!
|
144
|
-
Rails.application.reloader.prepare!
|
145
144
|
else
|
146
145
|
ActionDispatch::Reloader.cleanup!
|
147
146
|
ActionDispatch::Reloader.prepare!
|
148
|
-
end
|
147
|
+
end
|
149
148
|
end
|
150
149
|
|
151
150
|
def start_service
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: theine2
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jan Berdajs
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2019-
|
12
|
+
date: 2019-12-01 00:00:00.000000000 Z
|
13
13
|
dependencies: []
|
14
14
|
description: A Rails preloader for JRuby
|
15
15
|
email: ron.a.williams@gmail.com
|
@@ -18,6 +18,8 @@ executables:
|
|
18
18
|
- theine_current_ruby
|
19
19
|
- theine_server
|
20
20
|
- theine_set_ruby
|
21
|
+
- theine_start
|
22
|
+
- theine_stop
|
21
23
|
extensions: []
|
22
24
|
extra_rdoc_files: []
|
23
25
|
files:
|
@@ -25,6 +27,8 @@ files:
|
|
25
27
|
- bin/theine_current_ruby
|
26
28
|
- bin/theine_server
|
27
29
|
- bin/theine_set_ruby
|
30
|
+
- bin/theine_start
|
31
|
+
- bin/theine_stop
|
28
32
|
- lib/theine.rb
|
29
33
|
- lib/theine/client.rb
|
30
34
|
- lib/theine/config.rb
|
@@ -49,8 +53,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
49
53
|
- !ruby/object:Gem::Version
|
50
54
|
version: '0'
|
51
55
|
requirements: []
|
52
|
-
|
53
|
-
rubygems_version: 2.7.10
|
56
|
+
rubygems_version: 3.0.6
|
54
57
|
signing_key:
|
55
58
|
specification_version: 4
|
56
59
|
summary: Theine2
|