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

Refactor the way we close sockets into the RelaySubscriptionManager #1754

Merged
merged 3 commits into from
Feb 5, 2025

Conversation

mplorentz
Copy link
Member

Issues covered

Follow up to #175

Description

This is some refactoring I did while debugging #175 that I stashed away at some point but now I'm submitting it. It basically moves our code for closing relay subscriptions from the RelayService into the RelaySubscriptionManager. The RelaySubscriptionManager has progressively taken over more of... managing the subscriptions, and this is more of that. I also added more documentation and I think the lifecycle of opening a socket, starting a subscription, closing a subscription, and closing a socket, is easier to follow now that it's all happening in one file.

How to test

Launch the app and look for relay problems. This could be rate limit errors in the console, or errors about "too many concurrent REQs", or it could look like content failing to load in the app.

@pelumy
Copy link
Contributor

pelumy commented Feb 4, 2025

👀

Copy link
Contributor

@pelumy pelumy left a comment

Choose a reason for hiding this comment

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

Thanks for updating this @mplorentz. It's clearer and easy to follow through for me. I have tested the app and don't find anything strange.

@mplorentz mplorentz enabled auto-merge February 5, 2025 11:49
@mplorentz mplorentz added this pull request to the merge queue Feb 5, 2025
Merged via the queue into main with commit c008dff Feb 5, 2025
4 checks passed
@mplorentz mplorentz deleted the refactor-socket-closing branch February 5, 2025 12:03
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.

2 participants