url_rewrite_timeout

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

url_rewrite_timeout

ygirardin
Hi,


I'm trying to use the new squid4 directive url_rewrite_timeout.


In order to make sure it works my rewritter is blocking to enable the
timeout.

But nothing happen, I thought my browser will receive a 500 error with
the following configuration but nope nothing happend and no trace in
cache.log.


Here is my configuration :


url_rewrite_timeout 10 seconds on_timeout=fail


What am i doing wrong ?


Thank you

_______________________________________________
squid-users mailing list
[hidden email]
http://lists.squid-cache.org/listinfo/squid-users
Reply | Threaded
Open this post in threaded view
|

Re: url_rewrite_timeout

Amos Jeffries
Administrator
On 31/07/18 19:35, ygirardin wrote:

> Hi,
>
>
> I'm trying to use the new squid4 directive url_rewrite_timeout.
>
>
> In order to make sure it works my rewritter is blocking to enable the
> timeout.
>
> But nothing happen, I thought my browser will receive a 500 error with
> the following configuration but nope nothing happend and no trace in
> cache.log.
>
>
> Here is my configuration :
>
>
> url_rewrite_timeout 10 seconds on_timeout=fail
>
>
> What am i doing wrong ?
>

What URL are you requesting?

What shows up in access.log ?

Does the browser actually use the proxy?

Perhapse using something less likely to use non-HTTP protocols for the
fetch will show things better. Try squidclient to do the fetch.

Amos
_______________________________________________
squid-users mailing list
[hidden email]
http://lists.squid-cache.org/listinfo/squid-users
Reply | Threaded
Open this post in threaded view
|

Re: url_rewrite_timeout

ygirardin
Hi


Of course my browser used my proxy.


I try to request www.perdu.com (that's a simple website with only http).


Indeed when I look on the access.log I have the following trace :


1533023517.502   4990 10.1.0.39 NONE_ABORTED/000 0 GET http://perdu.com/ 
- HIER_NONE/- -

So seems like the connection is abort, but this should not stop my
rewriter ?

And if my rewritter reply OK after the 10 seconds timeout the page is
well displayed in my browser. I was expecting to receive a 500 error.




On 31/07/2018 09:43, Amos Jeffries wrote:

> On 31/07/18 19:35, ygirardin wrote:
>> Hi,
>>
>>
>> I'm trying to use the new squid4 directive url_rewrite_timeout.
>>
>>
>> In order to make sure it works my rewritter is blocking to enable the
>> timeout.
>>
>> But nothing happen, I thought my browser will receive a 500 error with
>> the following configuration but nope nothing happend and no trace in
>> cache.log.
>>
>>
>> Here is my configuration :
>>
>>
>> url_rewrite_timeout 10 seconds on_timeout=fail
>>
>>
>> What am i doing wrong ?
>>
> What URL are you requesting?
>
> What shows up in access.log ?
>
> Does the browser actually use the proxy?
>
> Perhapse using something less likely to use non-HTTP protocols for the
> fetch will show things better. Try squidclient to do the fetch.
>
> Amos
> _______________________________________________
> squid-users mailing list
> [hidden email]
> http://lists.squid-cache.org/listinfo/squid-users

_______________________________________________
squid-users mailing list
[hidden email]
http://lists.squid-cache.org/listinfo/squid-users
Reply | Threaded
Open this post in threaded view
|

Re: url_rewrite_timeout

Amos Jeffries
Administrator
On 31/07/18 19:56, ygirardin wrote:

> Hi
>
>
> Of course my browser used my proxy.
>
>
> I try to request www.perdu.com (that's a simple website with only http).
>
>
> Indeed when I look on the access.log I have the following trace :
>
>
> 1533023517.502   4990 10.1.0.39 NONE_ABORTED/000 0 GET http://perdu.com/
> - HIER_NONE/- -
>
> So seems like the connection is abort,

It is. Client aborted/disconnected after 5 sec. Your re-writer timeout
is 10 sec.


> but this should not stop my
> rewriter ?

The transaction ended before any rewriter action was needed. There is
nothing to be done by Squid for this client.

>
> And if my rewritter reply OK after the 10 seconds timeout the page is
> well displayed in my browser. I was expecting to receive a 500 error.
>

Helper responses are cached when possible. If your test requests the
same URL twice in a row from the same Squid the second one can use a
result provided for the first client request. Like so:


1) Client A connects, requests http://perdu.com/

2) Squid asks helper for URL alterations of http://perdu.com/

3) client A disconnects,

4) helper request A times out, client already gone, nothing happens.

5) helper responds with result "OK", Squid caches that result.

6) client B connects, requests http://perdu.com/

7) Squid uses result "OK" for helper lookup http://perdu.com/



Amos
_______________________________________________
squid-users mailing list
[hidden email]
http://lists.squid-cache.org/listinfo/squid-users