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

Fix leftover entries after distributed tracker update #176

Merged

Conversation

jonatanklosko
Copy link
Contributor

Closes #175.

@@ -89,7 +89,7 @@ defmodule Phoenix.Tracker.State do
Atomically updates ETS local entry.
"""
@spec leave_join(t, pid, topic, key, meta) :: t
def leave_join(%State{delta: delta} = state, pid, topic, key, meta) do
def leave_join(state, pid, topic, key, meta) do
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When merging leave and join I kept the pattern match, so the join part operated on delta from before leave. Totally my bad, sorry!

@jonatanklosko
Copy link
Contributor Author

@arjan I believe this is it, sorry for the inconvenience and thanks again for the reproduction.

@jonatanklosko jonatanklosko changed the title Fix distributed tracker update Fix leftover entries after distributed tracker update Jun 14, 2023
@arjan
Copy link

arjan commented Jun 14, 2023

Yes looks like this fixes it, thanks!

@chrismccord chrismccord merged commit 214ef9d into phoenixframework:main Jun 14, 2023
@jonatanklosko jonatanklosko deleted the jk-distributed-update branch June 14, 2023 11:43
@chrismccord
Copy link
Member

❤️❤️❤️🐥🔥

@chrismccord
Copy link
Member

Released with 2.1.3

@arjan
Copy link

arjan commented Jun 14, 2023

Amazing, thanks a lot!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Presence list keep growing when using Presence.update
3 participants