about summary refs log tree commit homepage
path: root/extras/proxy_pass.rb
DateCommit message (Collapse)
2015-12-08rely on optimized case dispatch opt-case
Ruby-trunk (as of r52931) optimizes case dispatch for additional immediate values such as `nil', `true', and `false'. Rearrange our case statements (and take away some safety-checks :x) to take advantage of these optimizations in ruby-trunk. ref: https://bugs.ruby-lang.org/issues/11769 http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/71818 http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/71825
2015-05-11extras/proxy_pass: remove compatibility note
We'll have to support both, it seems.
2015-05-09proxy_pass: favor literal hash over arrays for error responses
Arrays are less verbose, but they have more bytecode overhead which actually matters at runtime.
2015-04-07extras/proxy_pass: reinstate synchronous version
Since yahns/proxy_pass is not a drop-in replacement, reinstate the old, synchronous version to avoid breaking existing setups which require Rack middleware support.
2015-03-14proxy_pass: officially become a part of yahns
This will rely on rack.hijack in the future to support asynchronous execution without tying up a thread when waiting for upstreams. For now, this allows simpler code with fewer checks and the use of monotonic time on newer versions of Ruby.
2015-03-14extras/proxy_pass: support Unix domain sockets as backends
Of course, some users will prefer to bind HTTP application servers to Unix domain sockets for better isolation and (maybe) better performance.
2015-03-14extras/proxy_pass: implicit $fullpath expansion for upstreams
This is slightly more nginx-style behavior and allows simpler configuration.
2015-03-13avoid unnecessary calls #to_sym for __send__
No point in bloating our bytecode for single-use variables.
2015-03-13extras/proxy_pass: remove ERROR_502 constant
Some middlewares may attempt to modify the response body in place, so sharing this is not a good idea. We shouldn't really care about rare 502 error paths, either.
2015-03-12extras/proxy_pass: remove unused CHUNK_SIZE constant
It was never used.
2015-03-03extras/proxy_pass: flesh out upload support + tests
This module will probably become an official part of yahns soon, so finally add tests for this module.
2015-03-03extras/proxy_pass: log exceptions leading to 502
It may be useful for us to track down potential errors in our code or log when an upstream misbehaves.
2015-03-03extras/proxy_pass: do not name unused variable
"ruby -w" warns on it.
2015-02-10extras/proxy_pass: save memory in String#split arg
This saves over 400 bytes of memory in a cold code path.
2013-11-05extras: add proxy_pass Rack app
This is an ad-hoc reverse proxy solution. This is fully-Rack compatible at the moment, so it's synchronous. This is also only very lightly tested but I don't use it for any important serving, yet.