Welcome! Log In Create A New Profile

Advanced

Re: further "Hacking" the event model of Nginx

Johan Bergström
July 16, 2010 03:56AM
Hello,

On 16 jul 2010, at 09.33, Vincent Huang wrote:

> Johan Bergström wrote:
>> Hey,
>>
>> Wouldn't http://wiki.nginx.org/NginxXSendfile work for bouncing your
>> request between servers without modifying source code (thats how I do
>> it) ?
>>
>> Cheers,
>> Johan
>
> Thanks for your help.
> I need hold the response from one backend and send it to another(not
> directory use the backed response as the result to client), so I have to
> write some code inside nginx....
> Thanks again;-)

The example might be a bit misleading in your case. What X-Accel-Redirect does is take precedence over the location uri. You don't specifically have to pass the location match to a directory for downloads, you might just as well pass it along to another backend.

This is how my setup looks like:
- incoming get /foo
- location match on /foo that passes to fcgi backend
- fcgi backend analyzes request and returns response with x-accel-redirect /backend1/foo
- location match on /backend1 passes the request along to http backend
- backend responds with "final" request, master sends back to client

>
> Regards,
> Vincent
> --
> Posted via http://www.ruby-forum.com/.
>
> _______________________________________________
> nginx mailing list
> nginx@nginx.org
> http://nginx.org/mailman/listinfo/nginx


_______________________________________________
nginx mailing list
nginx@nginx.org
http://nginx.org/mailman/listinfo/nginx
Subject Author Posted

further "Hacking" the event model of Nginx

Vincent Huang July 16, 2010 12:08AM

Re: further "Hacking" the event model of Nginx

replay July 16, 2010 12:32AM

Re: further "Hacking" the event model of Nginx

Vincent Huang July 16, 2010 12:54AM

Re: further "Hacking" the event model of Nginx

replay July 16, 2010 01:12AM

Re: further "Hacking" the event model of Nginx

Vincent Huang July 16, 2010 02:52AM

Re: further "Hacking" the event model of Nginx

Johan Bergström July 16, 2010 03:30AM

Re: further "Hacking" the event model of Nginx

Vincent Huang July 16, 2010 03:40AM

Re: further "Hacking" the event model of Nginx

Johan Bergström July 16, 2010 03:56AM

Re: further "Hacking" the event model of Nginx

Vincent Huang July 16, 2010 04:52AM

Re: further "Hacking" the event model of Nginx

Maxim Dounin July 17, 2010 03:00AM

Re: further "Hacking" the event model of Nginx

Ashish S Dev March 08, 2012 09:14PM

Re: further "Hacking" the event model of Nginx

Ashish S Dev March 08, 2012 09:16PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 141
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready