Skip to content
This repository was archived by the owner on Aug 25, 2023. It is now read-only.
This repository was archived by the owner on Aug 25, 2023. It is now read-only.

Implementation questions #2

Description

@acoburn

Realizing that websockets haven't actually been implemented here (yet!), I would be very interested in hearing how you plan to design this feature. I have implemented this for Trellis according to the SOLID specification, but I haven't yet merged the implementation into master. Eventually, I'd like to get clarification in the specification itself, but having some implementation experience can be really useful when writing up an issue for the spec. I would be interested if any one has insights about any of these questions:

  1. The WebSocket protocol itself does not support authentication (BasicAuth is, effectively, deprecated), and the SOLID spec is silent about both AuthN and AuthZ for WebSockets. One thought I had involved having a client send an auth <token> request before the sub <URL> request, applying the same WebACL rules that exist for resource access.

  2. There are no defined server responses to client requests. For instance, if the auth method is supported, should the server indicate whether that request succeeded? What if a client tries to subscribe to a resource URL that doesn't exist or which is not in the domain of the server? If auth is supported, what if a client subscribes to a resource that the client can't access? What if the client sends a syntactically invalid payload?

  3. Can a client send multiple sub <URL> requests? That is, can a single WebSocket connection be used to listen to multiple resources? Or would a second request effectively end the first request?

  4. Should the payloads be more structured than just <command> <URL>? I like the simplicity of the current structure, but if JSON-LD was used, it might make it easier to extend the existing behaviors (it may also make the protocol more difficult to consume and implement).

  5. If a client subscribes to a container (e.g. /container), should that client be notified of changes only to direct descendants (e.g. /container/child) or all descendants, transitively (e.g. /container/subcontainer/subsubcontainer/child)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions