hasAnybodySeenHarry / notifier

The notification service within the debt-tracker platform. The service builds notification streams while consuming messages from the specified topics. Currently, it utilizes a NoSQL database for the underlying persistence.
0 stars 0 forks source link

[BUG] Notifications aren't getting streamed to an active user. #1

Open hasAnybodySeenHarry opened 2 months ago

hasAnybodySeenHarry commented 2 months ago

Describe the bug Even when a user has an active socket session, the notifications are not being delivered.

To Reproduce Steps to reproduce the behavior:

  1. Start the Debt Tracker React client.
  2. Follow instructions at the cluster repository to spin up the services.
  3. Subscribe to the notifications.
  4. Create a new debt/transaction.

Expected behavior The user should receive the notification correctly. However, right now, it seems this is not always the case.

Screenshots N/A

Desktop (please complete the following information):

Additional context At the beginning of the cluster, users receive notifications correctly but as time passes, when more users connect, notifications start to lose.

hasAnybodySeenHarry commented 2 months ago

This is due to a serious design bug in the notification service. Lack of coordination between instances is causing the notifications not getting delivered even when users are connected in some other instances. We're collecting more information on this and the issue will be fixed in the next rollout.

hasAnybodySeenHarry commented 2 months ago

The latest release added coordination between instances and so this issue should have been resolved. However, at this moment, we haven't handled multi-device situations yet. Therefore, concurrent connections will still produce weird and broken streams. I will leave this issue opened until the service has enforced a single connection per client.

hasAnybodySeenHarry commented 2 months ago

We've added the single-device enforcement to restrict users from connecting from multiple devices while having an active client session. Therefore, this issue is assumed to be fixed at this moment and will be closed in a few days unless further reports are gathered.