Rainbows! Rack HTTP server user/dev discussion
 help / color / Atom feed
Search results ordered by [date|relevance]  view[summary|nested|Atom feed]
						download: 
* [ANN] Rainbows! 4.0.0 - MOAR concurrency for MOAR COARS
@ 2011-06-27  9:45 Eric Wong
      [irrelevant] ` <20110627094517.GA27156-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org>
  0 siblings, 1 reply; 7+ results
From: Eric Wong @ 2011-06-27  9:45 UTC (permalink / raw)
  To: rainbows-talk-GrnCvJ7WPxnNLxjTenLetw

Changes:

Rainbows! now scales to more than 1024 worker processes without
special privileges.  To enable this, Rainbows! now depends on
Unicorn 4.x and thus raindrops[1].

client_max_header_size directive is added to limit per-client
memory usage in headers.

An experimental StreamResponseEpoll concurrency option now
exists to buffer outgoing responses without any thread-safe
dependencies.  Unlike the rest of Rainbows! which works fine
without nginx, this concurrency option is /only/ supported
behind nginx, even more strongly so than Unicorn itself.
non-nginx LAN clients are NOT supported for this.  This relies
on the sleepy_penguin[2] RubyGem (and Linux).

There are some minor bug fixes and cleanups all around.  See
"git log v3.4.0.." for details.

[1] http://raindrops.bogomips.org/
[2] http://bogomips.org/sleepy_penguin/

* http://rainbows.rubyforge.org/
* rainbows-talk-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org
* git://bogomips.org/rainbows.git

-- 
Eric Wong
_______________________________________________
Rainbows! mailing list - rainbows-talk-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org
http://rubyforge.org/mailman/listinfo/rainbows-talk
Do not quote signatures (like this one) or top post when replying


^ permalink raw reply	[relevance 6%]

* Re: [ANN] Rainbows! 4.0.0 - MOAR concurrency for MOAR COARS
      [irrelevant] ` <20110627094517.GA27156-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org>
@ 2011-06-29  6:36   ` ghazel-Re5JQEeQqe8AvxtiuMwx3w
      [irrelevant]     ` <BANLkTi=oQXK5Casq9SuGD3edeUrDPvRm3A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  0 siblings, 1 reply; 7+ results
From: ghazel-Re5JQEeQqe8AvxtiuMwx3w @ 2011-06-29  6:36 UTC (permalink / raw)
  To: Rainbows! list

On Mon, Jun 27, 2011 at 2:45 AM, Eric Wong <normalperson@yhbt.net> wrote:
> Changes:
>
> Rainbows! now scales to more than 1024 worker processes without
> special privileges.  To enable this, Rainbows! now depends on
> Unicorn 4.x and thus raindrops[1].

I can't seem to upgrade from rainbows-3.4.0 to rainbows-4.0.0. I see:

#<NoMethodError: undefined method `expand_addr' for nil:NilClass>

a bunch in the rainbows.stderr.log.

-Greg
_______________________________________________
Rainbows! mailing list - rainbows-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/rainbows-talk
Do not quote signatures (like this one) or top post when replying

^ permalink raw reply	[relevance 7%]

* Re: [ANN] Rainbows! 4.0.0 - MOAR concurrency for MOAR COARS
      [irrelevant]     ` <BANLkTi=oQXK5Casq9SuGD3edeUrDPvRm3A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2011-06-29  7:11       ` Eric Wong
      [irrelevant]         ` <20110629071101.GA8110-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org>
  0 siblings, 1 reply; 7+ results
From: Eric Wong @ 2011-06-29  7:11 UTC (permalink / raw)
  To: Rainbows! list

ghazel@gmail.com wrote:
> On Mon, Jun 27, 2011 at 2:45 AM, Eric Wong <normalperson@yhbt.net> wrote:
> > Changes:
> >
> > Rainbows! now scales to more than 1024 worker processes without
> > special privileges.  To enable this, Rainbows! now depends on
> > Unicorn 4.x and thus raindrops[1].
> 
> I can't seem to upgrade from rainbows-3.4.0 to rainbows-4.0.0. I see:
> 
> #<NoMethodError: undefined method `expand_addr' for nil:NilClass>

That's odd, what configuration options and Ruby version are you
using?  Are you using a per-worker listen socket?

-- 
Eric Wong
_______________________________________________
Rainbows! mailing list - rainbows-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/rainbows-talk
Do not quote signatures (like this one) or top post when replying

^ permalink raw reply	[relevance 7%]

* Re: [ANN] Rainbows! 4.0.0 - MOAR concurrency for MOAR COARS
      [irrelevant]         ` <20110629071101.GA8110-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org>
@ 2011-06-29  7:16           ` ghazel-Re5JQEeQqe8AvxtiuMwx3w
      [irrelevant]             ` <BANLkTi=SRC7EvrA5tZcwJhwNKzgtyvz5mg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  2011-06-29  7:19           ` Eric Wong
  1 sibling, 1 reply; 7+ results
From: ghazel-Re5JQEeQqe8AvxtiuMwx3w @ 2011-06-29  7:16 UTC (permalink / raw)
  To: Rainbows! list

On Wed, Jun 29, 2011 at 12:11 AM, Eric Wong <normalperson@yhbt.net> wrote:
> ghazel@gmail.com wrote:
>> On Mon, Jun 27, 2011 at 2:45 AM, Eric Wong <normalperson@yhbt.net> wrote:
>> > Changes:
>> >
>> > Rainbows! now scales to more than 1024 worker processes without
>> > special privileges.  To enable this, Rainbows! now depends on
>> > Unicorn 4.x and thus raindrops[1].
>>
>> I can't seem to upgrade from rainbows-3.4.0 to rainbows-4.0.0. I see:
>>
>> #<NoMethodError: undefined method `expand_addr' for nil:NilClass>
>
> That's odd, what configuration options and Ruby version are you
> using?  Are you using a per-worker listen socket?

REE 1.8.7

Hopefully relevant config:

use :ThreadSpawn
...

listen "/tmp/rainbows.sock", :backlog => 2048
listen 8998, :tcp_nopush => true
...
after_fork do |server, worker|
  # per-process listener ports for debugging/admin/migrations
  addr = "127.0.0.1:#{9100 + worker.nr}"
  server.listen(addr, :tries => -1, :delay => 5, :tcp_nopush => true)

-Greg
_______________________________________________
Rainbows! mailing list - rainbows-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/rainbows-talk
Do not quote signatures (like this one) or top post when replying

^ permalink raw reply	[relevance 7%]

* Re: [ANN] Rainbows! 4.0.0 - MOAR concurrency for MOAR COARS
      [irrelevant]             ` <BANLkTi=SRC7EvrA5tZcwJhwNKzgtyvz5mg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2011-06-29  7:31               ` Eric Wong
      [irrelevant]                 ` <20110629073103.GB10100-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org>
  0 siblings, 1 reply; 7+ results
From: Eric Wong @ 2011-06-29  7:31 UTC (permalink / raw)
  To: Rainbows! list

ghazel-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org wrote:
> after_fork do |server, worker|
>   # per-process listener ports for debugging/admin/migrations
>   addr = "127.0.0.1:#{9100 + worker.nr}"
>   server.listen(addr, :tries => -1, :delay => 5, :tcp_nopush => true)

Yup, as I suspected.  The patch I posted (and the unicorn prerelease
Rubygem) should fix it.

-- 
Eric Wong
_______________________________________________
Rainbows! mailing list - rainbows-talk-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org
http://rubyforge.org/mailman/listinfo/rainbows-talk
Do not quote signatures (like this one) or top post when replying


^ permalink raw reply	[relevance 7%]

* Re: [ANN] Rainbows! 4.0.0 - MOAR concurrency for MOAR COARS
      [irrelevant]         ` <20110629071101.GA8110-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org>
  2011-06-29  7:16           ` ghazel-Re5JQEeQqe8AvxtiuMwx3w
@ 2011-06-29  7:19           ` Eric Wong
  1 sibling, 0 replies; 7+ results
From: Eric Wong @ 2011-06-29  7:19 UTC (permalink / raw)
  To: Rainbows! list

Eric Wong <normalperson-rMlxZR9MS24@public.gmane.org> wrote:
> ghazel-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org wrote:
> > I can't seem to upgrade from rainbows-3.4.0 to rainbows-4.0.0. I see:
> > 
> > #<NoMethodError: undefined method `expand_addr' for nil:NilClass>
> 
> That's odd, what configuration options and Ruby version are you
> using?  Are you using a per-worker listen socket?

This should fix it, the test case for this was broken, too :<

diff --git a/lib/unicorn/http_server.rb b/lib/unicorn/http_server.rb
index 02ba965..78d80b4 100644
--- a/lib/unicorn/http_server.rb
+++ b/lib/unicorn/http_server.rb
@@ -453,7 +453,7 @@ class Unicorn::HttpServer
   def after_fork_internal
     @ready_pipe.close if @ready_pipe
     Unicorn::Configurator::RACKUP.clear
-    @ready_pipe = @init_listeners = @config = @before_exec = @before_fork = nil
+    @ready_pipe = @init_listeners = @before_exec = @before_fork = nil
 
     srand # http://redmine.ruby-lang.org/issues/4338
 
@@ -545,6 +545,7 @@ class Unicorn::HttpServer
     after_fork.call(self, worker) # can drop perms
     worker.user(*user) if user.kind_of?(Array) && ! worker.switched
     self.timeout /= 2.0 # halve it for select()
+    @config = nil
     build_app! unless preload_app
   end
 
diff --git a/test/exec/test_exec.rb b/test/exec/test_exec.rb
index 0f6b083..8c33457 100644
--- a/test/exec/test_exec.rb
+++ b/test/exec/test_exec.rb
@@ -516,7 +516,7 @@ EOF
     File.unlink(tmp.path)
     ucfg = Tempfile.new('unicorn_test_config')
     ucfg.syswrite("listen '#@addr:#@port'\n")
-    ucfg.syswrite("before_fork { |s,w|\n")
+    ucfg.syswrite("after_fork { |s,w|\n")
     ucfg.syswrite("  s.listen('#{tmp.path}', :backlog => 5, :sndbuf => 8192)\n")
     ucfg.syswrite("  s.listen('#@addr:#{port2}', :rcvbuf => 8192)\n")
     ucfg.syswrite("\n}\n")
-- 
Eric Wong
_______________________________________________
Rainbows! mailing list - rainbows-talk-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org
http://rubyforge.org/mailman/listinfo/rainbows-talk
Do not quote signatures (like this one) or top post when replying


^ permalink raw reply	[relevance 6%]

* Re: [ANN] Rainbows! 4.0.0 - MOAR concurrency for MOAR COARS
      [irrelevant]                 ` <20110629073103.GB10100-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org>
@ 2011-06-29  7:47                   ` ghazel-Re5JQEeQqe8AvxtiuMwx3w
  0 siblings, 0 replies; 7+ results
From: ghazel-Re5JQEeQqe8AvxtiuMwx3w @ 2011-06-29  7:47 UTC (permalink / raw)
  To: Rainbows! list

On Wed, Jun 29, 2011 at 12:31 AM, Eric Wong <normalperson@yhbt.net> wrote:
> ghazel@gmail.com wrote:
>> after_fork do |server, worker|
>>   # per-process listener ports for debugging/admin/migrations
>>   addr = "127.0.0.1:#{9100 + worker.nr}"
>>   server.listen(addr, :tries => -1, :delay => 5, :tcp_nopush => true)
>
> Yup, as I suspected.  The patch I posted (and the unicorn prerelease
> Rubygem) should fix it.

Yup. Unicorn and Rainbows! upgraded fine now.

Thanks!

-Greg
_______________________________________________
Rainbows! mailing list - rainbows-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/rainbows-talk
Do not quote signatures (like this one) or top post when replying

^ permalink raw reply	[relevance 7%]

Results 1-7 of 7 | reverse results
2011-06-27  9:45 [ANN] Rainbows! 4.0.0 - MOAR concurrency for MOAR COARS Eric Wong
    [irrelevant] ` <20110627094517.GA27156-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org>
2011-06-29  6:36   ` ghazel-Re5JQEeQqe8AvxtiuMwx3w
    [irrelevant]     ` <BANLkTi=oQXK5Casq9SuGD3edeUrDPvRm3A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-06-29  7:11       ` Eric Wong
    [irrelevant]         ` <20110629071101.GA8110-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org>
2011-06-29  7:16           ` ghazel-Re5JQEeQqe8AvxtiuMwx3w
    [irrelevant]             ` <BANLkTi=SRC7EvrA5tZcwJhwNKzgtyvz5mg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-06-29  7:31               ` Eric Wong
    [irrelevant]                 ` <20110629073103.GB10100-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org>
2011-06-29  7:47                   ` ghazel-Re5JQEeQqe8AvxtiuMwx3w
2011-06-29  7:19           ` Eric Wong


Rainbows! Rack HTTP server user/dev discussion

Archives are clonable:
	git clone --mirror https://bogomips.org/rainbows-public
	git clone --mirror http://ou63pmih66umazou.onion/rainbows-public

Newsgroups are available over NNTP:
	nntp://news.public-inbox.org/inbox.comp.lang.ruby.rainbows
	nntp://ou63pmih66umazou.onion/inbox.comp.lang.ruby.rainbows

 note: .onion URLs require Tor: https://www.torproject.org/

AGPL code for this site: git clone https://public-inbox.org/ public-inbox