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

Pusher PingPong is making clients go offline too often #56180

Closed
tgolen opened this issue Jan 31, 2025 · 17 comments
Closed

Pusher PingPong is making clients go offline too often #56180

tgolen opened this issue Jan 31, 2025 · 17 comments
Assignees
Labels
Engineering Internal Requires API changes or must be handled by Expensify staff Weekly KSv2

Comments

@tgolen
Copy link
Contributor

tgolen commented Jan 31, 2025

Problem

Once the pusher pingpong was implemented in #55326, it's resulted in more clients being forced offline than I had expected. This prevents users from using the app.

Image

Solution

Turn off the portion of the ping-pong that forces clients to go offline when the PONG event is not received and analyze the logs to see what behavior is happening with the ping-pong so it can be dialed in better.

@tgolen tgolen added Daily KSv2 DeployBlockerCash This issue or pull request should block deployment Internal Requires API changes or must be handled by Expensify staff labels Jan 31, 2025
@tgolen tgolen self-assigned this Jan 31, 2025
Copy link

melvin-bot bot commented Jan 31, 2025

Triggered auto assignment to @yuwenmemon (DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.

Copy link

melvin-bot bot commented Jan 31, 2025

💬 A slack conversation has been started in #expensify-open-source

@github-actions github-actions bot added Engineering Hourly KSv2 and removed Daily KSv2 labels Jan 31, 2025
Copy link
Contributor

👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:

  1. Identify the pull request that introduced this issue and revert it.
  2. Find someone who can quickly fix the issue.
  3. Fix the issue yourself.

@tgolen tgolen added the Reviewing Has a PR in review label Jan 31, 2025
@melvin-bot melvin-bot bot added Weekly KSv2 and removed Hourly KSv2 labels Jan 31, 2025
@tgolen tgolen removed the DeployBlockerCash This issue or pull request should block deployment label Jan 31, 2025
@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Weekly KSv2 labels Feb 3, 2025
@melvin-bot melvin-bot bot changed the title Pusher PingPong is making clients go offline too often [Due for payment 2025-02-10] Pusher PingPong is making clients go offline too often Feb 3, 2025
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Feb 3, 2025
Copy link

melvin-bot bot commented Feb 3, 2025

Reviewing label has been removed, please complete the "BugZero Checklist".

Copy link

melvin-bot bot commented Feb 3, 2025

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.93-3 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:

If no regressions arise, payment will be issued on 2025-02-10. 🎊

@melvin-bot melvin-bot bot added Weekly KSv2 and removed Weekly KSv2 labels Feb 6, 2025
@melvin-bot melvin-bot bot changed the title [Due for payment 2025-02-10] Pusher PingPong is making clients go offline too often [Due for payment 2025-02-13] [Due for payment 2025-02-10] Pusher PingPong is making clients go offline too often Feb 6, 2025
Copy link

melvin-bot bot commented Feb 6, 2025

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.94-25 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:

If no regressions arise, payment will be issued on 2025-02-13. 🎊

@melvin-bot melvin-bot bot removed the Weekly KSv2 label Feb 10, 2025
@melvin-bot melvin-bot bot added the Daily KSv2 label Feb 10, 2025
@tgolen
Copy link
Contributor Author

tgolen commented Feb 11, 2025

Daily Update

  • This is deployed, and I'm still seeing a much higher rate of PONGs not being received

Next Steps

  • I need to explore the grafana data and logs to see if I can spot any specific issues
  • I maybe need to add some more logging

ETA

  • Friday, Feb. 14

@tgolen
Copy link
Contributor Author

tgolen commented Feb 12, 2025

Daily Update

  • I didn't get a chance yesterday to look into this yet

Next Steps

  • See if I can get to it today after chores are done.

@tgolen
Copy link
Contributor Author

tgolen commented Feb 12, 2025

Daily Update

  • I discovered from the logs, that once a PONG is missed, it continues to log the same PONG being missed over and over
  • This is most likely due to the client being offline (which is normal)
  • This makes log analysis difficult because there is no way to see when the client FIRST missed a PONG
  • I have created a new App PR which will make the logs more useful for tracking the first missed PONG

Next Steps

  • @blimpich review and merge the PR
  • @tgolen Wait for deploy, then continue checking the logs and analyzing

ETA

  • Friday, Feb. 14

Copy link

melvin-bot bot commented Feb 13, 2025

Skipping the payment summary for this issue since all the assignees are employees or vendors. If this is incorrect, please manually add the payment summary SO.

@mallenexpensify
Copy link
Contributor

(long shot) any chance this bug in #quality is related? Asking cuz I searched script-src from the error then ended up here.

@tgolen
Copy link
Contributor Author

tgolen commented Feb 19, 2025

It shouldn't be, no. I still haven't re-enabled the code where Pusher PINGPONG actually puts clients offline. I'm still just logging it and trying to see what the behavior of the PINGPONG is.

@tgolen
Copy link
Contributor Author

tgolen commented Feb 21, 2025

Weekly Update

  • After the recent changes, the logs look MUCH better and now the rate of missing PONGs is nearly identical to the rate of general Pusher connection errors

Next Step

  • @tgolen create a PR for E/App that will make the client go offline when a PONG is missed, and come back online when a PONG is received

ETA

  • PR created today, Feb. 21

@melvin-bot melvin-bot bot added Weekly KSv2 and removed Weekly KSv2 labels Feb 21, 2025
@melvin-bot melvin-bot bot added Weekly KSv2 and removed Weekly KSv2 labels Mar 3, 2025
@melvin-bot melvin-bot bot changed the title [Due for payment 2025-02-13] [Due for payment 2025-02-10] Pusher PingPong is making clients go offline too often [Due for payment 2025-03-10] [Due for payment 2025-02-13] [Due for payment 2025-02-10] Pusher PingPong is making clients go offline too often Mar 3, 2025
Copy link

melvin-bot bot commented Mar 3, 2025

Reviewing label has been removed, please complete the "BugZero Checklist".

@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Mar 3, 2025
Copy link

melvin-bot bot commented Mar 3, 2025

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.7-2 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:

If no regressions arise, payment will be issued on 2025-03-10. 🎊

@tgolen tgolen changed the title [Due for payment 2025-03-10] [Due for payment 2025-02-13] [Due for payment 2025-02-10] Pusher PingPong is making clients go offline too often Pusher PingPong is making clients go offline too often Mar 7, 2025
@tgolen tgolen removed the Awaiting Payment Auto-added when associated PR is deployed to production label Mar 7, 2025
@tgolen
Copy link
Contributor Author

tgolen commented Mar 7, 2025

This issue can be closed for now. I have reverted the code which makes the client go offline too often. We're only logging it for now and I need to contact Pusher to discuss about the low delivery rates we're having with our PINGPONG. I'll open another issue for that.

@tgolen tgolen closed this as completed Mar 7, 2025
@tgolen
Copy link
Contributor Author

tgolen commented Mar 7, 2025

Opened #58024 to continue the investigation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Engineering Internal Requires API changes or must be handled by Expensify staff Weekly KSv2
Projects
None yet
Development

No branches or pull requests

3 participants