[mod_python] Request sendfile question

Jim Gallacher jpg at jgassociates.ca
Fri Mar 24 11:07:07 EST 2006

Ville Silventoinen wrote:
> On Fri, 24 Mar 2006, Jim Gallacher wrote:
>> Ville Silventoinen wrote:
>>>     req.filename = fname
>>>     req.content_type = ctype
>>>     req.set_content_length = flen
>>                            ^^^^^^^^
>> I assume this is a typo but just in case it's not, 
>> req.set_content_length is a method, not an attribute.
> Yes, that was a typo, sorry.
> Thanks for your comments.
> One colleague suggested using a named pipe. The mod_python process would 
> fork a child process, which would set up the named pipe for the 
> decompressed stream. The parent would wait until this is done and then 
> use the named pipe filename with req.sendfile. Any idea if something 
> like that would work?

I have not idea but it seems rather complicated and would still require 
modifying requestobject.c to expose the apache ap_send_fd call. I'm not 
convinced it would be worth the effort. What are you trying to achieve 
exactly that makes your orginal solution unacceptable?


More information about the Mod_python mailing list