prunes repair QUIC connections (#33775)
The commit implements lazy eviction for repair QUIC connections.
The cache is allowed to grow to 2 x capacity at which point at least
half of the entries with lowest stake are evicted, resulting in an
amortized O(1) performance.
(cherry picked from commit dc3c827299)
Co-authored-by: behzad nouri <behzadnouri@gmail.com>
separates out routing shreds from establishing connections (#33599)
Currently each outgoing shred will attempt to establish a connection if
one does not already exist. This is very wasteful and consumes many
tokio tasks if the remote node is down or unresponsive.
The commit decouples routing packets from establishing connections by
adding a buffering channel for each remote address. Outgoing packets are
always sent down this channel to be processed once the connection is
established. If connecting attempt fails, all packets already pushed to
the channel are dropped at once, reducing the number of attempts to make
a connection if the remote node is down or unresponsive.
(cherry picked from commit 8becb72b3e)
Co-authored-by: behzad nouri <behzadnouri@gmail.com>
docs: move rpc info to rpc docs (#33723)
docs: link fixes
docs: link fixes
docs: link fixes
(cherry picked from commit 2c6cc4dd7d)
Co-authored-by: Jacob Creech <82475023+jacobcreech@users.noreply.github.com>
separates out routing repair requests from establishing connections (#33742)
Currently each outgoing repair request will attempt to establish a
connection if one does not already exist. This is very wasteful and
consumes many tokio tasks if the remote node is down or unresponsive.
The commit decouples routing packets from establishing connections by
adding a buffering channel for each remote address. Outgoing packets are
always sent down this channel to be processed once the connection is
established. If connecting attempt fails, all packets already pushed to
the channel are dropped at once, reducing the number of attempts to make
a connection if the remote node is down or unresponsive.
(cherry picked from commit 7aa0faea96)
Co-authored-by: behzad nouri <behzadnouri@gmail.com>
SDK: update error variants in `Feature::from_account_info` (#33750)
(cherry picked from commit 6b1e9b8974)
Co-authored-by: Joe C <joe.caulfield@solana.com>
Fix non-determinism in account_hash_ignore_slot on genesis (#33692)
(cherry picked from commit 69495f4c13)
Co-authored-by: Jeff Washington (jwash) <jeff.washington@solana.com>
token-2022: Update to use program build with zk-ops enabled (#33747)
token-2022: Update to use version with zk-ops enabled
(cherry picked from commit d33758171b)
Co-authored-by: Jon Cinque <me@jonc.dev>
down samples outgoing gossip pull requests (#33719)
Push message propagation has improved in recent versions of the gossip
code and we don't rely on pull requests as much as before. Handling pull
requests is also inefficient and expensive.
The commit reduces number of outgoing pull requests by down sampling.
(cherry picked from commit c699bc9cab)
Co-authored-by: behzad nouri <behzadnouri@gmail.com>
remove redundant pubkey update record (#33722)
* remove redundant pubkey update record
* from became unused, so removed from all process_pull_response() calls
(cherry picked from commit 6efc7ec61d)
Co-authored-by: Greg Cusack <greg.cusack@solana.com>
* Update v1.17 changelog to current version
* Remove edge / beta / stable links. Leaving them is potentially confusing. Maintaining them is error prone and of limited benefit
* Update v1.17.1 notes
* Prepare CHANGELOG.md for v1.17.2 release
Change getHealth to compare optimistically confirmed slots (#33651)
The current getHealth mechanism checks a local accounts hash slot vs.
those of other nodes as specified by --known-validator. This is a
very coarse comparison given that the default for this value is 100
slots. More so, any nodes using a value larger than the default
(ie --incremental-snapshot-interval 500) will likely see getHealth
return status behind at some point.
Change the underlying mechanism of how health is computed. Instead of
using the accounts hash slots published in gossip, use the latest
optimistically confirmed slot from the cluster. Even when a node is
behind, it is able to observe cluster optimistically confirmed by slots
by viewing votes published in gossip.
Thus, the latest cluster optimistically confirmed slot can be compared
against the latest optimistically confirmed bank from replay to
determine health. This new comparison is much more granular, and not
needing to depend on individual known validators is also a plus.
(cherry picked from commit 8bd0e4cd95)
Co-authored-by: steviez <steven@solana.com>
bank: do not remove trailing 0 bytes from return data (#33639)
This is creating havoc for Solang, as the return data is borsh encoded
and therefore `u64` values like 0x100 get truncated.
(cherry picked from commit 47511999bb)
Co-authored-by: Sean Young <sean@mess.org>
validator: skip health check (#33568)
* validator: skip health check
* keep `healthy` as a boolean
(cherry picked from commit 7afb11f1e6)
Co-authored-by: DimAn <diman@diman.io>
Update hashes per tick with feature gates (#33600)
* Update hashes per tick with feature gates
(cherry picked from commit b36d051b51)
Co-authored-by: Brennan <brennan.watt@solana.com>
Fix - CPI interface `bool` masking (#33623)
Adds masking of booleans in CPI interface to disable_cpi_setting_executable_and_rent_epoch.
(cherry picked from commit 1262ff7589)
Co-authored-by: Alexander Meißner <AlexanderMeissner@gmx.net>
Fix CLI help text for `solana stake-account` (#33387)
Fix help text
(cherry picked from commit 83b49daf29)
Co-authored-by: sakridge <stephen@solana.com>
Bank: Add function to replace empty account with upgradeable program on feature activation (#32783)
* replace program account
* modify for all cases
* remove non-data swap
* address tests & conditional feedback
* get the rent involved
* mix in owner & executable
* feature-related cases
* stripped back to feature-specific case only
* added feature
* address initial feedback
* added more lamport checks
* condense tests
* using test_case
* add fail cases to tests
* more cleanup
* add verifiably built program
* update program account state
* cleaned up serializing logic
* use full word capitalization
* rename old & new to dst & src
* swap src and dst in parameters
* add warnings and errors
* rename feature to programify
* test suite description clarity
* remove strings from datapoints
* spell out source and destination
* more verbose comments in account replace functions
* move lamport calculation
* swap lamport check for state check
* move replace functions to helper module
* make replace_account methods fallible
* refactor error handling
* add test for source program state
(cherry picked from commit 25460f76e7)
Co-authored-by: Joe C <jcaulfield135@gmail.com>
ci: remove stable-perf from PR and push CI (#33479)
ci: move stable-perf to nightly pipeline
(cherry picked from commit b87c8d163d)
Co-authored-by: Yihau Chen <a122092487@gmail.com>
Deprecate bz2/gzip/none/tar snapshot compression types (#33484)
These options are now disallowed on the command line for
solana-validator and solana-ledger-tool, which effectively means no more
snapshots will be created with this types in normal usecases. However,
support for reading the deprecated types is still in place.
(cherry picked from commit 73e9e6dd70)
Co-authored-by: steviez <steven@solana.com>
* transaction-status: Remove `convert_pubkey`
Ran `git g -l convert_pubkey | xargs sed -i'' -re 's/convert_pubkey\(([^)]+)\)/\1/g'`
* Remove convert_compiled_instruction
Ran `git g -l convert_compiled_instruction | xargs sed -i'' -re 's/convert_compiled_instruction\(([^)]+)\)/\1/g'`
* Cleanup + clippy
* Remove instruction conversions in new extensions
* Run clippy --fix
* token: Update to 4.0.0
* token-2022: Bump and support new account and instruction types
* Update token-2022 in fetch_spl / program-test
* Fixup downstream uses
* Mint and destination were flipped in 0.9.0
* Don't use `convert_pubkey`
* Bump spl dependencies to versions which avoid recompilations