Re: [mp2] [PATCH] implement ap_save_brigade

[prev] [thread] [next] [Date index for 2005/05/13]

From: Stas Bekman
Subject: Re: [mp2] [PATCH] implement ap_save_brigade
Date: 05:13 on 13 May 2005
Stas Bekman wrote:
> Dorian Taylor wrote:
> 
>>> it'd be nice to run a benchmark. I wonder why ap_save_brigade was 
>>> marked as ! in the map file. Which normally means it's not going to 
>>> be exposed. Did you by chance look at the archives for possible 
>>> references to it?
>>
>>
>>
>> there's a mention of it in the APR::Bucket manpage. i couldn't find
>> anything else aside from a thread on dev@xxxxx.xxxxxx.xxx:
>>
>> http://www.mail-archive.com/dev@xxxxx.xxxxxx.xxx/msg22884.html
>>
>> and something else i wrote to this list asking about it.
>>
>> it's been labeled ! since its initial revision in svn though, apparently.
>>
>> perhaps dougm could shed some light?
>>
>> i came across the function via
>> http://www.outoforder.cc/projects/apache/mod_transform/ , where the
>> author uses it to retrieve arbitrary output from what may or may
>> not actually be a file on the filesystem. i've been using it to do
>> things like feeding subversion PROPFIND responses into xslt processors.
> 
> 
> It will work just the same when flattening the data on each request. I'm 
> not sure what happens when a filehandle bucket is setaside, but normal 
> buckets will be copied, that's why it'd be interesting to see a 
> benchmark whether it's a better idea to use that approach.
> 
> Joe, do you have any insights on this topic?

I'm not getting very far with this, Dorian. Neither httpd-dev nor apr-dev 
are taking it anywhere. So at the moment ap_save_brigade is sort of an 
unstable API, so other developers think we shouldn't expose it in the core 
API. So at the moment you have two options:

1) write an XS code in your module which will add this code.

2) rewrite the code not to use this API, instead use a scalar buffer or an 
array and append the data their flattening the brigades on each invocation.

Please let us know whether this works for you. Thanks.

        -- 
        __________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@xxxxxx.xxx http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

(message missing)

[mp2] [PATCH] implement ap_save_brigade
Dorian Taylor 18:22 on 09 May 2005

Re: Decaying Performance under newer apache/mp versions
Ricardo Ramos Massaro 20:08 on 09 May 2005

Re: [mp2] [PATCH] implement ap_save_brigade
Stas Bekman 21:37 on 09 May 2005

Re: [mp2] [PATCH] implement ap_save_brigade
Dorian Taylor 22:21 on 09 May 2005

Re: [mp2] [PATCH] implement ap_save_brigade
Stas Bekman 23:00 on 09 May 2005

Re: [mp2] [PATCH] implement ap_save_brigade
Dorian Taylor 23:30 on 09 May 2005

Re: [mp2] [PATCH] implement ap_save_brigade
Stas Bekman 01:31 on 10 May 2005

Re: [mp2] [PATCH] implement ap_save_brigade
Stas Bekman 05:13 on 13 May 2005

Re: [mp2] [PATCH] implement ap_save_brigade
Dorian Taylor 19:48 on 17 May 2005

Re: [mp2] [PATCH] implement ap_save_brigade
Stas Bekman 19:51 on 17 May 2005

Generated at 15:53 on 25 May 2005 by mariachi v0.52