Open egekorkan opened 1 year ago
@egekorkan Mhh, I think this was the default assumption. I wonder what we can/should do if the subprotocol is not given?
I think that this generally an interesting point for HTTP Bindings everywhere. There is no built-in mechanism for eventing in HTTP or to be specific, no mechanism can be assumed without a subprotocol field. I will open an issue in binding templates about it to discuss what should be standardized and whether longpoll should be the default mechanism.
Currently, the HTTP client implementation uses longpoll when it is not indicated in the subprotocol field: https://github.com/eclipse/thingweb.node-wot/blob/master/packages/binding-http/src/http-client-impl.ts#L159
It sort of makes sense but the reason for it is not super clear to me.