httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Graham Leggett <minf...@sharp.fm>
Subject Re: POST subrequests via mod_proxy
Date Wed, 13 Jan 2010 10:21:26 GMT
On 13 Jan 2010, at 12:07 PM, Sorin Manolache wrote:

> I understand. However, I don't want to make a subrequest with the body
> of the main request. I want to be able to make a subrequest with a
> totally new request body.
>
> For example:
>
> The client sends to my server:
>
> POST /server_url
> (main) request body: body_from_client_to_server
>
> My server would make a subrequest to a backend:
>
> POST /backend_url
> subrequest body: body_from_server_to_backend
>
> Or even this scenario:
>
> Client to my server:
> GET /server_url
>
> My server to a backend:
>
> POST /backend_url
> subrequest body: blabla

In this case, you want to create a simple input filter, which puts  
your intended request body into a brigade, and then passes the brigade  
(containing your body) to whatever is making the request.

Look in trunk for the module that implements the KEPT_BODY filter, it  
does the same thing and will give you an example of how it is done.

Regards,
Graham
--


Mime
View raw message