about summary refs log tree commit homepage
DateCommit message (Collapse)
2009-11-05Rainbows! 0.5.0 v0.5.0
We depend on the just-released Unicorn 0.94.0 for the fixed trailer handling. As with `unicorn', the `rainbows' executable now sets and respects ENV["RACK_ENV"]. Also small fixes and cleanups including better FreeBSD 7.2 compatibility and less likely to over-aggressively kill slow/idle workers when a very low timeout is set. Eric Wong (20): rev: split out heartbeat class bump Unicorn dependency to (consistently) pass tests tests: avoid single backquote in echo event_machine: avoid slurping when proxying tests: make timeout tests reliable under 1.9 thread_pool: comment for potential SMP issue under 1.9 Allow 'use "model"' as a string as well as symbol Rev model is the only user of deferred_bodies ev_core: use Tempfile instead of Unicorn::Util::tmpio ev_core: ensure quit is triggered on all errors rainbows: set and use process-wide ENV["RACK_ENV"] http_server: add one second to any requested timeout thread_pool: update fchmod heartbeat every second t0004: tighten up timeout test ev_core: remove Tempfile usage once again cleanup: remove unused t????.ru test files tests: staggered trailer upload test ensure RACK_ENV is inherited from the parent env t0100: more precise `expr` usage
2009-11-05t0100: more precise `expr` usage
It's also more portable since "+" isn't portable on FreeBSD.
2009-11-05ensure RACK_ENV is inherited from the parent env
Add tests to ensure we set it correctly and it gets passed down to the app.
2009-11-05tests: staggered trailer upload test
This test lead to two separate bugfixes in Unicorn, one in the HttpParser and the other in TeeInput. Ironically, this test was spawned from what I initially thought was a bug in the EvCore module used by Rev and EventMachine, but there was no bug in EvCore...
2009-11-05cleanup: remove unused t????.ru test files
2009-11-05ev_core: remove Tempfile usage once again
We're simply too uncomfortable with the weird GC issues associated with Tempfile and having linked temporary files at all. Instead just depend on the #size-aware TmpIO class that Unicorn 0.94.0 provides for us.
2009-11-04t0004: tighten up timeout test
We've worked around trigger happy timeouts in the master since we track the timeout at a lower resolution here.
2009-11-04thread_pool: update fchmod heartbeat every second
Like the rest of the concurrency models. This gives us more flexibility in case a process-wide blocking operation started during an "unlucky" period when the join timeout was about to expire.
2009-11-04http_server: add one second to any requested timeout
This is because our timeout implementations are less precise than Unicorn. Since we handle multiple clients with the same process, we sacrifice precision for performance and instead implement our fchmod heartbeats at a fixed rate, as doing fchmod() repeated for short-lived connections would hurt performance and we have to call fchmod even when connected clients are idle.
2009-11-04rainbows: set and use process-wide ENV["RACK_ENV"]
Merb, Sinatra, Thin, Passenger and now even Unicorn will it, so we set and use it too because that's what all the cool kids are doing.
2009-11-02ev_core: ensure quit is triggered on all errors
Just in case something goes wrong with the write or the logger, make sure we've triggered a quit.
2009-11-02ev_core: use Tempfile instead of Unicorn::Util::tmpio
Since we're geared towards slower clients, we may be able to make gains from using userspace IO buffering. This allows us to avoid metadef-ing a #size method for every File we allocate and save memory.
2009-11-02Rev model is the only user of deferred_bodies
We don't use it in EventMachine since EM has its own built-in ways to handle deferred bodies.
2009-11-02Allow 'use "model"' as a string as well as symbol
Since const_get works with a string as well as a symbol, allow that to be used. It's easier and simpler to just allow strings as use arguments than to error check and raise exceptions. So both of the following should now work: Rainbows! do use :Revactor end Rainbows! do use "Revactor" end Rainbows! will always use the symbol variant internally, however, so applications can alway expect env['rainbows.model'] to be a symbol.
2009-11-01thread_pool: comment for potential SMP issue under 1.9
The problem is unconfirmed at the moment, but I've long anticipated it. I just need to remember the next time I log into a monster machine.
2009-11-01tests: make timeout tests reliable under 1.9
We need to resort to SIGSTOP to block off processes entirely since 1.9 uses native threads.
2009-11-01event_machine: avoid slurping when proxying
Avoid slurping in case we're a fast backend writing to a slow client. This should prevent our memory usage from exploding when clients are reading slowly.
2009-10-31tests: avoid single backquote in echo
It's not portable to FreeBSD 7.2 /bin/sh
2009-10-30bump Unicorn dependency to (consistently) pass tests
Unicorn 0.93.5 came to be so the heartbeat tests could pass consistently.
2009-10-30rev: split out heartbeat class
This module will be reused in upcoming Rev-derived concurrency models.
2009-10-27Rainbows! 0.4.0 v0.4.0
Basic single-threaded EventMachine support is now included. It supports async_synatra[1] via the "async.callback" Rack environment[2]. For EventMachine, we rely on the updated attach/watch API in EventMachine 0.12.10. As Revactor 0.1.5 is now available, our Revactor support now depends on it as it adds the ability to listen on UNIX domain sockets. For developers/QA folks, the integration tests are completely revamped for easier maintenance when new concurrency models are introduced and should also produce TAP-compliant output. The test suite remains highly parallelizable using GNU make. There are immediate plans to expand support for both Rev and EventMachine to support use with threaded application dispatch. Eric Wong (41): rev: remove Revactor-specific workaround README: change ordering of concurrency model listing tests: more correct HTTP/0.9 test test-lib: avoid stalling due to bad FIFO handling rev: fix static file responses under HTTP/0.9 add news bodies to site NEWS.atom.xml tests: avoid needlessly remaking "rainbows" initial EventMachine support tests: hopefully fix stalls in input trailer tests tests: avoid race condition in reopen logs test tests: prefer "RUBY" to lowercased "ruby" tests: common setup and wait_start functions tests: add a TAP producer shell library tests: port all existing tests to TAP library tests: remove symlinks and small files, use Make t9000: bail if run with an unsupported/pointless model tests: allow "make $model" to run tests for that model rev: spell ECONNABORTED correctly rev/evma: move common code for event models into ev_core ev_core: do not drop deferred bodies on graceful quits eventmachine: get basic tests working rev: do not File.expand_path on result of body.to_path eventmachine 0.12.8 passes all tests tests: make large file memory tests more reliable eventmachine: require EM 0.12.10 update gem dependencies in comments/local.mk.sample rev: enforce Rev::VERSION >= 0.3.0 eventmachine: add async_sinatra support tests: only load Revactor tests under 1.9.1 tests: gracefully exit if EventMachine is not available tests: error out if socat + curl aren't reachable thread*: fix MRI 1.8.6 compatibility local.mk.sample: cleanups and minor reorg eventmachine: remove unnecessary ivar assignment eventmachine: document our support of "async_synatra" doc: Update TODO and README tests: generate all dependencies atomically app_pool: update RDoc test-lib: DWIM handling of temp UNIX sockets revactor: require 0.1.5, remove 0.1.4 workarounds gemspec: bump up Unicorn dep version to 0.93.4 [1] http://github.com/raggi/async_sinatra [2] this is not 100% Rack::Lint compatible, but we'll let it slide since there are already folks depending on the async_sinatra gem
2009-10-27gemspec: bump up Unicorn dep version to 0.93.4
It's easier to support especially for Thread* models which are affected by the BSD stdio weirdness 0.93.4 works around.
2009-10-27revactor: require 0.1.5, remove 0.1.4 workarounds
Also new are added basic HTTP tests for UNIX domain socket handling (for all models, now, of course).
2009-10-27test-lib: DWIM handling of temp UNIX sockets
2009-10-27app_pool: update RDoc
Now that we have EM support (which is basically like Rev), update our docs for that. Also, expand on why Revactor isn't supported just yet...
2009-10-26tests: generate all dependencies atomically
Using a "+" suffix alone was not enough protection since we use evil recursive makes and can't share dependency info with parent makes. While this could be done more efficiently (even with recursive make), but it'd be harder to maintain. So we generate the dependencies later to and sacrifice efficiency on the initial run (but rarely/never again).
2009-10-26doc: Update TODO and README
We have basic EventMachine and :async support.
2009-10-26eventmachine: document our support of "async_synatra"
ref: http://github.com/raggi/async_sinatra
2009-10-26eventmachine: remove unnecessary ivar assignment
It shouldn't be needed, really, favor simpler code here until proven otherwise.
2009-10-26local.mk.sample: cleanups and minor reorg
define the Ruby prefix once to make it easier on Rubies outside of home. Organize gem listings logically by dependency chains.
2009-10-26thread*: fix MRI 1.8.6 compatibility
Array#count is not available until MRI 1.8.7
2009-10-26tests: error out if socat + curl aren't reachable
This makes it easier to figure out why tests are failing for people that forget to read t/README
2009-10-26tests: gracefully exit if EventMachine is not available
2009-10-26tests: only load Revactor tests under 1.9.1
Even though our tests do an extra check, it's faster to not unnecessarily invoke the check in the first place.
2009-10-26eventmachine: add async_sinatra support
This is should be compatible with how the Thin webserver provides async callback support. See http://github.com/raggi/async_sinatra for the details
2009-10-26rev: enforce Rev::VERSION >= 0.3.0
We depend on the ability to create listeners from existing IO objects here.
2009-10-26update gem dependencies in comments/local.mk.sample
Rack 1.0.1 is out and works nicely.
2009-10-26eventmachine: require EM 0.12.10
The EM::attach/EM::watch API changed incompatibly in 0.12.10
2009-10-26tests: make large file memory tests more reliable
Use a bigger random_blob and run GC before checking RSS
2009-10-26eventmachine 0.12.8 passes all tests
This means Rainbows::DevFdBody async responses and large file streaming without slurping. This is only with eventmachine 0.12.8, it looks like 0.12.10 changes the attach/watch API...
2009-10-26rev: do not File.expand_path on result of body.to_path
Rack::Lint requires File::exist? to be true on this, so there's no need to expand the path name to resolve it here.
2009-10-26eventmachine: get basic tests working
log reopens, graceful shutdown, HTTP error responses should all be working now.
2009-10-26ev_core: do not drop deferred bodies on graceful quits
Graceful quit means we finish sending everything we have before exiting. Additionally, only signal quits after we've queued the error response up.
2009-10-26rev/evma: move common code for event models into ev_core
EventMachine and Rev models seem to be able to share a lot of common code, so lets share. We may support Packet in the future, too, and end up with a similar programming model there as well.
2009-10-26rev: spell ECONNABORTED correctly
Odd that Ruby didn't barf on this until now...
2009-10-24tests: allow "make $model" to run tests for that model
This makes it easier to filter functionality by model.
2009-10-24t9000: bail if run with an unsupported/pointless model
We'll probably make AppPool at least not break down and die in the future, but for now just disable it if run directly.
2009-10-24tests: remove symlinks and small files, use Make
This will make it easier to enable and manage tests for new concurrency models.
2009-10-24tests: port all existing tests to TAP library
Everything passes, and "set -e" prevents us from making any stupid mistakes...
2009-10-24tests: add a TAP producer shell library
This will eventually allow our test output to be consumed by any TAP[1]-compatible consumers. Like the rest of our shell scripts, this only relies on POSIX behavior and has no bashisms. mktemp(1) is a requirement only if using the verbose output in this library. This library aims to be useful outside of Rainbows! [1]: Test Anything Protocol: http://testanything.org/