-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New %codes for computing message forwarding delays #260
base: bag64a
Are you sure you want to change the base?
Changes from all commits
334d87a
f19be20
03361d8
98ccecb
b34e422
e843568
44b7842
fa1b0ad
330ef13
c410a1c
8a8da4b
380f33a
bfb0102
a4f5a99
e4fad62
38038ad
109de07
507ab43
38daef3
57fda97
a9c51e7
3b23fd3
0a19226
626598c
8865b6f
bf09e96
7b4134b
c0dd69b
7ab3b89
ed0be1a
88c458c
3fb4e85
ff53998
235e422
692aaf8
12d9909
55e55d7
9d3b7e5
6e9189f
d8af1f5
9dd2725
ba8d04b
b70587b
cfff89f
3317bda
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4868,6 +4868,93 @@ DOC_START | |
values may significantly understate or exaggerate actual times. | ||
Do not use this measurement unless you know it works in your case. | ||
|
||
The following x_time %codes produce approximate absolute time of event | ||
x in <full seconds since epoch>.<fractional seconds> format. Squid | ||
should remember these events when they happen, but various temporary | ||
implementation deficiencies may result in information loss for | ||
unsuccessful transactions. Using logged times for erroneous | ||
transaction analysis requires understanding of these Squid-version | ||
specific limitations and is not recommended. | ||
|
||
For CONNECT tunnels, all bytes (and a successful connection closure | ||
indication) received from the client and forwarded to the server are | ||
considered to be a part of the CONNECT request, while all bytes (and a | ||
successful connection closure indication) received from the server and | ||
forwarded to the client are considered to be a part of the CONNECT | ||
response. | ||
|
||
A failed socket read(2) or write(2) call is normally not reflected in | ||
these %codes. Such I/O failures usually result in transaction errors. | ||
|
||
If Squid received (or sent) the entire message in one network I/O (or | ||
equivalent), then the corresponding x_first_byte_time value will be | ||
the same as x_last_byte_time value. | ||
|
||
received_request_first_byte_time: Squid starts parsing an incoming | ||
client HTTP or FTP request. For requests generated by Squid (e.g., | ||
to download missing intermediate certificates or to fake a CONNECT | ||
request during SslBump operations), this time is the time of that | ||
request generation. | ||
|
||
In most cases, Squid receives the entire request header in one | ||
network read(2), but it is possible that the header will not be | ||
fully received (and parsed) until a later time. Thus, this %code | ||
time does not always correspond to the time when Squid starts | ||
evaluating (beyond basic parsing) and forwarding a request. | ||
|
||
In most cases, a client does not send the next request on a | ||
client-to-Squid connection until Squid responds to the previous | ||
one, but it is possible that Squid reads bytes belonging to | ||
multiple requests in one network read(2). Squid may also read | ||
PROXY protocol or TLS messages before reading HTTP or FTP request | ||
bytes. In such and similar cases, this %code value does not match | ||
the last read(2) time because Squid has to spend time on handling | ||
other read bytes first. | ||
|
||
Currently, this time may not match %tS because %tS timestamps is | ||
created when the entire request header has been parsed. | ||
|
||
Client-to-Squid TCP connection acceptance and client-Squid TLS | ||
handshake (if any) happen earlier. REQMOD adaptation of read bytes | ||
(if any) happens later. | ||
|
||
received_request_last_byte_time: The last time Squid received HTTP or | ||
FTP bytes (or a successful connection closure indication) | ||
associated with the current request. | ||
|
||
sent_request_first_byte_time: Squid successfully sent the first HTTP | ||
or FTP request byte (at least) to an origin server or cache_peer. | ||
|
||
If Squid retries or re-forwards a failed request, then this %code | ||
reflects the _last_ such attempt. | ||
|
||
Any Squid-to-peer TCP connection establishment, CONNECT tunnel | ||
establishment, and TLS handshake happen earlier. RESPMOD | ||
adaptation happens later. | ||
|
||
sent_request_last_byte_time: The last time Squid successfully sent | ||
HTTP or FTP bytes associated with the current request. See | ||
%sent_request_first_byte_time %code for more caveats. | ||
|
||
received_response_first_byte_time: Squid successfully received the | ||
first HTTP or FTP response byte from an origin server or | ||
cache_peer. | ||
|
||
If Squid retries or re-forwards a failed request, then this %code | ||
reflects the response in the _last_ such attempt. | ||
|
||
received_response_last_byte_time: The last time Squid received HTTP or | ||
FTP bytes (or a successful connection closure indication) | ||
associated with the current response. See | ||
%received_response_first_byte_time %code for more caveats. | ||
|
||
sent_response_first_byte_time: Squid successfully sent the first HTTP | ||
or FTP response byte (at least) to the client. | ||
|
||
sent_response_last_byte_time: The last time Squid successfully sent | ||
HTTP or FTP bytes associated with the current response to the | ||
client. See %sent_response_first_byte_time %code for more caveats. | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The PR implementation differs from the proposed definitions (for request_first_read/request_last_read):
We could simplify request_first_read/request_last_read calculation, ignoring parsing time and measuring them from ClientHttpRequest constructor. However, this approach would minimize request_first_read/request_last_read difference in some cases, concealing this useful information from the admin. |
||
Access Control related format codes: | ||
|
||
et Tag returned by external acl | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change is out of scope - it fixes a build error.