-
Notifications
You must be signed in to change notification settings - Fork 96
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
History support #28
Comments
My first thought would be that this could be an optional plugin? I like how simple Poxa is. Just pull and fire it up, and it works great. But this would add some form of data persistence... the slippery slope, haha! |
@darrencauthon I think history should be short, like 5 last messages for 5 minutes. Also, mnesia is standart erlang/elixir library so its not a problem. |
I will think on a sane way of having this, but I'm not sure if it's the case for Poxa. As @darrencauthon said if this could is done, it will be built on a way that is optional. It's important to notice that It's not that it's not simply "use mnesia" because when we go distributed (and we are close to get there) this will be a problem as mnesia will not handle nicely a netsplit for example. Also other nuances that I don't even know as I never used mnesia for something that it wasn't an example code... I would be glad to discuss some way of achieving this. |
@edgurgel I think for netsplit, history can be lost, because its not sensitive data. Netsplits are rare so its not a problem. I have no experience with distributed mnesia, but it seems like a good candidate for me. |
@edgurgel Also, there is an erlang project with history functionality and decent code https://github.com/doubleyou/dps |
There are also concerns on how to give this history. This would need to be an extension to Pusher Protocol or some convention of event(s) that will happen when you subscribe. |
As I know, pusher support user events, so it can be done with custom user event "history". Second option is very arguable, but viable if first one is not easily available. What do you think? |
People asked pusher to make history. Its bad for user experience when you change page and loose message. Its cool to have "custom made" history for pusher. Any ideas?
The text was updated successfully, but these errors were encountered: