Ticket #30 (new patch)

Opened 2 months ago

Last modified 2 months ago

Use Unix domain sockets + fork to acheive greater scalability

Reported by: cmdrclueless Assigned to: evanweaver
Priority: minor Milestone: 1.4
Component: Mongrel Keywords:
Cc:

Description

Using unix domain sockets (UNIXSocket::socketpair) plus fork to improve scalability. This work was done on behalf of my employer: Raritan Computer, Inc. Due to the nature of the patch it is probably only relevant to system that allow file descriptors to be passed via a unix domain socket pair.

The work falls under the existing Mongrel license (the Ruby license).

THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Attachments

mongrel_changes.diff (29.4 kB) - added by cmdrclueless on 05/05/08 22:34:09.
Patch file for mongrel
mongrel_patch_20080507.diff (42.0 kB) - added by cmdrclueless on 05/07/08 12:31:13.
Here is an updated patch which includes adapted tests for the unix dispatch server.
mongrel_patch_stable_1-1.20080624-rev_1028.patch (32.7 kB) - added by cmdrclueless on 06/24/08 10:30:13.
This is a patch against revision 1028 for 1.1 stable

Change History

05/05/08 22:34:09 changed by cmdrclueless

  • attachment mongrel_changes.diff added.

Patch file for mongrel

05/05/08 22:39:07 changed by evanweaver

Wow, great. Do you have any tests for the new functionality? This will be important on Ruby 1.9 which supports copy-on-write properly.

05/05/08 23:54:11 changed by cmdrclueless

No, I don't have any test cases for the new functionality. I spent the better part of a day and a half hammering the code using our application. It continued to pass all the existing test; not that it absolves me from writing addition test cases. Unfortunately the time I have to spend on this is really dictated by my employer at this point. I simply don't have the time outside of work to spend on mongrel.

Please review the patch throughly. I did my best not to break any existing functionality. It doesn't mean I didn't miss something critical though.

05/06/08 16:14:26 changed by cmdrclueless

FYI, I'm working on a new patch with fixes and tests adapted from the HttpServer? test. I should have it ready in the next day or so.

05/07/08 12:31:13 changed by cmdrclueless

  • attachment mongrel_patch_20080507.diff added.

Here is an updated patch which includes adapted tests for the unix dispatch server.

06/24/08 10:30:13 changed by cmdrclueless

  • attachment mongrel_patch_stable_1-1.20080624-rev_1028.patch added.

This is a patch against revision 1028 for 1.1 stable