-
Notifications
You must be signed in to change notification settings - Fork 63
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
Consider defining an expiry date for a TD #916
Comments
I think it is a good idea. Just for added precision, TTL does not necessarily imply that the TD will change so even if a TD expires and a new one is fetched, the version can still be the same. |
Is there any reason that Thing Descriptions are different to any other web resource in this respect? The web already has a solution to this problem. See the HTTP Expires header and the Cache-Control header for finer grained control. |
I think the goal is to have something inside the TD since the document can be stored in a database and can be consumed by different protocols |
I strongly recommend against that. Caching is hard to get right at the best of times, without having to worry about ambiguity between the protocol and file format. I politely suggest resisting the temptation to re-invent features of web protocols with a WoT-specific solution in the name of being "protocol agnostic". There is nothing to stop a WoT server implementation from storing an expiry date in its database and exposing that in a protocol-specific way, without it being in the Thing Description. Note that CoAP also has its own caching model. |
Are we talking about a new field in the TD model that should have an expiration date? If I understand correctly w3c/wot-discovery#18 will define this outside of the TD, right? |
I believe this issue is about adding a new field inside the TD. In w3c/wot-discovery#18, we are exploring different options in the absence of such information inside the TD, especially for when the TD is submitted to a directory. |
In this case the version container might be the right place:
|
Doesn't the
|
By the way, this is now in the discovery spec: https://w3c.github.io/wot-discovery/#exploration-directory-registration-info |
TDs may get outdated and new versions will be available.
It may be important to remind users of TDs about that.
This is also useful for thing directories, there was a corresponding discussion in the discovery TF.
w3c/wot-discovery#18
The text was updated successfully, but these errors were encountered: