W3C home > Mailing lists > Public > ietf-http-wg@w3.org > January to March 2010

Re: #29: correcting corrected_initial_age

From: Julian Reschke <julian.reschke@gmx.de>
Date: Mon, 08 Mar 2010 16:15:14 +0100
Message-ID: <4B951482.4040504@gmx.de>
To: Mark Nottingham <mnot@mnot.net>
CC: HTTP Working Group <ietf-http-wg@w3.org>, Alex Rousskov <rousskov@measurement-factory.com>, Roy Fielding <fielding@gbiv.com>
On 04.03.2010 05:39, Mark Nottingham wrote:
> We haven't heard back from Alex, and the other issue I mentioned didn't seem to get enough support to move on. So, I suggest we do the conservative thing:
>
> Current text:
>>    age_value     - Age header field-value received with the response
>>    date_value    - Date header field-value received with the response
>>    request_time  - local time when the cache made the request
>>                   resulting in the stored response
>>    response_time - local time when the cache received the response
>>    now           - current local time
>>
>>    apparent_age = max(0, response_time - date_value);
>>    corrected_received_age = max(apparent_age, age_value);
>>    response_delay = response_time - request_time;
>>    corrected_initial_age = corrected_received_age + response_delay;
>>    resident_time = now - response_time;
>>    current_age   = corrected_initial_age + resident_time;
>
> Replacement text:
>>    age_value     - Age header field-value received with the response;
>>                                 0 if not available.
>>    date_value    - Date header field-value received with the response;
>>                                 see [ref] for requirements regarding responses
>>                                 without a date_value.
>>    request_time  - local time when the cache made the request
>>                   resulting in the stored response
>>    response_time - local time when the cache received the response
>>    now           - current local time
>>
>>    apparent_age = max(0, response_time - date_value);
>>    response_delay = response_time - request_time;
>>    corrected_initial_age = max(apparent_age, age_value + response_delay)
>>    resident_time = now - response_time;
>>    current_age   = corrected_initial_age + resident_time;
>
> Comments?

I just spent some time staring at this, and I'd *really* feel better if 
we had a test case, that is:

- values for age_value, date_value, request_time, response_time, now
- result per RFC2616
- expected result

Best regards, Julian
Received on Monday, 8 March 2010 15:15:50 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 27 April 2012 06:51:16 GMT