Rainbows! Rack HTTP server user/dev discussion
 help / color / mirror / code / Atom feed
Search results ordered by [date|relevance]  view[summary|nested|Atom feed]
thread overview below | download mbox.gz: |
* [ANN] Rainbows! 5.1.1 - unicorn 5.3.x compatibility fix
@ 2017-04-02  2:11  6% Eric Wong
  0 siblings, 0 replies; 2+ results
From: Eric Wong @ 2017-04-02  2:11 UTC (permalink / raw)
  To: rainbows-public; +Cc: Claudio Poli

Rainbows! 5.1.1

This release fixes an incompatibility introduced with
the release of unicorn 5.3.0, yesterday :x.

Thanks to Claudio Poli for reporting the bug (and reminding
me this project exists).

Two changes since 5.1.0 (2017-01-12):
      workaround for unicorn 5.3.0
      tests: update isolate deps for unicorn and raindrops

Rainbows! is maintained as long as anybody uses it,
but I don't recommend using it for new apps:

  https://bogomips.org/rainbows-public/20151020095934.GA19114@dcvr.yhbt.net/

* https://bogomips.org/rainbows/
* rainbows-public@bogomips.org
* https://bogomips.org/rainbows-public/
* git clone git://bogomips.org/rainbows.git
* https://bogomips.org/rainbows/NEWS.atom.xml
* nntp://news.public-inbox.org/inbox.comp.lang.ruby.rainbows
* nntp://news.gmane.org/gmane.comp.lang.ruby.rainbows.general

^ permalink raw reply	[relevance 6%]

* [PATCH] workaround for unicorn 5.3.0
  @ 2017-04-02  1:54  7% ` Eric Wong
  0 siblings, 0 replies; 2+ results
From: Eric Wong @ 2017-04-02  1:54 UTC (permalink / raw)
  To: Claudio Poli; +Cc: rainbows-public

unicorn 5.3.0 introduced a new Unicorn::TCPSrv and
Unicorn::TCPClient constants to distinguish TCP sockets
from Unix ones from its check_client_connection feature.

These classes screw up our direct inheritance of Kgio::Socket
from the Rainbows::Client class.  Since we do not support
check_client_connection, we do not need these new classes in
unicorn.  Removing Unicorn::TCPSrv and aliasing it as
Kgio::TCPServer is sufficient for now.  In the future,
removing all kgio dependencies from Rainbows! will be prioritized.

Thanks to Claudio Poli for reporting the bug:

  https://bogomips.org/rainbows-public/9267B33C-D13C-47E1-8892-4777B96DDCD1@gmail.com/
---
  This patch passes all tests, expect a release coming ASAP.
  Thanks again.

 lib/rainbows.rb | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/lib/rainbows.rb b/lib/rainbows.rb
index acfe911..584c94b 100644
--- a/lib/rainbows.rb
+++ b/lib/rainbows.rb
@@ -149,3 +149,12 @@ def self.now # Ruby <= 2.0
 
 require 'rainbows/error'
 require 'rainbows/configurator'
+
+module Unicorn
+  # this interferes with Rainbows::Client creation with unicorn 5.3
+  begin
+    remove_const :TCPSrv
+    TCPSrv = Kgio::TCPServer
+  rescue NameError # unicorn < 5.3.0
+  end
+end
-- 
EW

^ permalink raw reply related	[relevance 7%]

Results 1-2 of 2 | reverse | options above
-- pct% links below jump to the message on this page, permalinks otherwise --
2017-04-02  2:11  6% [ANN] Rainbows! 5.1.1 - unicorn 5.3.x compatibility fix Eric Wong
2017-04-02  0:05     undefined method `process_loop' for #<Unicorn::TCPClient:fd 14> Claudio Poli
2017-04-02  1:54  7% ` [PATCH] workaround for unicorn 5.3.0 Eric Wong

Code repositories for project(s) associated with this public inbox

	https://yhbt.net/rainbows.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).