-
Notifications
You must be signed in to change notification settings - Fork 19
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
Shared workers support? #2
Comments
Preliminary conclusions
|
Hey @puzrin - thanks for making this repo, I saw your comment on the Primus Webworker ticket. I think SharedWorker support would be great for applications utilizing realtime data that can't afford downtime on the link without an expensive re-image. For example, I run a trading site that has a lot of real-time book and trade data coming down the feed (we actually have 12 live feeds at once per tab). I'm investigating using tabex to fix the multi-tab use case but of course if the master is terminated a reconnection will need to happen. During the time taken for the reconnection, we have no choice but to emit a SharedWorkers sound like the best of all worlds here but it is unfortunate that there is no support planned by Microsoft. And the use is different enough that it could be difficult to keep in sync with the traditional LS method. So it seems like more of a "nice to have" then a "need to have", but as browser support grows it would be really great to have a library like tabex keeping the use case simple and the fallbacks available. Perhaps an SW integration would involve changing tabex to explicitly support the leader election use case via something like an Thoughts? |
Just thought of an additional advantage to |
#5 if heartbit sucks, it worth to improve heartbit logic first. All browsers with Since we had no special requirements for delivery guarantees, we postponed SW implementation to volunteers. In our case LS router is more simple to use. All tickets in this repo are for records - if someone wish to extend. |
Thanks for the reply. I think this will be a good reason for Primus to move heartbeating to the server as the timer delay problem is only getting worse with time. Nice implementation re: WW timers. This may be a good candidate for a separate module or as part of tick-tock so we can delay the damage for a while. Would you be okay with me using your code and refactoring the timers to another module for use in other projects? |
No problem. Use it as you wish. |
This is technically interesting thing, but probably not so useful on practice
pros
cons
problems to solve
If we emulate legacy master events, tab (LS) clients can conflict with SW client.
additional file).
If you need SharedWorkers support - post your use case in this ticket, with explanation, why that's really needed.
The text was updated successfully, but these errors were encountered: