-
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
observeallproperties
and unobserveallproperties
clarification
#1084
Comments
Sure, a delta-based approach would be more efficient. However, this is kind of a new little sub-protocol that needs to be defined somewhere. Maybe this is also a topic for the WoT Profile? |
I can see pros for both approaches. Does it make sense to have a way to indicate in a TD whether |
I suggest that The specification does say:
So my assumption is that for a property with a type of boolean, the payload of an observeallproperties notification would look something like:
This tells you which property has changed and what it's new value is. I also think it it would be reasonable for a Web Thing to batch together multiple property changes into a single message. I agree it's really not clear from the specification how this operation is expected to work beyond that, it will vary a lot depending on protocol. WebThings doesn't currently implement For the Core Profile we will need to decide on a default mechanism for observe operations (if they are supported) using HTTP, which might help excercise this feature. |
I also like sending only the ones who have changed. If I need to sort the changed values somehow, I would prefer doing single observe operations. Regarding whether this is a subprotocol or not, I think that sending all values is also a subprotocol, we are prescribing how something should happen. In WebThings, I would say that there is |
PR by @benfrancis at w3c/wot-architecture#605 says that only updated values should be sent. I would propose closing it here since the decision will be made at architecture specification. |
In the call of 21.07 we have decided to close this issue. Objections to the meaning of this operation should be done at the w3c/wot-architecture#605 |
While working on the PR for #1074 and the discussion on #1082 made me think of the meaning behind
observeallproperties
andunobserveallproperties
. Actually, there is literally no text explaining what these operations do, all we can do is wishful thinking.@sebastiankb said in the last F2F that
observeallproperties
returns all the property values when one property value changes, whether the rest are changed or not. At the time, I didn't think too much about it but now that I do, it does not make sense. If a Consumer gets all property values, it needs to find out which ones have changed and at that point, it becomes no different thanreadallproperties
(I think it is even worse in this case). So the TF needs to agree what is the behavior behind this operation.Also, this issue should raise awareness that we are putting new features into the spec that has no clear way of implementing them. Additionally, there is no implementation of this, raising further concerns in my opinion.
See also: eclipse-thingweb/node-wot#405 and w3c/wot-scripting-api#312
The text was updated successfully, but these errors were encountered: