Commit Graph

24849 Commits

Author SHA1 Message Date
behzad nouri 0ab425b43b
splits test_shred_variant_compat into separate test-cases (#35306) 2024-02-26 17:32:47 +00:00
behzad nouri c8ee4f59ad
uses struct instead of tuple for Merkle shreds variant (#35303)
Working towards adding a new Merkle shred variant with retransmitter's
signature, the commit uses struct instead of tuple to describe Merkle shred
variant.
2024-02-26 15:58:40 +00:00
dependabot[bot] 6c6e691c80
build(deps): bump socket2 from 0.5.5 to 0.5.6 (#35318)
* build(deps): bump socket2 from 0.5.5 to 0.5.6

Bumps [socket2](https://github.com/rust-lang/socket2) from 0.5.5 to 0.5.6.
- [Release notes](https://github.com/rust-lang/socket2/releases)
- [Changelog](https://github.com/rust-lang/socket2/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/socket2/compare/v0.5.5...v0.5.6)

---
updated-dependencies:
- dependency-name: socket2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [auto-commit] Update all Cargo lock files

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2024-02-26 23:04:25 +08:00
dependabot[bot] 2fd2f34b35
build(deps): bump syn from 2.0.50 to 2.0.51 (#35317)
* build(deps): bump syn from 2.0.50 to 2.0.51

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.50 to 2.0.51.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.50...2.0.51)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [auto-commit] Update all Cargo lock files

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2024-02-26 23:03:33 +08:00
Michal Rostecki e74d5ccca3
hash: Use `finalize().into()` instead of `try_into()` for hash results (#35300)
`sha2` and `sha3` crates already moved to `generic-array` 0.14.7,
which means that we can safely convert the hash result to a sized
array just by calling `finalize().into()`, which doesn't return
any errors.
2024-02-23 19:31:32 -07:00
Andrew Fitzgerald 9f581113bd
Scheduler: Leader-Slot metrics for Scheduler (#35087) 2024-02-23 17:06:22 -08:00
Brooks 54706a885b
Adds get_with_and_then() to AccountsIndex (#35307) 2024-02-23 18:48:36 -05:00
Brooks 1e47aacd0d
Removes get_account_read_entry() (#35309) 2024-02-23 22:25:30 +00:00
Brooks 58c1b7aefb
Replaces ReadAccountMapEntry in more tests (#35308) 2024-02-23 21:20:42 +00:00
Lucas Steuernagel ec63b813f5
Move account filter test to SVM (#35304) 2024-02-23 17:44:26 -03:00
enjoyoor c02f47a6fb
fix: cleanup (#35298) 2024-02-23 19:59:52 +00:00
Greg Cusack fe571bbab3
Plumb `CommitmentConfig` through `bench-tps` client types (#35282)
* use --commitment-config <commitment-level> for setting blockhash commitment level for sending transactions with rpc-client

* clarify default

* leave get_balance_with_commitment at processed()

* rm unused variable

* refactor commitment_config flag read in

* update cli and change send_batch's get_latest_blockhash() to get_latest_blockhash_with_client_commitment() and use client's internal commitment level

* change fix some nits based on PR comments

* rm unused import
2024-02-23 11:50:41 -08:00
Andrew Fitzgerald 72734a9539
move changelog note of default central-scheduler (#35217) 2024-02-23 11:13:23 -08:00
Alexander Meißner 74758d9fbf
Refactor - Move recompilation out of program loading (#35297)
Moves recompilation specifics out of load_program().
2024-02-23 17:25:32 +01:00
Brooks 7da8d82aa1
Adds snapshot_utils::purge_all_bank_snapshots() (#35291) 2024-02-23 11:15:10 -05:00
Brooks 923cac8d7f
Replaces ReadAccountMapEntry in exhaustively_verify_refcounts() (#35243) 2024-02-23 11:13:57 -05:00
Brooks b5ffc24a38
Replaces ReadAccountMapEntry in retry_to_get_account_accessor() (#35244) 2024-02-23 11:12:24 -05:00
Tao Zhu 139b9c8c25
Add fee_details to fee calculation (#35021)
* add fee_details to fee calculation

* fix - no need to round after summing u64

* feature gate on removing unwanted rounding
2024-02-23 08:58:48 -06:00
Alexander Meißner 2891ce886b
Fix - program loading with effective slot at epoch boundary (#35283)
* Always limit effective slot to the begin of the current epoch.

* Adds comments.

* Optimizes to avoid having two entries if there is no relevant feature activation.

* Adds test_feature_activation_loaded_programs_epoch_transition().
2024-02-23 15:15:28 +01:00
Andrew Fitzgerald 367f489f63
scheduler inner metrics (#35271) 2024-02-22 15:01:08 -08:00
Lucas Steuernagel 31a73ab731
Move `test_rent_state_list_len` to SVM (#35287) 2024-02-22 18:37:09 -03:00
steviez d9802027cb
genesis: Skip inserting genesis accounts for Development clusters (#35266)
solana-genesis currently includes a list of accounts that exist in
MainnetBeta genesis. These accounts are added for all cluster types,
including Development clusters.

There is no need for these accounts to get added to dev clusters so
skip adding them for ClusterType::Development case
2024-02-22 14:42:35 -06:00
Illia Bobyr c98ff7a6da
loaded-programs: Remove unnecessary `allow(unused_mut)` (#35284)
Only the `executable` might need to be mutable.  This
`allow(unused_mut)` is probably a leftover from a previous version.
2024-02-22 12:11:00 -08:00
dependabot[bot] 3284d34e04
build(deps): bump openssl from 0.10.63 to 0.10.64 (#35251)
* build(deps): bump openssl from 0.10.63 to 0.10.64

Bumps [openssl](https://github.com/sfackler/rust-openssl) from 0.10.63 to 0.10.64.
- [Release notes](https://github.com/sfackler/rust-openssl/releases)
- [Commits](https://github.com/sfackler/rust-openssl/compare/openssl-v0.10.63...openssl-v0.10.64)

---
updated-dependencies:
- dependency-name: openssl
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [auto-commit] Update all Cargo lock files

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2024-02-22 20:12:59 +08:00
steviez bfcd4c8656
ledger-tool: Use error handling in blockstore command code (#35157)
There are lots of operations that could fail, including lots of the
Blockstore calls. The old code matched on Ok(_) or did unwrap()'s
which clutter the code and increase indentation.

This change wraps the entire command in a function that returns a
Result. The wrapper then does a single unwrap_or_else() and prints
any error message. Everywhere else is now free to use the ? operator
2024-02-22 00:19:28 -06:00
Ashwin Sekar 07955e79ad
replay: gracefully exit if tower load fails (#35269) 2024-02-21 18:51:30 -08:00
nathan haim 60ccdb3fb4
cli: program set-upgrade-authority sign-only (#35203)
* cli: program set-upgrade-authority
Add --sign-only flag

* Apply suggestions from code review

This fixes nits.
It modifies tests: it will sign offline with `newAuthority` keypair instead of fee payer. Then it reuses the signature in the next command.

Co-authored-by: Jon C <me@jonc.dev>

* cli/tests/program: fix tests

* cli/src/program: delete unsed import

* fix to pass ci cargo-clippy-nightly

---------

Co-authored-by: Jon C <me@jonc.dev>
2024-02-22 02:07:00 +01:00
Ryo Onodera 024d6ecc4f
Add --unified-scheduler-handler-threads (#35195)
* Add --unified-scheduler-handler-threads

* Adjust value name

* Warn if the flag was ignored

* Tweak message a bit
2024-02-22 09:05:17 +09:00
steviez 537c3d8e2c
Format the string literals in /validator directory (#35261)
There are lots of string literals in the /validator directory,
including many for CLI help and error messages. Any string literals
that exceed 100 characters prevent rustfmt from running properly.

This change temporarily set format_string = true in rustfmt.toml, and
then ran the linter on the validator directory. This was followed up
by manually tweaking several strings that were already well crafted
for readability (and within the 100 character limit)
2024-02-21 16:12:23 -06:00
DimAn 531793b4be
validator: ignore too old tower error (#35229)
* validator: ignore too old tower error

* Update core/src/replay_stage.rs

Co-authored-by: Ashwin Sekar <ashwin@solana.com>

* remove redundant references

---------

Co-authored-by: Ashwin Sekar <ashwin@solana.com>
2024-02-21 13:23:23 -05:00
Lucas Steuernagel a97f26e2a3
Build `transfer-hook` for downstream project (#35245)
* Build transfer hook for downstream project

* Add transfer hook example to programs list
2024-02-21 14:21:12 -03:00
Brooks db2071a225
Removes get_account_read_entry_with_lock() (#35240) 2024-02-21 11:25:38 -05:00
steviez 4905076fb6
Remove channel that sends roots to BlockstoreCleanupService (#35211)
Currently, ReplayStage sends new roots to BlockstoreCleanupService, and
BlockstoreCleanupService decides when to clean based on advancement of
the latest root. This is totally unnecessary as the latest root is
cached by the Blockstore, and this value can simply be fetched.

This change removes the channel completely, and instead just fetches
the latest root from Blockstore directly. Moreso, some logic is added
to check the latest root less frequently, based on the set purge
interval.

All in all, we went from sending > 100 slots/min across a crossbeam
channel to reading an atomic roughly 3 times/min, while also removing
the need for an additional thread that read from the channel.
2024-02-21 10:16:16 -06:00
steviez 5c04a9731c
Obtain BankForks read lock once to get ancestors and descendants (#35273)
No need to get the read lock twice; instead, hold it and get both items
2024-02-21 10:07:57 -06:00
Yihau Chen d223a43096
ci: update anchor downstream project (#35274)
* Update build downstream projects script (#35262)

* fix patch-crates.sh doesn't pass the real variables

* fix downstream project anchor doesn't be triggered correctly

---------

Co-authored-by: Lucas Steuernagel <38472950+LucasSte@users.noreply.github.com>
2024-02-21 22:30:55 +08:00
dependabot[bot] 14453eb1b0
build(deps): bump serde_json from 1.0.113 to 1.0.114 (#35250)
* build(deps): bump serde_json from 1.0.113 to 1.0.114

Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.113 to 1.0.114.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.113...v1.0.114)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [auto-commit] Update all Cargo lock files

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2024-02-21 15:46:55 +08:00
dependabot[bot] 8233964e39
build(deps): bump syn from 2.0.49 to 2.0.50 (#35249)
* build(deps): bump syn from 2.0.49 to 2.0.50

Bumps [syn](https://github.com/dtolnay/syn) from 2.0.49 to 2.0.50.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.49...2.0.50)

---
updated-dependencies:
- dependency-name: syn
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [auto-commit] Update all Cargo lock files

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2024-02-21 15:46:40 +08:00
dependabot[bot] 770da48178
build(deps): bump serde from 1.0.196 to 1.0.197 (#35248)
* build(deps): bump serde from 1.0.196 to 1.0.197

Bumps [serde](https://github.com/serde-rs/serde) from 1.0.196 to 1.0.197.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.196...v1.0.197)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [auto-commit] Update all Cargo lock files

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2024-02-21 15:45:52 +08:00
dependabot[bot] 97fa7b1995
build(deps): bump ahash from 0.8.8 to 0.8.9 (#35247)
* build(deps): bump ahash from 0.8.8 to 0.8.9

Bumps [ahash](https://github.com/tkaitchuck/ahash) from 0.8.8 to 0.8.9.
- [Release notes](https://github.com/tkaitchuck/ahash/releases)
- [Commits](https://github.com/tkaitchuck/ahash/compare/v0.8.8...v0.8.9)

---
updated-dependencies:
- dependency-name: ahash
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [auto-commit] Update all Cargo lock files

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2024-02-21 15:45:17 +08:00
steviez 86b5f3cde7
Revert "Update build downstream projects script (#35262)" (#35272)
This reverts commit 4022434576.
2024-02-20 23:33:04 -06:00
Andrew Fitzgerald cd4cf814fc
Scheduler: Separate scheduler metrics module (#35216) 2024-02-20 19:39:00 -08:00
Brooks 6d15487183
rpc: Parse largest token accounts after sorting & truncating (#35264) 2024-02-20 19:29:14 -05:00
Ashwin Sekar b0134ab04d
validator: include waited_for_supermajority in startup metric (#35137) 2024-02-20 16:13:57 -08:00
Brooks f122e99c4e
rpc: Faster sorting for get_token_largest_accounts() (#35263) 2024-02-20 17:55:45 -05:00
HaoranYi 141048ee74
update comments for is_builtin (#35258)
Co-authored-by: HaoranYi <haoran.yi@solana.com>
2024-02-20 16:45:38 -06:00
Lucas Steuernagel 4022434576
Update build downstream projects script (#35262) 2024-02-20 18:21:16 -03:00
Dmitri Makarov 0acee67891
SVM: move transaction_results from accounts-db to SVM (#35183)
SVM: Remove accounts-db deps in accounts_loader tests
2024-02-20 12:54:56 -08:00
steviez a1c39a3c22
List the default value for `--accounts` in CLI help (#35254) 2024-02-20 13:12:41 -06:00
Brooks d88b7d95b1
Replaces ReadAccountMapEntry in slots_by_pubkey() (#35241) 2024-02-20 13:53:02 -05:00
Brooks 915faaba1c
Replaces ReadAccountMapEntry in snapshot minimizer (#35237) 2024-02-20 13:52:29 -05:00