Modify Django settings variables in a middleware
Posted
by jack
on Stack Overflow
See other posts from Stack Overflow
or by jack
Published on 2010-03-21T00:09:24Z
Indexed on
2010/03/21
0:11 UTC
Read the original article
Hit count: 396
I set a variable MAX_REQUEST = 100 in settings.py
I write a middleware which may lower this value for request origining from a proxy ip address by the following code:
settings.MAX_REQUEST = 10
However, looks like the above modification affects all legitimate users.
Is it normal?
© Stack Overflow or respective owner