Skip to content

Conversation

@filipecabaco
Copy link
Member

What kind of change does this PR introduce?

unassign db_conn from socket to prevent dead connections

@vercel
Copy link

vercel bot commented May 29, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Skipped Deployment
Name Status Preview Comments Updated (UTC)
realtime-demo ⬜️ Ignored (Inspect) Visit Preview Jun 5, 2025 11:16am

@coveralls
Copy link

coveralls commented May 29, 2025

Coverage Status

coverage: 83.211% (+0.3%) from 82.932%
when pulling 3817f04 on fix/unassign-db-conn-from-socket
into 063037e on main.

@filipecabaco filipecabaco force-pushed the fix/unassign-db-conn-from-socket branch from 4c3457f to 13c3705 Compare June 2, 2025 02:32
@filipecabaco filipecabaco force-pushed the fix/unassign-db-conn-from-socket branch from 13c3705 to fecfbfe Compare June 3, 2025 10:54
@filipecabaco
Copy link
Member Author

@edgurgel added the move from handlers to RealtimeChannel so we centralize those calls.

For now we just have a "catch all" error and we can refine afterwards when we have a better understanding of what is actually the errors being caught

I also did the test by brute force change the syn state which won't trigger the Connect module exit flows

Copy link
Member

@edgurgel edgurgel left a comment

Choose a reason for hiding this comment

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

LGTM

@edgurgel
Copy link
Member

edgurgel commented Jun 4, 2025

Sorry for the conflicts! But at least it should be pretty straightforward to fix those 🙏

@filipecabaco filipecabaco force-pushed the fix/unassign-db-conn-from-socket branch from fecfbfe to d75d521 Compare June 4, 2025 22:20
for _ <- 1..100, reduce: socket do
socket ->
assert {:reply, :ok, socket} =
assert {:reply, :ok, _} =
Copy link
Member

@edgurgel edgurgel Jun 5, 2025

Choose a reason for hiding this comment

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

This is the issue! socket needed to be passed around to be reduced and kept the policies that were cached etc!

I've pushed a fix!

Copy link
Member Author

Choose a reason for hiding this comment

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

🤦‍♂️🤦‍♂️🤦‍♂️

@filipecabaco filipecabaco force-pushed the fix/unassign-db-conn-from-socket branch from 3b7dc88 to 3817f04 Compare June 5, 2025 11:16
@filipecabaco filipecabaco merged commit 42fc73d into main Jun 5, 2025
7 checks passed
@filipecabaco filipecabaco deleted the fix/unassign-db-conn-from-socket branch June 5, 2025 11:35
@kiwicopple
Copy link
Member

🎉 This PR is included in version 2.36.10 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants