You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
websockets-pubsub would subscribe to events from WacLdp rather than from BlobTree, so they would contain URLs instead of storage paths.
websockets-pubsub can then call WacLdp.checkAccess(webId: URL, origin: string, resource: URL, mode: URL) instead of having to pass a BlobTree and checking access on a storage path of that BlobTree.
in general, cleaner separation between the storage layer which thinks in terms of storage paths, and the WacLdp module as a whole, which exposes interfaces (its http request handler but also its change event and accessCheck function) that think in terms of URLs
The pod-server requires both websockets-pubsub's Hub object and wac-ldp's App object.
Currently wac-ldp's Server constructor does this:
And wac-ldp exposes BlobTree and makeHandler, but I'm thinking of changing this to:
The advantage would be:
WacLdp.checkAccess(webId: URL, origin: string, resource: URL, mode: URL)instead of having to pass a BlobTree and checking access on a storage path of that BlobTree.