-
Notifications
You must be signed in to change notification settings - Fork 239
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
v2.1: Extract client code in send_transaction_service into a new structure (backport of #3423) #3480
base: v2.1
Are you sure you want to change the base?
Conversation
This is RPC only code, doesn't change anything in the validator and it's mostly moving existing code around. I want to backport it because I did some changes to the quic server that give better throughput and lower resource load if the client generates a transaction stream that doesn't have high fragmentation. The FD quic server does the same, and is even stricter in that it only allows very minimal fragmentation. This is a preparatory PR to ultimately make send-transaction-service optionally use the new quic-client-next crate to send transactions. quic-client-next doesn't create stream fragmentation. Again, RPC only, so zero risk for the validator. |
@bw-solana could you have a look? |
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.
This service is quite internal thing (can be used only together with RPC), so I generally doubt anyone uses it. |
😱 New commits were pushed while the automerge label was present. |
@bw-solana @alessandrod can we not just separate the crate and bump the major version? If this is making a breaking change with >2000 downloads a day, we cannot possibly alert everyone using it ahead of time. |
We've discussed this - haven't come to consensus yet. @willhickey captured things well here: #3724 |
i don't understand why the interfaces were changed in the same PR as breaks the types out to their own module. way too noisy even for master |
Changes in public API that I found:
What has been moved:
Would it help if I create a separate commit that would extract these structures from the original module? I can also revert for this backport these |
Because nobody ever cared about APIs so far, and we don't have a CI hook that breaks CI if API is inadvertently broken. I welcome the interest in being adults with APIs going forward, but you can't just manifest it, things have to change. In the meantime, we're trying to unfuck RPC so that we stop doing ethereum level throughput. This PR is one of many, we're already trying to split, but we're also trying to get everything landed at a decent speed. Keep in mind that this is a huge chore for Kirill who's agreed to fix code that nobody wants to touch, and a source of aneurysms for me as I review all his changes. |
Can this be undone without breaking anything?
Then I guess this can easily be reverted.
Moving seems fine, just re-export from where they used to be exported. Let's fix the API breakage, but also let's minimize churn please. I don't want this STS fix to take another month to land. I want to move on and go back to pretending that RPC doesn't exist. |
https://crates.io/crates/solana-rpc/reverse_dependencies there are probably 2 to 3 actual consumers of the API besides us |
> i don't understand why the interfaces were changed in the same PR as breaks the types out to their own module. way too noisy even for master
Because nobody ever cared about APIs so far, and we don't have a CI hook that breaks CI if API is inadvertently broken. I welcome the interest in being adults with APIs going forward, but you can't just manifest it, things have to change. In the meantime, we're trying to unfuck RPC so that we stop doing ethereum level throughput. This PR is one of many, we're already trying to split, but we're also trying to get everything landed at a decent speed. Keep in mind that this is a huge chore for Kirill who's agreed to fix code that nobody wants to touch, and a source of aneurysms for me as I review all his changes.
Oh I don’t care that they were both changed so much as that they were both
changed in the same pr, making the entire set difficult to review with
confidence
|
09f4795
to
e91ca42
Compare
The Firedancer team maintains a line-for-line reimplementation of the |
e91ca42
to
4dca724
Compare
/// Metrics of the send-transaction-service. | ||
#[derive(Default)] | ||
struct SendTransactionServiceStats { | ||
pub struct SendTransactionServiceStats { |
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.
This became pub here to be used in transaction_client
@t-nelson I added a commit that moves back the Stats structure and reverts some other changes ( |
Red CI is unrelated, see https://discord.com/channels/428295358100013066/560503042458517505/1315755154338877511 |
now CI breaks after update branch because |
@t-nelson please ignore CI failures, looks like 2.1 branch constantly faces some CI failures (unrelated to this PR). |
Problem
In order to be able to use new client code in the
SendTransactionService
(see #3444), I need to wrap network-related code with the new structureConnectionCacheClient
.Summary of Changes
To extract network code into a new structure, I had to move some auxiliary code into separate files.
Beside of that, changes are pretty minimal and I deliberately haven't tried to optimize existing code to keep changes minimal. It just does almost exactly the same as the old one.
This is an automatic backport of pull request #3423 done by [Mergify](https://mergify.com).