Welcome! Log In Create A New Profile

Advanced

Re: limit_req is not working in virutal location?

Francis Daly
January 11, 2018 08:14AM
On Thu, Jan 11, 2018 at 03:32:07AM -0500, pva wrote:

Hi there,

I'm slightly guessing, so apologies if I mislead you and hopefully someone else
will correct this if necessary...

> Hi. Could you, please, explain why limit_req in @limitspeed location is not
> working in case of redirect to @allowed virtual location and works in case I
> copy @allowed virtual location contents inside @limitspeed?

I think that "return" happens before, and therefore effectively overrides
"limit_req".

You'll want your "limit_req" effective in a location where some real
work is done to create the response, in order for it to actually limit
the response rate.

(So either replace "return" with the content of the other location,
as you did; or add the limit_req into the other location.)

f
--
Francis Daly francis@daoine.org
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

limit_req is not working in virutal location?

pva January 11, 2018 03:32AM

Re: limit_req is not working in virutal location?

Francis Daly January 11, 2018 08:14AM

Re: limit_req is not working in virutal location?

pva January 11, 2018 10:47AM

Re: limit_req is not working in virutal location?

Maxim Dounin January 11, 2018 10:58AM

Re: limit_req is not working in virutal location?

pva January 11, 2018 12:22PM

Re: limit_req is not working in virutal location?

Maxim Dounin January 11, 2018 01:16PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 130
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 500 on July 15, 2024
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready