zbatery 0.0.0 → 0.1.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.
- data/.document +1 -0
- data/.manifest +1 -0
- data/ChangeLog +37 -21
- data/FAQ +42 -0
- data/GIT-VERSION-FILE +1 -1
- data/GIT-VERSION-GEN +1 -1
- data/GNUmakefile +2 -2
- data/NEWS +6 -0
- data/README +9 -3
- data/lib/zbatery.rb +7 -2
- data/zbatery.gemspec +1 -1
- metadata +8 -3
data/.manifest
CHANGED
data/ChangeLog
CHANGED
@@ -1,35 +1,51 @@
|
|
1
|
-
ChangeLog from git://git.bogomips.org/zbatery.git ()
|
1
|
+
ChangeLog from git://git.bogomips.org/zbatery.git (v0.0.0..v0.1.0)
|
2
2
|
|
3
|
-
commit
|
3
|
+
commit c2ece58e13107983b726b83c5cfe798ff71034ca
|
4
4
|
Author: Eric Wong <normalperson@yhbt.net>
|
5
|
-
Date:
|
5
|
+
Date: Tue Dec 22 14:56:37 2009 -0800
|
6
6
|
|
7
|
-
|
7
|
+
Zbatery 0.1.0
|
8
|
+
|
9
|
+
This gem release allows compatibility with newer versions of
|
10
|
+
Rainbows! This also fixes a bug when $stdout is not redirected
|
11
|
+
to a file.
|
12
|
+
|
13
|
+
commit c17e73cde38365774bc73dae1a1ece00afde77d3
|
14
|
+
Author: Eric Wong <normalperson@yhbt.net>
|
15
|
+
Date: Tue Dec 22 12:51:54 2009 -0800
|
16
|
+
|
17
|
+
ficks speling eror in README
|
8
18
|
|
9
|
-
commit
|
19
|
+
commit 35f7422b3c568b677960d2e1c0f6f6fa98882f02
|
10
20
|
Author: Eric Wong <normalperson@yhbt.net>
|
11
|
-
Date:
|
21
|
+
Date: Mon Dec 21 14:14:28 2009 -0800
|
12
22
|
|
13
|
-
|
23
|
+
GNUmakefile: releases push tgz to Rubyforge
|
14
24
|
|
15
|
-
commit
|
25
|
+
commit 64d95504ff2f00e5bf6ad1acff53bd7175bb2035
|
16
26
|
Author: Eric Wong <normalperson@yhbt.net>
|
17
|
-
Date:
|
27
|
+
Date: Tue Dec 15 23:54:38 2009 -0800
|
18
28
|
|
19
|
-
|
29
|
+
avoid breaking user switching with a single process
|
20
30
|
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
31
|
+
$stdout may not have been a chown-able file descriptor,
|
32
|
+
so throw in a dummy object there that absorbs chown calls.
|
33
|
+
|
34
|
+
commit b7ade93403021c989bf9258b29a549b0e7f3692e
|
35
|
+
Author: Eric Wong <normalperson@yhbt.net>
|
36
|
+
Date: Tue Dec 15 00:18:59 2009 -0800
|
37
|
+
|
38
|
+
doc: update README, add FAQ
|
25
39
|
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
unreloadable.
|
40
|
+
* make it clear we depend on Unicorn and Rainbows!
|
41
|
+
* point out Sunshowers
|
42
|
+
* add FAQ
|
30
43
|
|
31
|
-
commit
|
44
|
+
commit 95c6af7c3adc097622c5958b7c1eb33ca6bbfeac
|
32
45
|
Author: Eric Wong <normalperson@yhbt.net>
|
33
|
-
Date:
|
46
|
+
Date: Sun Dec 13 01:28:29 2009 -0800
|
34
47
|
|
35
|
-
|
48
|
+
gemspec: relax Rainbows! dependency
|
49
|
+
|
50
|
+
We do not expect Rainbows! internals we depend on to change
|
51
|
+
significantly before Rainbows! 1.0.0.
|
data/FAQ
ADDED
@@ -0,0 +1,42 @@
|
|
1
|
+
= Frequently Asked Questions about Zbatery
|
2
|
+
|
3
|
+
Be sure to check out the Rainbows!
|
4
|
+
{FAQ}[http://rainbows.rubyforge.org/FAQ.html] and the Unicorn
|
5
|
+
{FAQ}[http://unicorn.bogomips.org/FAQ.html] as well.
|
6
|
+
|
7
|
+
|
8
|
+
=== Mongrel -> Unicorn -> Rainbows! -> Zbatery. Why another server?
|
9
|
+
|
10
|
+
Not everybody can afford to run a master process or multiple worker
|
11
|
+
processes. Nor do they need all the Unix signals support from
|
12
|
+
Rainbows!/Unicorn. We hope this is actually a temporary project that
|
13
|
+
can eventually be folded back into Mongrel.
|
14
|
+
|
15
|
+
|
16
|
+
=== Why not stick to Mongrel?
|
17
|
+
|
18
|
+
Unfortunately Mongrel 2.x development has stalled and the majority of
|
19
|
+
the team is busy with other projects. However, Unicorn and Rainbows!
|
20
|
+
development continues with less concern for portability.
|
21
|
+
|
22
|
+
Rainbows! is the only Ruby web server we know of that supports a wide
|
23
|
+
variety of concurrency models, so we decided to take advantage of
|
24
|
+
the options Rainbows! provides instead of being tied to one.
|
25
|
+
|
26
|
+
|
27
|
+
=== What's Rack? Do you support Rails?
|
28
|
+
|
29
|
+
{Rack}[http://rack.rubyforge.org/] is a minimal specification between
|
30
|
+
Ruby web servers (e.g. Mongrel, Zbatery) and Ruby web frameworks (e.g.
|
31
|
+
Rails, Sinatra, Camping). Instead of requiring a new handler for every
|
32
|
+
framework a server wants to support, web servers only need to support
|
33
|
+
Rack. As of late 2009, all major Ruby web frameworks are built on top
|
34
|
+
of Rack, including Rails.
|
35
|
+
|
36
|
+
|
37
|
+
=== What platforms are supported?
|
38
|
+
|
39
|
+
Any platform running matz's Ruby 1.8 or 1.9 should work with Zbatery.
|
40
|
+
We have not tested on anything other than GNU/Linux and FreeBSD, so
|
41
|
+
please let us know of your success/failure stories. Rubinius 1.0.0rc1
|
42
|
+
appears to work, too (if you're using Unicorn 0.95.2 or later).
|
data/GIT-VERSION-FILE
CHANGED
@@ -1 +1 @@
|
|
1
|
-
GIT_VERSION = 0.
|
1
|
+
GIT_VERSION = 0.1.0
|
data/GIT-VERSION-GEN
CHANGED
data/GNUmakefile
CHANGED
@@ -58,7 +58,7 @@ NEWS: GIT-VERSION-FILE
|
|
58
58
|
$(RAKE) -s news_rdoc > $@+
|
59
59
|
mv $@+ $@
|
60
60
|
|
61
|
-
SINCE =
|
61
|
+
SINCE = 0.0.0
|
62
62
|
ChangeLog: LOG_VERSION = \
|
63
63
|
$(shell git rev-parse -q "$(GIT_VERSION)" >/dev/null 2>&1 && \
|
64
64
|
echo $(GIT_VERSION) || git describe)
|
@@ -151,7 +151,7 @@ package: $(pkgtgz) $(pkggem)
|
|
151
151
|
release: verify package $(release_notes) $(release_changes)
|
152
152
|
# make tgz release on RubyForge
|
153
153
|
rubyforge add_release -f -n $(release_notes) -a $(release_changes) \
|
154
|
-
$(rfproject) $(rfpackage) $(VERSION) $(
|
154
|
+
$(rfproject) $(rfpackage) $(VERSION) $(pkgtgz)
|
155
155
|
# push gem to Gemcutter
|
156
156
|
gem push $(pkggem)
|
157
157
|
# in case of gem downloads from RubyForge releases page
|
data/NEWS
CHANGED
data/README
CHANGED
@@ -28,7 +28,9 @@ for basic functionality.
|
|
28
28
|
pipe and fork(). Unicorn 0.95.2+ has rake-compiler support, so
|
29
29
|
compiling the HTTP parser should be easier at least.
|
30
30
|
|
31
|
-
*
|
31
|
+
* Web Sockets support (via
|
32
|
+
{Sunshowers}[http://rainbows.rubyforge.org/sunshowers/]), requires
|
33
|
+
Rainbows! 0.9.0+
|
32
34
|
|
33
35
|
== License
|
34
36
|
|
@@ -44,7 +46,7 @@ Zbatery is 100% Free Software.
|
|
44
46
|
== Install
|
45
47
|
|
46
48
|
You may download the tarball from the Rainbows project page on Rubyforge
|
47
|
-
and run setup.rb after unpacking it:
|
49
|
+
and run setup.rb after unpacking it (and installing Unicorn and Rainbows!):
|
48
50
|
|
49
51
|
http://rubyforge.org/frs/?group_id=8977
|
50
52
|
|
@@ -52,6 +54,10 @@ You may also install it via RubyGems on Gemcutter:
|
|
52
54
|
|
53
55
|
gem install zbatery
|
54
56
|
|
57
|
+
Zbatery depends on Rainbows!, and in turn, Unicorn. Despite Unicorn and
|
58
|
+
Rainbows! being Unix-only, the Unicorn HTTP parser C extension should
|
59
|
+
build on non-Unix-like systems (unverified).
|
60
|
+
|
55
61
|
== Usage
|
56
62
|
|
57
63
|
=== for Rack applications
|
@@ -124,7 +130,7 @@ UNIX-specific) test suites.
|
|
124
130
|
|
125
131
|
== Contact
|
126
132
|
|
127
|
-
All feedback (bug reports, user/development
|
133
|
+
All feedback (bug reports, user/development discussion, patches, pull
|
128
134
|
requests) go to the mailing list/newsgroup. We are currently
|
129
135
|
borrowing the Rainbows! mailing list since most of our code (and
|
130
136
|
problems) are related to Rainbows! mailto:rainbows-talk@rubyforge.org.
|
data/lib/zbatery.rb
CHANGED
@@ -4,7 +4,7 @@ require 'rainbows'
|
|
4
4
|
module Zbatery
|
5
5
|
|
6
6
|
# current version of Zbatery
|
7
|
-
VERSION = "0.
|
7
|
+
VERSION = "0.1.0"
|
8
8
|
|
9
9
|
class << self
|
10
10
|
|
@@ -34,6 +34,11 @@ module Zbatery
|
|
34
34
|
|
35
35
|
class HttpServer < Rainbows::HttpServer
|
36
36
|
|
37
|
+
# this class is only used to avoid breaking Unicorn user switching
|
38
|
+
class DeadIO
|
39
|
+
def chown(*args); end
|
40
|
+
end
|
41
|
+
|
37
42
|
# only used if no concurrency model is specified
|
38
43
|
def worker_loop(worker)
|
39
44
|
init_worker_process(worker)
|
@@ -86,7 +91,7 @@ module Zbatery
|
|
86
91
|
rescue => e # hopefully ignores errors on Win32...
|
87
92
|
logger.error "failed to setup signal handler: #{e.message}"
|
88
93
|
end
|
89
|
-
worker = Worker.new(0,
|
94
|
+
worker = Worker.new(0, DeadIO.new)
|
90
95
|
before_fork.call(self, worker)
|
91
96
|
worker_loop(worker) # runs forever
|
92
97
|
end
|
data/zbatery.gemspec
CHANGED
@@ -49,7 +49,7 @@ Gem::Specification.new do |s|
|
|
49
49
|
# eventmachine
|
50
50
|
# espace-neverblock + eventmachine
|
51
51
|
# async_sinatra + sinatra + eventmachine
|
52
|
-
s.add_dependency(%q<rainbows>, ["
|
52
|
+
s.add_dependency(%q<rainbows>, [">= 0.8.0", "<= 1.0.0"])
|
53
53
|
|
54
54
|
# s.licenses = %w(GPLv2 Ruby) # accessor not compatible with older RubyGems
|
55
55
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: zbatery
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Zbatery hackers
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-12-
|
12
|
+
date: 2009-12-22 00:00:00 +00:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -18,9 +18,12 @@ dependencies:
|
|
18
18
|
version_requirement:
|
19
19
|
version_requirements: !ruby/object:Gem::Requirement
|
20
20
|
requirements:
|
21
|
-
- -
|
21
|
+
- - ">="
|
22
22
|
- !ruby/object:Gem::Version
|
23
23
|
version: 0.8.0
|
24
|
+
- - <=
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: 1.0.0
|
24
27
|
version:
|
25
28
|
description: |-
|
26
29
|
Zbatery is an HTTP server for Rack applications on systems that either
|
@@ -41,6 +44,7 @@ extra_rdoc_files:
|
|
41
44
|
- LICENSE
|
42
45
|
- NEWS
|
43
46
|
- README
|
47
|
+
- FAQ
|
44
48
|
files:
|
45
49
|
- .document
|
46
50
|
- .gitignore
|
@@ -50,6 +54,7 @@ files:
|
|
50
54
|
- Documentation/.gitignore
|
51
55
|
- Documentation/GNUmakefile
|
52
56
|
- Documentation/zbatery.1.txt
|
57
|
+
- FAQ
|
53
58
|
- GIT-VERSION-FILE
|
54
59
|
- GIT-VERSION-GEN
|
55
60
|
- GNUmakefile
|