Re: ap_sub_req_lookup_file vs ap_sub_req_lookup_uri
i notice mod_include is implemented as a filter. is this the preferred way to implment ap_sub_req_lookup_file? currently i implement ap_sub_req_lookup_file within a handler responsible for calling the appropriate files. within the handler i only have access to the output_filters, input_filters, proto_output_filters and proto_input_filters variables in the request_rec as it is not included in a filter chain including any of these variables in the ap_sub_req_lookup_file call does not contcatenate the files. when performing subrequests to concatenate content do you need to run the filter chain? From: Ben Noordhuis To: modules-dev@httpd.apache.org Sent: Tue, September 14, 2010 1:17:43 PM Subject: Re: ap_sub_req_lookup_file vs ap_sub_req_lookup_uri You call it with next_filter=NULL instead of f->next? That'll skip the regular filter chain, probably not what you want.
Re: Apache mods - possible to send request on?
On 14 Sep 2010, at 18:33, Paul Donaldson wrote: > Hello, > > I am completely new to Apache and Apache Modules, and so I'd be grateful if > someone could tell me whether it might be possible to write a module that > takes > elements of the request and makes a request to another web server at an > arbitrary URL? Yes of course you can! You can run a subrequest that'll use mod_proxy. Or you can use your choice of HTTP client code. -- Nick Kew
Re: Apache mods - possible to send request on?
write a module that takes elements of the request and makes a request to another web server at an arbitrary URL? See the proxy modules for examples. -- Ray Morris supp...@bettercgi.com Strongbox - The next generation in site security: http://www.bettercgi.com/strongbox/ Throttlebox - Intelligent Bandwidth Control http://www.bettercgi.com/throttlebox/ Strongbox / Throttlebox affiliate program: http://www.bettercgi.com/affiliates/user/register.php On 09/14/2010 12:33:14 PM, Paul Donaldson wrote: Hello, I am completely new to Apache and Apache Modules, and so I'd be grateful if someone could tell me whether it might be possible to write a module that takes elements of the request and makes a request to another web server at an arbitrary URL? I don't want to redirect the client, I just want to be able to get the request, look for elements in the query string of the request, make an asynchronous http request to another web server, meanwhile the original request is handled in the normal way. Many Thanks, Peter
Re: ap_sub_req_lookup_file vs ap_sub_req_lookup_uri
ben, thank you for pointing me in the right direction. the only difference i see between my call(s) to ap_sub_req_lookup_file and the call(s) within mod_include is the inclusion of the filter parameter. maybe my understanding of filters is incorrect. are filters only used to modify response content or are filters required to concatenate subrequest content for the response? peter From: Ben Noordhuis To: modules-dev@httpd.apache.org Sent: Tue, September 14, 2010 9:39:39 AM Subject: Re: ap_sub_req_lookup_file vs ap_sub_req_lookup_uri ap_sub_req_lookup_file() should work, it's what mod_include uses when you have on your page. You might want to take a look at its source.
Re: ap_sub_req_lookup_file vs ap_sub_req_lookup_uri
ap_sub_req_lookup_file() should work, it's what mod_include uses when you have on your page. You might want to take a look at its source.
ap_sub_req_lookup_file vs ap_sub_req_lookup_uri
when using ap_sub_req_lookup_file to concatenate the contents of two files only the contents of the first file are delivered in the response. alternatively if i use ap_sub_lookup_uri to concatenate the contents of two web pages, the aggregated content is delivered in the response. what is the difference between using ap_sub_req_lookup_file and ap_sub_req_lookup_uri? should you use ap_sub_req_lookup_file to determine the file's existence and only if you are delivering one file in the response? how do you concatenate the contents of two or more files on your local drive? thank you for your help. peter
Re: Peek at request from within Connection input filter
On 14 Sep 2010, at 04:08, Jodi Bosa wrote: > Is there a way that I can "peek" at the request from within a Connection > filter? In other words, I need to examine the actual HTTP request in order > to affect something in another Connection filter. A constraint is that I > cannot modify this other Connection filter. No. There isn't a request object in a connection filter. A connection may be handling multiple requests which can't be deterministically mapped. Or there may be no Request at all if the protocol is not HTTP. If you can ensure there is a meaningful Connection-Request correspondence in your app, use the connection's configuration record to pass information to/from the request(s). -- Nick Kew