[GH-ISSUE #1496] [Feature] Refresh all active clients when new changes sync to server #7494

Closed
opened 2026-04-10 17:21:08 -05:00 by GiteaMirror · 4 comments
Owner

Originally created by @Cldfire on GitHub (Aug 9, 2023).
Original GitHub issue: https://github.com/actualbudget/actual/issues/1496

Verified feature request does not already exist?

  • I have searched and found no existing issue

💻

  • Would you like to implement this feature?

Pitch: what problem are you trying to solve?

I could have sworn closed-source Actual auto-refreshed all active clients when a change was made on one client. However, looking through the initial open-source server commit (dd541e5f70/app-sync.js), I can't find anything that would have caused that to happen. Maybe I'm misremembering 🤔 or maybe I'm confusing it with James' tweet from a while back demonstrating instant sync between browser tabs via the service worker: https://twitter.com/jlongster/status/1241040807093768194

In any case, it feels like something we should have and it also feels very simple to implement:

  • Use SSE
  • Whenever the server receives new messages and stores them in the database, send an event to each connected client telling them to sync now (except for the client that sent the new messages)
  • Each connected client calls fullSync in response to the event

Thoughts?

Originally created by @Cldfire on GitHub (Aug 9, 2023). Original GitHub issue: https://github.com/actualbudget/actual/issues/1496 ### Verified feature request does not already exist? - [X] I have searched and found no existing issue ### 💻 - [X] Would you like to implement this feature? ### Pitch: what problem are you trying to solve? I could have sworn closed-source Actual auto-refreshed all active clients when a change was made on one client. However, looking through the initial open-source server commit (https://github.com/actualbudget/actual-server/blob/dd541e5f70e9f451b017d41816a5b5c87bc06199/app-sync.js), I can't find anything that would have caused that to happen. Maybe I'm misremembering 🤔 or maybe I'm confusing it with James' tweet from a while back demonstrating instant sync between browser tabs via the service worker: https://twitter.com/jlongster/status/1241040807093768194 In any case, it feels like something we should have and it also feels very simple to implement: * Use [SSE](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events) * Whenever the server receives new messages and stores them in the database, send an event to each connected client telling them to sync now (except for the client that sent the new messages) * Each connected client calls `fullSync` in response to the event Thoughts?
GiteaMirror added the needs votesfeature labels 2026-04-10 17:21:08 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Aug 9, 2023):

Thanks for sharing your idea!

This repository uses lodash style issue management for enhancements. That means enhancement issues are automatically closed. This doesn’t mean we don’t accept feature requests, though! We will consider implementing ones that receive many upvotes, and we welcome contributions for any feature requests marked as needing votes (just post a comment first so we can help you make a successful contribution).

The enhancement backlog can be found here: https://github.com/actualbudget/actual/issues?q=label%3A%22needs+votes%22+sort%3Areactions-%2B1-desc+

Don’t forget to upvote the top comment with 👍!

<!-- gh-comment-id:1670578855 --> @github-actions[bot] commented on GitHub (Aug 9, 2023): :sparkles: Thanks for sharing your idea! :sparkles: This repository uses lodash style issue management for enhancements. That means enhancement issues are automatically closed. This doesn’t mean we don’t accept feature requests, though! We will consider implementing ones that receive many upvotes, and we welcome contributions for any feature requests marked as needing votes (just post a comment first so we can help you make a successful contribution). The enhancement backlog can be found here: https://github.com/actualbudget/actual/issues?q=label%3A%22needs+votes%22+sort%3Areactions-%2B1-desc+ Don’t forget to upvote the top comment with 👍! <!-- feature-auto-close-comment -->
Author
Owner

@Cldfire commented on GitHub (Aug 10, 2023):

Threw together a super quick example of this working with SSE tonight:

https://github.com/actualbudget/actual/assets/13814214/ff05360d-6a17-4233-955c-aac0f956da4d

It'll take a decent amount more work to actually make this mergeable, but it looks promising.

<!-- gh-comment-id:1672341411 --> @Cldfire commented on GitHub (Aug 10, 2023): Threw together a super quick example of this working with SSE tonight: https://github.com/actualbudget/actual/assets/13814214/ff05360d-6a17-4233-955c-aac0f956da4d It'll take a decent amount more work to actually make this mergeable, but it looks promising.
Author
Owner

@youngcw commented on GitHub (Oct 13, 2023):

@Cldfire can this be closed as finished?

<!-- gh-comment-id:1762055431 --> @youngcw commented on GitHub (Oct 13, 2023): @Cldfire can this be closed as finished?
Author
Owner

@Cldfire commented on GitHub (Oct 13, 2023):

No, this hasn't been implemented. The related MR above was an improvement, but it doesn't implement what this issue describes.

<!-- gh-comment-id:1762092996 --> @Cldfire commented on GitHub (Oct 13, 2023): No, this hasn't been implemented. The related MR above was an improvement, but it doesn't implement what this issue describes.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/actual#7494