Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Web can only receive one sse event #9742

Closed
kobergj opened this issue Sep 28, 2023 · 2 comments · Fixed by owncloud/ocis#7404
Closed

Web can only receive one sse event #9742

kobergj opened this issue Sep 28, 2023 · 2 comments · Fixed by owncloud/ocis#7404
Assignees
Labels
Type:Bug Something isn't working

Comments

@kobergj
Copy link
Contributor

kobergj commented Sep 28, 2023

Something seems fishy with webs sse connection. Only one event is received, then the connection is stale and needs a reconnect to get more events.

Steps to reproduce:

  • run any ocis version that has sses enabled (e.g. current master but is reproducible with all versions > 4.0)
  • make sure to have OCIS_SERVICE_ACCOUNT_ID and OCIS_SERVICE_ACCOUNT_SECRET set (or run ocis init)
  • login with marie and einstein in two seperate windows
  • as marie share a file with einstein
    -> einstein will receive a notification
  • as marie remove the share with einstein
    -> einstein will NOT receive a notification
  • as einstein reload the page
  • as marie share the file again with einstein
    -> einstein will receive two notifications (the missing file_unshared and the new file_shared)

Remark:
The web shows no additional logs and the sse connection seems to be ok (if you ask to the network tab).
Note that this could be very well be bug on server side, but I cannot reproduce the issue using curl or postman connected to the sse endpoint (they will receive all events immediately).

We need to find out why the web sse connection is different from the one opened through postman.

@JammingBen JammingBen self-assigned this Sep 28, 2023
@JammingBen JammingBen added the Type:Bug Something isn't working label Sep 28, 2023
@JammingBen
Copy link
Collaborator

I see that the structure of the data the server sends has changed (I assume via owncloud/ocis#7325). Web checks for notification_id, which is now inside data - hence it doesn't work.

Strange though that the first notification still works for you 🤔 For me it's not working at all.

@kobergj
Copy link
Contributor Author

kobergj commented Sep 29, 2023

Mmmh. Strange but ok. I'll wait for web implementation and retest again!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type:Bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants