-
Notifications
You must be signed in to change notification settings - Fork 63
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
WIP: use gm tpuconnectionmanager for proxy #218
base: main
Are you sure you want to change the base?
WIP: use gm tpuconnectionmanager for proxy #218
Conversation
grooviegermanikus
commented
Sep 28, 2023
•
edited
Loading
edited
- use (copy) tpu_connection_manager and notably active_connection from pratik's implementation
- improve auto connection from lite-rpc to quic-proxy
- will be partially removed
Shutdown(Pubkey), | ||
} | ||
|
||
struct ActiveConnection { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
note: no Clone
anymore which IMO is good
}); | ||
|
||
}, | ||
Ok(BroadcastMessage::Shutdown(tpu_identity)) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wdyt? sending shutdown in line with transaction payload in same channel will remove race condition between transactions remaining in queue while connection thread is shutting down
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok i think, removes one extra channel.
@@ -0,0 +1,283 @@ | |||
#![allow(unused_imports)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can make changes to original code instead of coping it.
let broadcast_receiver = self.broadcast_sender.subscribe(); | ||
|
||
active_connection.start_listening(broadcast_receiver, max_uni_stream_connections); | ||
self.identity_to_active_connection.insert( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Connections are never removed from this map. They are always added.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
eh! don't scare me ;) - look, I guess you are wrong:
2023-09-29T15:08:05.018721Z INFO update_connections: solana_lite_rpc_quic_forward_proxy::outbound::tpu_connection_manager: identity_to_active_connection: 9
...
2023-09-29T15:08:13.737999Z INFO update_connections: solana_lite_rpc_quic_forward_proxy::outbound::tpu_connection_manager: identity_to_active_connection: 3
}); | ||
|
||
}, | ||
Ok(BroadcastMessage::Shutdown(tpu_identity)) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok i think, removes one extra channel.