Comparison

plugins/mod_proxy65.lua @ 2309:7dc6049a69e8

mod_proxy65: Use a bigger buffer for data we're proxying A slightly larger buffer seems to preform a lot better
author Sjoerd Simons <sjoerd.simons@collabora.co.uk>
date Thu, 03 Dec 2009 17:04:54 +0100
parent 2308:600ac8992a4c
child 2310:e74c6740a42b
comparison
equal deleted inserted replaced
2308:600ac8992a4c 2309:7dc6049a69e8
252 module:log("error", "Possibly two proxy65 components are configured to share the same port."); 252 module:log("error", "Possibly two proxy65 components are configured to share the same port.");
253 end 253 end
254 254
255 connlisteners.start(module.host .. ':proxy65'); 255 connlisteners.start(module.host .. ':proxy65');
256 component = componentmanager.register_component(host, handle_to_domain); 256 component = componentmanager.register_component(host, handle_to_domain);
257 local sender_lock_threshold = 1024; 257 local sender_lock_threshold = 4096;
258 function throttle_sending(sender, receiver) 258 function throttle_sending(sender, receiver)
259 sender:pattern(sender_lock_threshold); 259 sender:pattern(sender_lock_threshold);
260 local sender_locked; 260 local sender_locked;
261 local _sendbuffer = receiver.sendbuffer; 261 local _sendbuffer = receiver.sendbuffer;
262 function receiver.sendbuffer() 262 function receiver.sendbuffer()