W3C home > Mailing lists > Public > public-wot-ig@w3.org > July 2016

Re: Stability and Current Practises

From: Christian Groves <Christian.Groves@nteczone.com>
Date: Mon, 11 Jul 2016 16:24:37 +1000
To: Carsten Bormann <cabo@tzi.org>
Cc: Public Web of Things IG <public-wot-ig@w3.org>
Message-ID: <7953738d-aca5-a736-623f-d6ee5ae94169@nteczone.com>
Hello Carsten,

Please see below.

Regards, Christian


On 7/07/2016 4:22 PM, Carsten Bormann wrote:
> Hi Christian,
>
> Christian Groves wrote:
>> Hello,
>>
>> With regards to clause
>> 3.2.3.1/(http://w3c.github.io/wot/current-practices/wot-practices.html)
>> and the "stability option" is there a reason ms units were chosen? The
>> cache-control fields mentioned (e.g. CoAP Cache-Control and HTTP
>> Max-Age) are based on seconds.
> (HTTP Cache-Control and CoAP Max-Age?)
>
> Obviously, the SI base unit of interest here is the second.
> In metrology, quantities measured in seconds are usually represented as
> floating point values.
> Now there is some benefit from being able to express common values as
> integers.  I think ms is just an arbitrary choice for a sub-multiple
> unit that makes this more likely (it is also the base unit for time in
> Java, which may or may not be relevant to the IoT based on which part of
> the IoT you are thinking about).
[CNG] I'm familiar with metrology, however the Cache-Control Max-Age is 
defined to be a non-negative decimal integer. If the primary purpose of 
stability option is to map to the cache control and http max-age then it 
doesn't seem to follow that you make it a sub-multiple of a second. It 
means that for a given number of bits the time represented won't be the 
same. 32bits of ms doesn't equal the same length of time as 32bit s. 
Also it means the mapping is more complicated, e.g. is 1750ms mapped to 
a Max-Age value of 1s or 2s? It can't be mapped to 1.75s.

>
>> Also the value chosen for "irregular change" and "static value" seems
>> opposite to what is logical. "0" usually means no change. "-1" would
>> seem better to indicate something irregular (at least to me).
> 0 should be close in meaning to 1 ms.  Asymptotically, getting smaller
> and smaller values means more frequent change.  So irregular change (no
> stability at all) should be stability=0.
>
> Static value is an infinite period of stability.  Unfortunately, there
> is no common computer representation for an infinite integer, so the
> objective to represent this as an integer cannot be met.
[CNG] Funnily enough my 6 year old was asking why there was no infinity 
button on his calculator yesterday...
>    (JSON doesn't
> even have Infinite as a floating point value, but that is a limitation
> specific to JSON.) Since stability values never can be negative,
> adopting a negative value for "static" is at least unambiguous, if not
> particularly logical; in a type system such as JSON's the value "true"
> would be more logical.
>
> Grüße, Carsten
>
Received on Monday, 11 July 2016 06:27:34 UTC

This archive was generated by hypermail 2.3.1 : Monday, 11 July 2016 06:27:34 UTC