Skip to content
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

Clarify read-only/write-only behavior #854

Closed
mlagally opened this issue Dec 5, 2019 · 5 comments
Closed

Clarify read-only/write-only behavior #854

mlagally opened this issue Dec 5, 2019 · 5 comments
Labels
Defer to next TD spec version This topic is not covered in this charter, maybe included for the next TD version.

Comments

@mlagally
Copy link
Contributor

mlagally commented Dec 5, 2019

Current language for property affordance is a bit ambiguous about read-only/write only behavior:
https://w3c.github.io/wot-thing-description/#propertyaffordance

An Interaction Affordance that exposes state of the Thing. This state can then be retrieved (read) and optionally updated (write).

The intention of the text is to indicate that the state can always be retrieved with a read operation and can be optionally updated with a write operation.

The paragraph should be changed to make this more clear, e.g.:

An Interaction Affordance that exposes state of the Thing. The state MUST be retrievable with a read operation and MAY be optionally updated with a write operation.

@mlagally mlagally changed the title Clarify Clarify read-only/write-only behavior Dec 5, 2019
@sebastiankb sebastiankb added the Defer to next TD spec version This topic is not covered in this charter, maybe included for the next TD version. label Dec 5, 2019
@takuki
Copy link
Contributor

takuki commented Feb 14, 2020

A Property affordance has a member "writeOnly".
When writeOnly is true, the property cannot be read.
I think the text in question is a bit obsolete.

@takuki
Copy link
Contributor

takuki commented Feb 14, 2020

In TD call on 2/14, we discussed and suggest to say explicitly something like "devices can provide both read and write operations, or read operation only, or write operation only, and both read only and write only combination is prohibited."

@zolkis
Copy link

zolkis commented Feb 19, 2020

Another way to look at it is based on capabilities, i.e. a Property can be readable, writable and observable.

For instance, it is not clear if "writeOnly" always also means not observable in a TD?
(at least in OCF, observability requires readability).

@JKRhb
Copy link
Member

JKRhb commented Feb 13, 2021

For instance, it is not clear if "writeOnly" always also means not observable in a TD?
(at least in OCF, observability requires readability).

I was just asking myself this very question – have there been any updates on this matter in the meantime? As, at least in CoAP, the (de)registration of observers is part of a GET request (and therefore a read operation) I also assumed that writeOnly implies that a property is not observable.

@egekorkan
Copy link
Contributor

Call of 15.06:

  • We do agree that there are only writeable properties.
  • There are multiple people rooting for bringing back writeable and readable. readOnly and writeOnly are from JSON Schema but they are not actual validation terms and are not used much.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Defer to next TD spec version This topic is not covered in this charter, maybe included for the next TD version.
Projects
None yet
Development

No branches or pull requests

6 participants