Webrick proxy server and streaming


I ran webrick proxy server snippet found on webrick.org site. It was
working fine except with streaming or large files. Rather than handing
over data to browser as it gets it downloading entire file and then
flushing entire file to client. Is it possible to webrick to hand
over data to client as it gets ?, So that streaming and progressive
loading at client side work as expected ?

require ‘webrick/httpproxy’

s = WEBrick::HTTPProxyServer.new(
:Port => 2020,
:RequestCallback => Proc.new{|req,res|
puts “-”*70
puts req.request_line, req.raw_header
puts “-”*70
trap(“INT”){ s.shutdown }

On Sep 15, 7:32 pm, samba [email protected] wrote:

require ‘webrick/httpproxy’
BTW you can use youtube for testing streaming behavior.