Commit Graph

18112 Commits

Author SHA1 Message Date
ec1d06240c Add ability to interact with a Bigtable with a custom instance id (backport #23779) (#24325)
* Refactor validator bigtable config

(cherry picked from commit 63ee00e647)

* bigtable: add a config ctor for `LedgerStorage`

(cherry picked from commit f513195468)

* bigtable: allow custom instance names

(cherry picked from commit 9b32b72990)

# Conflicts:
#	validator/Cargo.toml

* Add ability to query bigtable via solana-test-validator, with hidden params

(cherry picked from commit 9c60991cd3)

* Fix conflicts

Co-authored-by: Tyera Eulberg <tyera@solana.com>
Co-authored-by: Trent Nelson <trent@solana.com>
2022-04-13 19:00:47 -06:00
32dea4427b Bump bpf-tools to v1.25 (#24290)
- Tweak linker script
  Ensure that all read only sections end up in one segment, and
  everything else in other segments. Discard .eh_frame, .hash and
  .gnu.hash since they are unused.
- Don't create invalid string slices in stdout/stderr on Solana
- Report exceeded stack size as a warning if dynamic frames are off
- Native support for signed division in SBF
  Adds BPF_SDIV, which is enabled only for the SBF subtarget.
- Introduce dynamic stack frames and the SBFv2 flag
  Dynamic stack frames  are currently opt-in and enabled setting
  cpu=sbfv2. When sbfv2 is used, ELF files are flagged with
  e_flags=EF_SBF_V2 so the runtime can detect it and react
  accordingly.

(cherry picked from commit 6b611e1c52)

Co-authored-by: Dmitri Makarov <dmakarov@alumni.stanford.edu>
2022-04-13 20:26:13 +00:00
9aa95870fa Make tpu_use_quic a flag only without argument (#24018) (#24027)
(cherry picked from commit 98525ddea9)

Co-authored-by: Lijun Wang <83639177+lijunwangs@users.noreply.github.com>
2022-04-13 13:00:49 -06:00
d48e9b3a7b Bump sbf-tools version to v1.24
(cherry picked from commit 689064a4f4)
2022-04-13 09:15:12 -07:00
95a279f310 Double the chunk size for sending the program binary data in tx
(cherry picked from commit 03ed334ebb)

# Conflicts:
#	programs/bpf/tests/programs.rs
2022-04-13 09:15:12 -07:00
1700820583 Add TpuClient support to bench-tps (backport #24227) (#24284)
* Add TpuClient support to bench-tps (#24227)

* Add fallible send methods, and rpc_client helper

* Add helper to return RpcClient url

* Implement BenchTpsClient for TpuClient

* Add cli rpc and identity handling

* Handle different kinds of clients in main, use TpuClient

* Add tpu_client integration test

(cherry picked from commit 8487030ea6)

# Conflicts:
#	bench-tps/Cargo.toml

* Fix conflicts

Co-authored-by: Tyera Eulberg <tyera@solana.com>
2022-04-12 13:12:33 -06:00
0745738eb1 Add resolver = 2 to fix Windows build error on Travis CI (#24196) (#24259)
(cherry picked from commit a5e740431a)

Co-authored-by: Will Hickey <will.hickey@solana.com>
2022-04-12 14:05:18 -05:00
d02bf12976 Add BenchTpsClient trait (backport #24208) (#24256)
* Add BenchTpsClient trait (#24208)

* Add BenchTpsClient

* Impl BenchTpsClient for used clients

* Use BenchTpsClient in do_bench

* Update integration test to use faucet via rpc

* Support keypairs from file that are not prefunded

* Remove old perf-utils

(cherry picked from commit 3871c85fd7)

# Conflicts:
#	bench-tps/Cargo.toml

* Fix conflicts

Co-authored-by: Tyera Eulberg <tyera@solana.com>
2022-04-12 07:45:46 +00:00
587d45769d Thin client quic (#23973) (#24266)
Change thin-client to use connection-cache

(cherry picked from commit 8b72200afb)

Co-authored-by: ryleung-solana <91908731+ryleung-solana@users.noreply.github.com>
2022-04-11 23:54:39 -06:00
f495024591 Move helpers to solana-cli-config (#24246) (#24250)
* Add solana-cli-utils crate

* Use cli-utils in cli

* Move println fn to cli-output

* Use cli-config instead

(cherry picked from commit 8a73badf3d)

Co-authored-by: Tyera Eulberg <tyera@solana.com>
2022-04-11 22:17:01 -06:00
28a681a7bf Remove duplicate increment (#24219) (#24226)
(cherry picked from commit ff3b6d2b8b)

Co-authored-by: carllin <carl@solana.com>
2022-04-11 17:19:48 -04:00
15acdcc19a Bump version to v1.10.9 (#24253) 2022-04-11 13:30:11 -06:00
623ac6567b AcctIdx: fix infinite loop (#23806) (#23816)
(cherry picked from commit 965ab9186d)

Co-authored-by: Jeff Washington (jwash) <wash678@gmail.com>
v1.10.8
2022-04-11 09:54:11 -05:00
a628034eb5 Bump version to v1.10.8 2022-04-09 00:06:32 -06:00
8bce2dd446 Address review comments
(cherry picked from commit a058f348a2)
v1.10.7
2022-04-08 19:22:35 -05:00
60020632c1 Unittest for cost tracker after process_and_record_transactions
(cherry picked from commit 2ed29771f2)
2022-04-08 19:22:35 -05:00
864253a85b Adjustments to cost_tracker updates
- don't store pending tx signatures and costs in CostTracker
- apply tx costs to global state immediately again
- go from commit_or_cancel to update_or_remove, where the cost tracker
  is either updated with the true costs for successful tx, or the costs
  of a retryable tx is removed
- move the function into qos_service and hold the cost tracker lock for
  the whole loop

(cherry picked from commit 924b8ea1eb)
2022-04-08 19:22:35 -05:00
637ac7933b - Only commit successfully executed transactions' cost to cost_tracker;
- In-fly transactions are pended in cost_tracker until being committed
  or cancelled;

(cherry picked from commit 9e07272af8)
2022-04-08 19:22:35 -05:00
5a29e95f71 v1.10: Bump tonic, tonic-build, prost, and etcd-client (#24157)
* Bump tonic, prost, and etcd-client

* Restore doc ignores
2022-04-08 10:21:53 -06:00
ba72f347e4 Move duplicate-block proposal (#24167) (#24181)
(cherry picked from commit fbe5e51a16)

Co-authored-by: Tyera Eulberg <tyera@solana.com>
2022-04-07 23:57:44 +00:00
720ad85632 providing clarity on airdrop amount constraints (#24115) (#24178)
* providing clarity on airdrop amount constraints

This change is in response to a review of a PR in the `solana-program-library` found here: https://github.com/solana-labs/solana-program-library/pull/3062

* replaced static limits with info on how to find them

* removed trailing whitespace

(cherry picked from commit 781094edb2)

Co-authored-by: T.J. Kyner <78994885+tjkyner@users.noreply.github.com>
2022-04-07 23:02:18 +00:00
e5623d288e removes legacy weighted_shuffle and weighted_best methods (#24125) (#24139)
Older weighted_shuffle is based on a heuristic which results in biased
samples as shown in:
https://github.com/solana-labs/solana/pull/18343
and can be replaced with WeightedShuffle.

Also, as described in:
https://github.com/solana-labs/solana/pull/13919
weighted_best can be replaced with rand::distributions::WeightedIndex,
or WeightdShuffle::first.

(cherry picked from commit db23295e1c)

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2022-04-07 00:52:40 +00:00
ad530d73ce Bump lru crate (#24151) 2022-04-06 16:45:27 -06:00
36122a27af reduces gossip crds stats (#24132) (#24144)
(cherry picked from commit cd09390367)

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2022-04-06 17:24:16 +00:00
a6ded6a5ed removes turbine legacy code and already activated features (backport #24080) (#24117) 2022-04-06 01:12:18 +00:00
c5541efdc2 Set drop callback on first root bank (#23999) (#24129)
(cherry picked from commit 4ea59d8cb4)

Co-authored-by: carllin <carl@solana.com>
2022-04-05 20:32:17 +00:00
3f3e1b30d6 removes outdated and flaky test_skip_repair from retransmit-stage (#24121) (#24126)
test_skip_repair in retransmit-stage is no longer relevant because
following: https://github.com/solana-labs/solana/pull/19233
repair packets are filtered out earlier in window-service and so
retransmit stage does not know if a shred is repaired or not.
Also, following turbine peer shuffle changes:
https://github.com/solana-labs/solana/pull/24080
the test has become flaky since it does not take into account how peers
are shuffled for each shred.

(cherry picked from commit 2282571493)

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2022-04-05 19:08:18 +00:00
5365b939bf Implement get_account_with_config (#23997). (#24095) (#24113)
(cherry picked from commit 41f2fd7fca)

Co-authored-by: hana <81144685+2501babe@users.noreply.github.com>
2022-04-05 00:47:44 +00:00
1b6de0f08d Bump version to v1.10.7 (#24105) 2022-04-04 11:20:53 -05:00
8d5c7b7d89 hides implementation details of vote-accounts from public interface (#24087) (#24102)
(cherry picked from commit ef3e3dce7a)

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
v1.10.6
2022-04-04 15:08:21 +00:00
ca1a282a60 demotes WeightedShuffle failures to error metrics (#24079) (#24088)
Since call-sites are calling unwrap anyways, panicking seems too punitive
for our use cases.

(cherry picked from commit 7cb3b6cbe2)

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2022-04-03 18:10:00 +00:00
3f661f25fb improves Stakes::activate_epoch performance (#24068) (#24081)
Tested with mainnet stakes obtained from the ledger at 5 recent epoch
boundaries, this code is ~30% faster than current master.

Current code:
  epoch: 289, elapsed: 82901us
  epoch: 290, elapsed: 80525us
  epoch: 291, elapsed: 79122us
  epoch: 292, elapsed: 79961us
  epoch: 293, elapsed: 78965us

This commit:
  epoch: 289, elapsed: 61710us
  epoch: 290, elapsed: 55721us
  epoch: 291, elapsed: 55886us
  epoch: 292, elapsed: 55399us
  epoch: 293, elapsed: 56803us

(cherry picked from commit fa7eb7f30c)

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2022-04-03 13:44:19 +00:00
b157a9111f Note this is a modified backport that does not SAVE the new fields, but does load them. (#24074)
Original:
Start saving/loading prior_roots(_with_hash) to snapshot (#23844)

    * Start saving/loading prior_roots(_with_hash) to snapshot

    * Update runtime/src/accounts_index.rs

    Co-authored-by: Michael Vines <mvines@gmail.com>

    * Update runtime/src/accounts_index.rs

    Co-authored-by: Michael Vines <mvines@gmail.com>

    * update comment

    Co-authored-by: Michael Vines <mvines@gmail.com>
    (cherry picked from commit 396b49a7c1)

Co-authored-by: Jeff Washington (jwash) <wash678@gmail.com>
2022-04-02 17:22:33 +00:00
f2f20af768 Fix typo in documentation (#24076) (#24077)
(cherry picked from commit 4968e7d38c)

Co-authored-by: blake <572337+bartenbach@users.noreply.github.com>
2022-04-02 13:35:39 +00:00
a8855386c1 zk-token-sdk: handle edge cases for transfer with fee (#23804) (#23818)
* zk-token-sdk: handle edge cases for transfer with fee

* zk-token-sdk: clippy

* zk-token-sdk: clippy

* zk-token-sdk: cargo fmt

(cherry picked from commit 10eeafd3d6)

Co-authored-by: samkim-crypto <skim13@cs.stanford.edu>
2022-04-01 20:02:10 -04:00
6048b71640 Revert voting service to use UDP instead of QUIC (backport #24032) (#24052)
* Revert voting service to use UDP instead of QUIC (#24032)

(cherry picked from commit df4d92f9cf)

# Conflicts:
#	core/src/voting_service.rs

* resolve merge conflicts

Co-authored-by: Pankaj Garg <pankaj@solana.com>
2022-04-01 18:52:27 +00:00
4a4a1db836 expands lifetime of SlotStats (#23872) (#24002)
Current slot stats are removed when the slot is full or every 30 seconds
if the slot is before root:
https://github.com/solana-labs/solana/blob/493a8e234/ledger/src/blockstore.rs#L2017-L2027

In order to track if the slot is ultimately marked as dead or rooted and
emit more metrics, this commit expands lifetime of SlotStats while
bounding total size of cache using an LRU eviction policy.

(cherry picked from commit 1f9c89c1e8)

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2022-04-01 14:50:12 +00:00
c7889f8def uses first_coding_index for erasure meta obtained from coding shreds (#23974) (#24001)
Now that nodes correctly populate position field in coding shreds, and
first_coding_index in erasure meta, the old code to maintain backward
compatibility can be removed.
The commit is working towards changing erasure coding schema to 32:64.

(cherry picked from commit cda3d66b21)

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2022-04-01 14:49:39 +00:00
832f524687 Update Version CrdsData on node identity changes
(cherry picked from commit 7ef18f220a)
2022-03-28 19:57:48 -07:00
a639282c0f Bump version to 1.10.6 (#23969) 2022-03-28 10:56:01 -05:00
5eb085fcaf Implement forwarding via TpuConnection (#23817) (#23936)
(cherry picked from commit 6b85c2104c)

Co-authored-by: ryleung-solana <91908731+ryleung-solana@users.noreply.github.com>
v1.10.5
2022-03-28 16:38:44 +02:00
c66d086db1 fix: thread enforce_ulimit_nofile config down when opening blockstore (#23925) (#23958)
(cherry picked from commit f44c8f296f)

Co-authored-by: Steven Luscher <steveluscher@users.noreply.github.com>
2022-03-26 20:09:49 +00:00
0c740ebba6 Specify if archive size datapoint is for full or incremental snapshots (#23941) (#23957)
(cherry picked from commit 31b707b625)

Co-authored-by: Brooks Prumo <brooks@solana.com>
2022-03-26 19:25:39 +00:00
fd49ed1959 Bump version to 1.10.5 (#23955) 2022-03-26 11:34:12 -05:00
df9f4193af improve arg documentation v1.10.4 2022-03-25 21:37:35 -07:00
be99d1d55d cli: allow skipping fee-checks when writing program buffers (hidden) 2022-03-25 18:17:15 -06:00
22af384700 Add get_confirmed_blocks_with_data method (backport #23618) (#23940)
* add get_confirmed_blocks_with_data and get_protobuf_or_bincode_cells

(cherry picked from commit f3219fb695)

* appease clippy

(cherry picked from commit 5533e9393c)

* use &[T] instead of Vec<T> where appropriate

clippy

(cherry picked from commit fbcf6a0802)

* modify get_protobuf_or_bincode_cells to accept and return an iterator

(cherry picked from commit f717fda9a3)

* make get_protobuf_or_bincode_cells accept IntoIter on row_keys, make get_confirmed_blocks_with_data return an Iterator

(cherry picked from commit d8be0d9430)

Co-authored-by: Edgar Xi <edgarxi97@gmail.com>
2022-03-25 22:45:01 +00:00
30059510cc Add solana-faucet to the list of dependencies referenced by downstream projects (#23935) (#23938)
(cherry picked from commit c6dda3b324)

Co-authored-by: Will Hickey <will.hickey@solana.com>
2022-03-25 13:36:29 -05:00
c0d3cd145e Optimize TpuConnection and its implementations and refactor connection-cache to not use dyn in order to enable those changes (#23877) (#23909)
Co-authored-by: ryleung-solana <91908731+ryleung-solana@users.noreply.github.com>
2022-03-25 19:09:26 +01:00
af79a86a72 ci: don't allow mergify to add automerge label to merged PRs (#23931)
(cherry picked from commit e34c52934c)

Co-authored-by: Trent Nelson <trent@solana.com>
2022-03-25 16:20:09 +00:00