solana-with-rpc-optimizations/sdk/src
Ryo Onodera cb8661bd49
Persistent tower (#10718)
* Save/restore Tower

* Avoid unwrap()

* Rebase cleanups

* Forcibly pass test

* Correct reconcilation of votes after validator resume

* d b g

* Add more tests

* fsync and fix test

* Add test

* Fix fmt

* Debug

* Fix tests...

* save

* Clarify error message and code cleaning around it

* Move most of code out of tower save hot codepath

* Proper comment for the lack of fsync on tower

* Clean up

* Clean up

* Simpler type alias

* Manage tower-restored ancestor slots without banks

* Add comment

* Extract long code blocks...

* Add comment

* Simplify returned tuple...

* Tweak too aggresive log

* Fix typo...

* Add test

* Update comment

* Improve test to require non-empty stray restored slots

* Measure tower save and dump all tower contents

* Log adjust and add threshold related assertions

* cleanup adjust

* Properly lower stray restored slots priority...

* Rust fmt

* Fix test....

* Clarify comments a bit and add TowerError::TooNew

* Further clean-up arround TowerError

* Truly create ancestors by excluding last vote slot

* Add comment for stray_restored_slots

* Add comment for stray_restored_slots

* Use BTreeSet

* Consider root_slot into post-replay adjustment

* Tweak logging

* Add test for stray_restored_ancestors

* Reorder some code

* Better names for unit tests

* Add frozen_abi to SavedTower

* Fold long lines

* Tweak stray ancestors and too old slot history

* Re-adjust error conditon of too old slot history

* Test normal ancestors is checked before stray ones

* Fix conflict, update tests, adjust behavior a bit

* Fix test

* Address review comments

* Last touch!

* Immediately after creating cleaning pr

* Revert stray slots

* Revert comment...

* Report error as metrics

* Revert not to panic! and ignore unfixable test...

* Normalize lockouts.root_slot more strictly

* Add comments for panic! and more assertions

* Proper initialize root without vote account

* Clarify code and comments based on review feedback

* Fix rebase

* Further simplify based on assured tower root

* Reorder code for more readability

Co-authored-by: Michael Vines <mvines@gmail.com>
2020-09-19 14:03:54 +09:00
..
nonce Clippy cleanup for all targets and nighly rust (also support 1.44.0) (#10445) 2020-06-09 09:38:14 +09:00
sysvar 9951 clippy errors in the test suite (#10030) 2020-05-15 09:35:43 -07:00
abi_digester.rs Fix cbindgen compatibility (#11455) 2020-08-07 15:13:48 -07:00
abi_example.rs Switch programs activation to whole-set based gating (#11750) 2020-08-26 01:49:15 +09:00
account.rs Introduce automatic ABI maintenance mechanism (2/2; rollout) (#8012) 2020-07-06 20:22:23 +09:00
account_info.rs Move types to more appropriate files (#10638) 2020-06-17 10:39:14 -07:00
account_utils.rs Cleanup SDK use syntax (#8004) 2020-01-28 16:11:22 -08:00
bpf_loader.rs Add support for deprecated loader (#11946) 2020-08-31 14:06:58 -07:00
bpf_loader_deprecated.rs Add support for deprecated loader (#11946) 2020-08-31 14:06:58 -07:00
builtins.rs Make BPF Loader static (#11516) 2020-08-14 12:32:45 -07:00
client.rs Rename Client methods to match proposed BanksClient (#10793) 2020-06-25 03:35:38 +00:00
clock.rs Switch programs activation to whole-set based gating (#11750) 2020-08-26 01:49:15 +09:00
commitment_config.rs Update commitment options (#12173) 2020-09-11 11:19:06 -07:00
decode_error.rs Move types to more appropriate files (#10638) 2020-06-17 10:39:14 -07:00
entrypoint.rs Add support for deprecated loader (#11946) 2020-08-31 14:06:58 -07:00
entrypoint_deprecated.rs Add support for deprecated loader (#11946) 2020-08-31 14:06:58 -07:00
entrypoint_native.rs Cache re-usable work performed by the loader (#12135) 2020-09-14 17:42:37 -07:00
epoch_info.rs getEpochInfo RPC endpoint now includes the current block height 2020-07-21 17:24:07 -07:00
epoch_schedule.rs Introduce automatic ABI maintenance mechanism (2/2; rollout) (#8012) 2020-07-06 20:22:23 +09:00
fee_calculator.rs Add keccak-secp256k1 instruction (#11839) 2020-09-15 18:23:21 -07:00
genesis_config.rs Check bank capitalization (#11927) 2020-09-12 01:48:06 +09:00
hard_forks.rs Introduce automatic ABI maintenance mechanism (2/2; rollout) (#8012) 2020-07-06 20:22:23 +09:00
hash.rs Switch account hashing to blake3 (#11969) 2020-09-02 00:37:36 -07:00
incinerator.rs Add incinerator sysvar (#9815) 2020-04-30 22:04:08 -07:00
inflation.rs Clarify comments and names in inflation code (#11977) 2020-09-03 14:15:12 +09:00
instruction.rs The constraints on compute power a program can consume is limited only to its instruction count (#11717) 2020-08-21 15:31:19 -07:00
lib.rs Add Pack and COption to sdk (#12294) 2020-09-17 21:10:02 -06:00
loader_instruction.rs Cleanup program docs (#10283) 2020-05-29 20:29:24 -06:00
log.rs Add account accessor functions (#7966) 2020-01-24 14:34:59 -08:00
message.rs Introduce automatic ABI maintenance mechanism (2/2; rollout) (#8012) 2020-07-06 20:22:23 +09:00
native_loader.rs Remove hash field from account (#9915) 2020-05-12 23:39:46 +08:00
native_token.rs Add --warp-epoch and --force-inflation to ledger-tool cap. (#11107) 2020-07-20 19:09:38 +09:00
packet.rs Introduce automatic ABI maintenance mechanism (2/2; rollout) (#8012) 2020-07-06 20:22:23 +09:00
poh_config.rs Introduce automatic ABI maintenance mechanism (2/2; rollout) (#8012) 2020-07-06 20:22:23 +09:00
program.rs Unified signature for create_program_address (#11460) 2020-08-10 10:24:11 -07:00
program_error.rs Force program address off the curve (#11323) 2020-08-05 16:35:54 -07:00
program_option.rs Add Pack and COption to sdk (#12294) 2020-09-17 21:10:02 -06:00
program_pack.rs Add Pack and COption to sdk (#12294) 2020-09-17 21:10:02 -06:00
program_stubs.rs fix program test stubs (#11956) 2020-08-31 21:48:16 -07:00
program_utils.rs chore(deps): bump bincode from 1.2.1 to 1.3.1 (#10867) 2020-07-09 00:08:05 +00:00
pubkey.rs sdk: Make PubKey::create_program_address available in program unit tests (#11745) 2020-08-24 19:28:36 +02:00
rent.rs Introduce automatic ABI maintenance mechanism (2/2; rollout) (#8012) 2020-07-06 20:22:23 +09:00
rpc_port.rs Add a client for BankForks (#10728) 2020-08-07 08:45:17 -06:00
sanitize.rs thiserror, docs, remove general Failure case (#9741) 2020-04-29 18:12:51 -07:00
secp256k1.rs Add keccak-secp256k1 instruction (#11839) 2020-09-15 18:23:21 -07:00
secp256k1_program.rs Add keccak-secp256k1 instruction (#11839) 2020-09-15 18:23:21 -07:00
short_vec.rs Reimplement decode_len() with ShortU16 vistor helper 2020-08-14 08:17:52 -06:00
shred_version.rs Move shred_version module to sdk/ 2020-02-24 14:46:12 -07:00
signature.rs Test that off-curve pubkeys fail signature verify 2020-07-31 14:21:03 -06:00
signers.rs 9951 clippy errors in the test suite (#10030) 2020-05-15 09:35:43 -07:00
slot_hashes.rs Fix slot_hashes documentation 2020-02-06 10:06:16 -07:00
slot_history.rs Persistent tower (#10718) 2020-09-19 14:03:54 +09:00
stake_history.rs Introduce automatic ABI maintenance mechanism (2/2; rollout) (#8012) 2020-07-06 20:22:23 +09:00
system_instruction.rs Add StakeInstruction::AuthorizeWithSeed (#11700) 2020-08-21 18:28:01 +00:00
system_program.rs Make default programs static (#9717) 2020-04-27 21:05:12 -07:00
system_transaction.rs Remove fee-payer guesswork from Message and Transaction (#10776) 2020-06-24 14:52:38 -06:00
timing.rs Update to rust 1.44.0 (#10585) 2020-06-17 01:32:16 +09:00
transaction.rs Add keccak-secp256k1 instruction (#11839) 2020-09-15 18:23:21 -07:00
transport.rs CLI: Error message cleanup (#8804) 2020-03-12 23:20:49 -07:00