You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Bill Stoddard <re...@attglobal.net> on 2000/08/16 03:52:14 UTC
AP_BUCKET_FILE read method
I've been trying to understand the bucket code and implement ap_bucket_file. I can see two distinct
behaviours of the read method I would like to see: 1. pass in a buffer and get data out, 2. pass in
a paramater and get an apr_file_t out. I cannot get the same bahaviour out of the same read
function. Case 2 is useful when I want to call apr_sendfile in the core filter. This seems to
suggest adding an additional method to the bucket_t (I don't have a good name for it) in addition to
the read or creating a different type of bucket. Thoughts?
Bill
Re: AP_BUCKET_FILE read method
Posted by Tony Finch <do...@dotat.at>.
Bill Stoddard <re...@attglobal.net> wrote:
>
>I've been trying to understand the bucket code and implement
>ap_bucket_file. I can see two distinct behaviours of the read method
>I would like to see: 1. pass in a buffer and get data out, 2. pass in
>a paramater and get an apr_file_t out. I cannot get the same
>bahaviour out of the same read function. Case 2 is useful when I want
>to call apr_sendfile in the core filter. This seems to suggest adding
>an additional method to the bucket_t (I don't have a good name for
>it) in addition to the read or creating a different type of bucket.
>Thoughts?
I envisioned that the core filter would be given special dispensation
to diddle around inside file buckets so that it can call sendfile,
since that is a special optimisation that's only applicable to FILE
buckets. Unless you think other sendfileable bucket types might turn
up in the future...
Tony.
--
en oeccget g mtcaa f.a.n.finch
v spdlkishrhtewe y dot@dotat.at
eatp o v eiti i d. fanf@covalent.net