forkr 0.1.4 → 0.1.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -0
- data/forkr.gemspec +6 -2
- data/lib/forkr.rb +3 -1
- metadata +5 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a3fe336abe0899e2eef7d722d55ad165efb4cfc9
|
4
|
+
data.tar.gz: 18aaa3777dd55743fe873b9a51eee9e055f4e5f3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9097997fb92d8ae974614681a99fa431dbfb055195e25d223d636d1b1117b49ec0c08c280d790fcd9a41d464b3e54f444b57153e4db5464cea70f5d9a3cfbad4
|
7
|
+
data.tar.gz: 9c3ef4521cfab509fd9012a07177350e905fb03deee41e33f228155647ce0591ed0a07a7237c938644bb1229f812fc4e39bcb1567890bfb7ecfa9342d2c6d5a6
|
data/README.md
CHANGED
@@ -16,6 +16,7 @@ You need to provide a single object, called a Forklet. This object must respond
|
|
16
16
|
Your run method will be invoked after forking - this is the time to close or reopen any file descriptors or the like.
|
17
17
|
|
18
18
|
In your run method, you will need to:
|
19
|
+
|
19
20
|
* Block the current thread - make sure to do this or Forkr will get confused and continue restarting your workers. It thinks they have died.
|
20
21
|
* Respond properly to the TERM, QUIT, and INT signals
|
21
22
|
|
data/forkr.gemspec
CHANGED
@@ -1,9 +1,13 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
2
|
s.name = 'forkr'
|
3
|
-
s.version = '0.1.
|
3
|
+
s.version = '0.1.5'
|
4
4
|
s.date = '2014-12-03'
|
5
5
|
s.summary = "A pre-forking worker host - shamelessly inspired by unicorn."
|
6
|
-
s.description =
|
6
|
+
s.description = <<-DESCRIPTION
|
7
|
+
Forkr is a preforking worker host, shamelessly inspired by unicorn.
|
8
|
+
|
9
|
+
It exists to easily fork and scale ruby programs which aren't rack-based.
|
10
|
+
DESCRIPTION
|
7
11
|
s.authors = ["Trey Evans"]
|
8
12
|
s.email = 'lewis.r.evans@gmail.com'
|
9
13
|
s.files = ["lib/forkr.rb", "forkr.gemspec", "README.md"]
|
data/lib/forkr.rb
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
class Forkr
|
2
|
-
attr_reader :master_pid, :
|
2
|
+
attr_reader :master_pid, :child_count, :children
|
3
3
|
|
4
4
|
def initialize(forklet, num_kids = 1)
|
5
5
|
@worker_client = forklet
|
@@ -22,6 +22,8 @@ class Forkr
|
|
22
22
|
|
23
23
|
protected
|
24
24
|
|
25
|
+
attr_reader :inbound, :outbound
|
26
|
+
|
25
27
|
def send_wake_notice(notice)
|
26
28
|
return(nil) if $$ != master_pid
|
27
29
|
return(nil) if @in_shutdown
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: forkr
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Trey Evans
|
@@ -10,7 +10,10 @@ bindir: bin
|
|
10
10
|
cert_chain: []
|
11
11
|
date: 2014-12-03 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
|
-
description:
|
13
|
+
description: |
|
14
|
+
Forkr is a preforking worker host, shamelessly inspired by unicorn.
|
15
|
+
|
16
|
+
It exists to easily fork and scale ruby programs which aren't rack-based.
|
14
17
|
email: lewis.r.evans@gmail.com
|
15
18
|
executables: []
|
16
19
|
extensions: []
|