inrupt/solid-client-notifications-js

Inconsistant messaging

scenaristeur opened this issue · 1 comments

Looking for using notification I use a container at https://pod.inrupt.com/spoggy/public/game/ (shared with everyone can read/write/modify).

I want every user to be notified when a new .ttl file is created in this container, and be notified everytime each file in this folder is modified.

so i create a first web socket to https://pod.inrupt.com/spoggy/public/game/
and then looking at the files in the container, create a new websocket for each of the files in it .
First question : Is it the good way to be notified of each change in any file ? or is there something like a wildcard that could be used like "subscribe to https://pod.inrupt.com/spoggy/public/game/* " ?

Playing a little with it i see some inconsistency : for example, sometimes user is notified when a new file is created, sometimes not, sometimes he is notified when a resource is modified, sometimes not.

Here is a quick demo of the inconsistency : https://youtu.be/m6TY-K-_61Q

And the functionnal app https://scenaristeur.github.io/game-sync/ (you must login with "Broker Pod Inrupt" before sending changes)

The create button create a new resources, and the list of resources should be updated for everyone.
Then selecting a resource allow to modify it with 4 buttons "up, down, right, left". When a resource is modified, every other user should receive the message, but whereas the websocket indicates that the subscribtion has been made to a specific topic (container or resource) the message does not arrive each time. sometimes yes & sometimes not.

Do i misuse notification lib or is it something on the ESS server ?

here is my code https://github.com/scenaristeur/game-sync/blob/9a21ac9d6002b22a14ed911f547f1143b0365bc0/src/plugins/solid-sync.js#L68


 System:
   OS: Linux 5.4 Linux Mint 20.1 (Ulyssa)
   CPU: (4) x64 Intel(R) Core(TM) i7-3520M CPU @ 2.90GHz
   Memory: 1.70 GB / 7.60 GB
   Container: Yes
   Shell: 5.0.17 - /bin/bash
 Binaries:
   Node: 14.17.2 - /usr/bin/node
   npm: 7.19.1 - /usr/bin/npm
 Browsers:
   Chromium: 91.0.4472.114
   Firefox: 89.0.2
 npmPackages:
   @inrupt/solid-client: ^1.10.0 => 1.10.0 
   @inrupt/solid-client-authn-browser: ^1.9.1 => 1.9.1 
   @inrupt/solid-client-notifications: ^0.1.0 => 0.1.0 
   @inrupt/vocab-common-rdf: ^0.7.4 => 0.7.4 
   @inrupt/vocab-inrupt-common: ^0.7.4 => 0.7.4 
   @inrupt/vocab-solid-common: ^0.7.4 => 0.7.4 
   @vue/cli-plugin-babel: ~4.5.0 => 4.5.13 
   @vue/cli-plugin-eslint: ~4.5.0 => 4.5.13 
   @vue/cli-plugin-pwa: ~4.5.0 => 4.5.13 
   @vue/cli-plugin-router: ~4.5.0 => 4.5.13 
   @vue/cli-plugin-vuex: ~4.5.0 => 4.5.13 
   @vue/cli-service: ~4.5.0 => 4.5.13 
   babel-eslint: ^10.1.0 => 10.1.0 
   bootstrap: 4.5.3 => 4.5.3 
   bootstrap-vue: ^2.21.2 => 2.21.2 
   core-js: ^3.6.5 => 3.15.2 
   eslint: ^6.7.2 => 6.8.0 
   eslint-plugin-vue: ^6.2.2 => 6.2.2 
   register-service-worker: ^1.7.1 => 1.7.2 
   vue: ^2.6.14 => 2.6.14 
   vue-router: ^3.2.0 => 3.5.2 
   vue-template-compiler: ^2.6.11 => 2.6.14 
   vuex: ^3.4.0 => 3.6.2 
 npmGlobalPackages:
   @vue/cli: 4.5.13
   ember-cli: 3.26.1
   ember-rdfa-semapps: 0.0.0
   npm-check-updates: 11.6.0
   npm: 7.19.1


Hi @scenaristeur ,

We are looking into this, we'll get back to you with our findings soon.

Cheers,
Nick.-