Skip to content

szlend/tracker_test

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TrackerTest

When Phoenix.Tracker nodes connect for the first time, and boths nodes already hold presences, their state will desync.

Steps to reproduce

Node 1

iex --sname n1 --cookie test -S mix

for n <- 1..51, do: Phoenix.Tracker.track(TrackerTest.Tracker, self(), "test", "#{inspect Node.self()}_#{n}", %{})

Node 2

iex --sname n2 --cookie test -S mix

for n <- 1..51, do: Phoenix.Tracker.track(TrackerTest.Tracker, self(), "test", "#{inspect Node.self()}_#{n}", %{})

Node.connect :"n1@your_hostname"

Both

Wait a while for Phoenix.Tracker to do it's thing

Phoenix.Tracker.list(TrackerTest.Tracker, "test") |> Enum.count

# Node 1
> 51

# Node 2
> 102

If you change N from 51 to 50, it works fine, and you get

falling back to sending entire crdt

instead of

sending delta generation 1

Anything above 50 appears to fail.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages