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

Implement optimal lazy initialization strategy for RoutingSender #272

Open
nieznanysprawiciel opened this issue Jul 21, 2023 · 1 comment

Comments

@nieznanysprawiciel
Copy link
Contributor

nieznanysprawiciel commented Jul 21, 2023

Why:

  • Calling RoutingSender::send will try to re-initialize session, if it was closed. This is good idea in certain scenarios, but everything depends on the reason that session was closed.

Examples:

  • Other Node shutdown - re-initialization will fail anyway
  • Temporarily internet connection was lost - in this case we would like to continue sending packets after connection will start working again
  • Initialization with Node failed, because it was sending incorrect protocol messages - it's not clear if we want to talk with this Node (it can be either malicious or it works incorrectly)

What:

  • Consider what are possible cases of re-initialization scenarios
  • Plan the best strategy possible
  • Implement RoutingSender
  • Check if TcpSender has any similarities in terms of optimal strategy
@nieznanysprawiciel nieznanysprawiciel changed the title Implement the best possible lazy initialization strategy for RoutingSender Implement optimal lazy initialization strategy for RoutingSender Jul 21, 2023
@staszek-krotki
Copy link
Contributor

Looks like an optimization without significant value added

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

No branches or pull requests

2 participants