Rainbows! Rack HTTP server user/dev discussion
 help / color / Atom feed
* Fwd: Patch to fix use in Rainbows! with arguments
       [not found] ` <AANLkTinySo=C2S84M6V5kbibOVfhkkLM00Bkfoa+GLns-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2011-02-08  2:02   ` Graham Hughes
       [not found]     ` <AANLkTikGAcTXW32tuMvwVWDo4U+pBxUq5+7m-7xA3LtB-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Graham Hughes @ 2011-02-08  2:02 UTC (permalink / raw)
  To: rainbows-talk-GrnCvJ7WPxnNLxjTenLetw

Hello.  I found an annoying error in Rainbows after 0.97 that I traced
down to inaccurate scoping in one of the modules; I think this never
came up in your tests because you don't test use in config.rb with
arguments: we were running the following:

Rainbows! do
  use :NeverBlock, :pool_size => 50
  worker_connections 100
end

which broke.

Enclosed is a patch which fixes this issue.

Graham

From 366ab17b95c0c618f9f49c6ff20ff3218cc26344 Mon Sep 17 00:00:00 2001
From: Graham Hughes <graham@rightscale.com>
Date: Mon, 7 Feb 2011 16:49:31 -0800
Subject: [PATCH] Actually use the Rainbows::O constant for use
---
 lib/rainbows/http_server.rb |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/rainbows/http_server.rb b/lib/rainbows/http_server.rb
index 71ed192..ab214c3 100644
--- a/lib/rainbows/http_server.rb
+++ b/lib/rainbows/http_server.rb
@@ -63,8 +63,8 @@ class Rainbows::HttpServer < Unicorn::HttpServer
       raise ArgumentError, "concurrency model #{model.inspect} not supported"
     args.each do |opt|
       case opt
-      when Hash; O.update(opt)
-      when Symbol; O[opt] = true
+      when Hash; Rainbows::O.update(opt)
+      when Symbol; Rainbows::O[opt] = true
       else; raise ArgumentError, "can't handle option: #{opt.inspect}"
       end
     end
--
1.7.4
_______________________________________________
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	[flat|nested] 3+ messages in thread

* Re: Fwd: Patch to fix use in Rainbows! with arguments
       [not found]     ` <AANLkTikGAcTXW32tuMvwVWDo4U+pBxUq5+7m-7xA3LtB-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2011-02-08  3:37       ` Eric Wong
       [not found]         ` <20110208033745.GA15989-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Eric Wong @ 2011-02-08  3:37 UTC (permalink / raw)
  To: Rainbows! list; +Cc: Graham Hughes

Graham Hughes <graham-nkzjiHSqi6rZJqsBc5GL+g@public.gmane.org> wrote:
> Enclosed is a patch which fixes this issue.

Thanks Grant!  Applied and pushed out to rainbows.git along with another
commit for a test case.  Expect a new release sometime this week, but
you should be able to build a pre-release gem from rainbows.git just by
running "make gem".

In the future can you use "git send-email" so your patch doesn't get
mangled?  There are some MUA-specific hints in
Documentation/SubmittingPatches[1] from git.git, too

Thanks again!

[1]- http://git.kernel.org/?p=git/git.git;f=Documentation/SubmittingPatches;a=blob

-- 
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	[flat|nested] 3+ messages in thread

* Re: Patch to fix use in Rainbows! with arguments
       [not found]         ` <20110208033745.GA15989-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org>
@ 2011-02-08  7:03           ` Graham Hughes
  0 siblings, 0 replies; 3+ messages in thread
From: Graham Hughes @ 2011-02-08  7:03 UTC (permalink / raw)
  To: Eric Wong; +Cc: Rainbows! list

On Feb 7, 2011, at 19:37, Eric Wong <normalperson-rMlxZR9MS24@public.gmane.org> wrote:

> Graham Hughes <graham-nkzjiHSqi6rZJqsBc5GL+g@public.gmane.org> wrote:
>> Enclosed is a patch which fixes this issue.
> 
> Thanks Grant!  Applied and pushed out to rainbows.git along with another
> commit for a test case.  Expect a new release sometime this week, but
> you should be able to build a pre-release gem from rainbows.git just by
> running "make gem".
> 
> In the future can you use "git send-email" so your patch doesn't get
> mangled?  There are some MUA-specific hints in
> Documentation/SubmittingPatches[1] from git.git, too

Thank you, and I will investigate send-email in future.

Graham
> 
_______________________________________________
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	[flat|nested] 3+ messages in thread

end of thread, back to index

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <AANLkTinySo=C2S84M6V5kbibOVfhkkLM00Bkfoa+GLns@mail.gmail.com>
     [not found] ` <AANLkTinySo=C2S84M6V5kbibOVfhkkLM00Bkfoa+GLns-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-02-08  2:02   ` Fwd: Patch to fix use in Rainbows! with arguments Graham Hughes
     [not found]     ` <AANLkTikGAcTXW32tuMvwVWDo4U+pBxUq5+7m-7xA3LtB-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-02-08  3:37       ` Eric Wong
     [not found]         ` <20110208033745.GA15989-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org>
2011-02-08  7:03           ` Graham Hughes

Rainbows! Rack HTTP server user/dev discussion

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

Example config snippet for mirrors

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.git