-
Notifications
You must be signed in to change notification settings - Fork 25
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 merging Profile protocol bindings into Protocol Binding and Payload Binding documents #248
Comments
Thank you for CCing me and for the detailed explanation of your ideas.
There might be some technicalities that we might need to discuss but I would at least try to work towards a convergence of Profiles and Protocol Bindings Templates. If we can work in synergy on these two aspects I think the overall result will be an improvement of the whole Web of Things architecture and standards. What I found odd, or maybe just interesting is that I don't find that much controversial the point you listed. Aren't they just additional constraints to be built on top of a new hypothetical Maybe what is useful here is to start with how we should update the current document template for |
Thanks for your feedback @relu91.
The potentially controversial part is that I'm suggesting all of those constraints would be part of the protocol binding document and payload binding documents as defaults, not "built on top of them" as part of the profile. The profile would just reference those documents and require that their defaults are used. Otherwise it's actually the "HTTP Profile" which is providing the "protocol binding", not the "HTTP Protocol Binding" document. Do you see the distinction? Currently there are two ways of providing a protocol binding (by using a profile or a protocol binding template). If you want to call the "HTTP Protocol Binding Template" the "HTTP Protocol Binding" then in my view it has to fulfil both of those functions. So for example:
All Consumers which implement the binding documents would have to implement these defaults. Consumers which only need to support Things which conform to the HTTP+JSON Profile would only need to implement these defaults. This goes quite a lot further than the current set of very basic defaults in the HTTP Protocol Binding Template document, but personally I think that's a good thing because it provides a greater level of interoperability by default. It also goes further than the JSON payload binding which is currently quite loosely defined in the Thing Description specification. I think I understand what you mean about platform binding templates (to the extent that I understand what they're going to be), but in this case we wouldn't be binding to a platform, we'd be defining one. We'd essentially be prescribing a default sub-protocol for using the Web of Things with a given protocol/payload format, but with the flexibility to override those defaults using a vocabulary to describe any other platform which uses that protocol. Sorry that's another long explanation, but I want to be clear about the extent of what I'm suggesting. Does it still sound OK to you?
As an example, the way I imagine this might look in the HTTP Binding Document is that there would be a section which looks a lot like the current Protocol Binding section of the HTTP Basic Profile, where it takes each operation type in turn and explains the default flow for how that operation would be implemented using HTTP. Similar to the current Example Sequences section in the HTTP Binding Template document, but rather than providing informative examples it would define normative defaults. (There could then be additional examples of how to override those defaults using the defined vocabulary terms). |
See w3c/wot-profile#285 (comment) for example document outlines of an HTTP Protocol Binding and JSON Payload Binding specifications if taking this approach. |
I have created a WoT HTTP Protocol Binding 2.0 (and companion WoT HTTP Basic Profile 2.0 ) strawman proposal to explore the ideas discussed in this issue in more detail. See my email on the WoT WG mailing list for more explanation. Feedback is welcome here. |
It has been suggested that in the next charter period the term "protocol binding template" might be renamed to "protocol binding" throughout W3C WoT specifications. E.g. the "WoT HTTP Binding Template" would become the "WoT HTTP Protocol Binding".
There's a long discussion, the summary of which is that I disagree with this change on the basis that:
There are several different suggestions in that thread for resolving this conflict, but one of them is to actually combine the concept of prescriptive protocol bindings from profiles with the concept of descriptive protocol bindings using protocol binding templates into a single type of document. The content of the protocol binding sections of profiles would be merged into "protocol binding" and "payload binding" documents as a set of defaults, which Things can then override using a semantic vocabulary. All Consumers implementing the protocol binding would implement those defaults.
This would allow a different approach to profiles where they just reference a particular protocol binding and payload binding document, instead of defining a protocol binding inside a profile. I've described this approach in detail here, but the basic idea is that a profile would prescribe a particular binding and require that conformant Things stick to its defaults rather than overriding them.
This approach could resolve the conflict between prescriptive vs. descriptive protocol bindings by combining them into a single concept, where the former is just a set of defaults for the latter. However, it will only work if the task force working on Binding Templates are happy with the idea of merging the prescriptive protocol bindings from profiles into the new protocol binding documents, as defaults.
Some of this would be quite straightforward, e.g.
GET
and200
forqueryaction
)writemultipleproperties
which is currently a bit ambiguous in the Thing Description specification)However, some areas might be more controversial, e.g.:
ActionStatus
payload format forqueryaction
andqueryallactions
operations and the whole concept of dynamic resources in action queuesreadmultipleproperties
operation is trickyevent
field is the name of the event/property, thedata
field is a JSON serialised payload and theid
field is a datestampThere might also be some tricky areas where the Protocol Binding and Payload Binding currently work together in a Profile, e.g. the JSON payload of a
queryaction
response contains ahref
member which is meant to contain an HTTP URL of an action status resource. This might have to be clarified in the profile itself.What do you think? Is this a feasible way forward?
If you think this level of detail would be too prescriptive as defaults in a protocol binding document then I don't think "protocol binding template" should be renamed to "protocol binding", because they don't actually provide a protocol binding. We'd continue to have two different ways of providing protocol bindings, using profiles and protocol binding templates.
CC @egekorkan @relu91
The text was updated successfully, but these errors were encountered: