Skip to content

ObserveProperty with uri vars #539

Open
@ferllings

Description

@ferllings

Hello,
Could someone clarifies something for me?
In the ObserveProperty method: https://w3c.github.io/wot-scripting-api/#the-observeproperty-method

This algorithm allows for only one active Subscription per Property. If a new Subscription is made while an existing Subscription is active the runtime will throw an NotAllowedError.
And #6 confirms
If thing.[activeObservations][propertyName] [=map/exists], [reject] promise with a [NotAllowedError] and stop.

But in the case of using uriVars, do we consider the subscription is the same, even if the uriVars are different?

#8 indicates:

Make a request to the underlying platform to observe the [Property] identified by propertyName with form and optional URI templates given in options' uriVariables.

What if we already made a previous request, .../propertyA?v=X
but we want to make a new request for .../propertyA?v=Y

And I believe there is a mistake in subscribeEvent() https://w3c.github.io/wot-scripting-api/#the-subscribeevent-method
#6 says

If thing.[activeSubscriptions][eventName] DOES NOT exist, reject promise with a [NotAllowedError] and stop.

Thanks for your help?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugError, flaw or fault in the specification that causes misunderstandings and/or incorrect/unexpectedquestionAny generic question and/or commentuse caseDescribes a scenario that may be useful for technical decisions

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions