Commit Graph

116 Commits

Author SHA1 Message Date
Pankaj Garg 4ac1213c9c
Integrate coding shreds and recovery (#5625)
* Integrate coding shreds and recovery

* More tests for shreds and some fixes

* address review comments

* fixes to code shred generation

* unignore tests

* fixes to recovery
2019-08-26 18:27:45 -07:00
Michael Vines faafee6b42
to to/the the (#5590) 2019-08-21 17:46:59 -07:00
Pankaj Garg 4798e7fa73
Integrate data shreds (#5541)
* Insert data shreds in blocktree and database

* Integrate data shreds with rest of the code base

* address review comments, and some clippy fixes

* Fixes to some tests

* more test fixes

* ignore some local cluster tests

* ignore replicator local cluster tests
2019-08-20 17:16:06 -07:00
Michael Vines ccee6241a6
Revert "publish fixes"
This reverts commit 4d13d3871d.
2019-08-16 17:28:07 -07:00
Michael Vines 4d13d3871d
publish fixes 2019-08-16 17:03:57 -07:00
Rob Walker 94f1132fb6
fix single node testnet, remove bootstrap vote (#5534) 2019-08-15 18:58:46 -07:00
Rob Walker d22848f9b1
use live stakes for consensus (#5426)
* use live stakes for consensus

* lint

* re-enable leader_failure_4

* fixups

* re-ignore leader_failure_4
2019-08-14 13:30:21 -07:00
carllin cd14a940d8
Allow process_blocktree() to start processing from any root (#5484)
* Remove unnecessary entry_height from BankInfo

* Refactor process_blocktree to support process_blocktree_from_root

* Refactor to process blocktree after loading from snapshot

* On restart make sure bank_forks contains all the banks between the root and the tip of each fork, not just the head of each fork

* Account for 1 tick_per_slot in bank 0 so that blockhash of bank0 matches the tick
2019-08-13 17:20:14 -07:00
Rob Walker 07d11be6ab
add global stake warmup (#5483)
* add global stake warmup

* integrate stake history into runtime

* fixup core tests

* fixup

* remove existing cooldown tests for now
2019-08-12 20:59:57 -07:00
Justin Starry 0fde19239b
Rate limit counter metrics points to one per second (#5496)
* Rate limit counter metrics points to one per second

* Remove old env var

* Test that metrics counter is incrementing

* Fix typo
2019-08-12 18:15:34 -04:00
Justin Starry 4f86c0b74a
Rate limit transaction counters (#5447)
* Rate limit transaction counters

* @sakridge feedback

* Set default high metrics rate for multinode demo

* Fix tests

* Swap defaults and fix env var tests

* Only set metrics rate if not already set
2019-08-08 17:05:06 -04:00
Tyera Eulberg efd09ecd37 Revert fork metrics (#5427)
* Revert "Remove duplicate row (#5419)"

This reverts commit a81dd80d60.

* Revert "Log fork stake-percentage in metrics, and display (#5406)"

This reverts commit 92e419f1c7.
2019-08-05 15:53:36 -07:00
Tyera Eulberg 92e419f1c7
Log fork stake-percentage in metrics, and display (#5406)
* Log fork stake percentage data

* Add fork stake percentage to dashboard

* Call out parent slot
2019-08-02 19:16:23 -06:00
Michael Vines eb3991b9ba
Replay stage log message nits (#5408) 2019-08-02 10:08:42 -07:00
carllin 6cb2040a1b
Snapshot Packaging Service (#5262)
* Snapshot serialization and packaging
2019-07-31 17:58:10 -07:00
Justin Starry 84368697af
Fix metrics when leader does not report metrics (#5291) 2019-07-30 16:18:33 -04:00
Pankaj Garg aef7bae60d
Let grace ticks to roll over into multiple leader slots (#5268)
* Let grace ticks to roll over into multiple leader slots

* address review comments
2019-07-26 11:33:51 -07:00
Tyera Eulberg dab7de7496
Add confidence cache to BankForks (#5066)
* Add confidence cache to BankForks

* Include stake-weighted lockouts in cache

* Add cache test

* Move confidence cache updates to handle_votable_bank

* Prune confidence cache on prune_non_root()

* Spin thread to process aggregate_stake_lockouts

* Add long-running thread for stake_weighted_lockouts computation
2019-07-26 11:27:57 -06:00
Justin Starry 547a7a345f
Add logs to indicate when the leader changes (#5253) 2019-07-23 22:19:20 -04:00
Michael Vines 0d8f5379a0
Add time units 2019-07-22 08:22:21 -07:00
Sagar Dhawan a07b17b9b5
Drop older slots in the ledger (#5188)
* Add facility to delete blocktree columns in range

* Add ledger cleanup service

* Add local_cluster test
2019-07-20 13:13:55 -07:00
Rob Walker afa05acb32
more replay_stage grooming (#5163) 2019-07-18 14:54:27 -07:00
Sagar Dhawan a3a91ba222 Fix misleading variable name (#5176)
automerge
2019-07-18 14:07:32 -07:00
Sagar Dhawan 751b54b60b
Skip sleeping in replay stage if a bank was recently processed (#5161)
* Skip sleeping in replay stage if a bank was recently processed

* Remove return
2019-07-18 12:04:53 -07:00
Rob Walker 0ffd91df27
groom poh_recorder (#5127)
* groom poh_recorder

* fixup

* nits

* slot() from the outside means "the slot the recorder is working on"

* remove redundant check

* review comments, put next_tick back in the "is reset" check

* remove redundant check
2019-07-17 14:10:15 -07:00
sakridge 40faaef9da
Revert "Logging (#5017)" (#5096)
This reverts commit b50a3bae72.
2019-07-14 18:48:15 -07:00
Pankaj Garg 4c90898f0b
Dynamic erasure set configuration (#5018)
* Use local erasure session to create/broadcast coding blobs

* Individual session for each recovery (as the config might be different)

* address review comments

* new constructors for session and coding generator

* unit test for dynamic erasure config
2019-07-11 13:58:33 -07:00
carllin b50a3bae72
Logging (#5017)
* Add logging to replay_stage

* locktower logging
2019-07-10 15:52:31 -07:00
Rob Walker f537482c86
remove set_leader from cluster_info (#4998) 2019-07-09 22:06:47 -07:00
Rob Walker f777a1a74c
groom replay_stage and poh_recorder (#4961)
* groom replay_stage and poh_recorder

* fixup

* fixup

* don't freeze() parent, need to review bank_forks and maybe vote...
2019-07-09 15:36:30 -07:00
Rob Walker eb4edd75e6
make bank commit_credits non public (#4944)
* make bank commit_credits non pub

* track down create() failure

* move bank_client to process_transaction(), which commits credits
2019-07-08 15:37:54 -07:00
carllin 2aac094f63
Ensure blobs are deserializable without unwrapping (#4948)
* Return result from deserializing blobs in blocktree instead of assuming deserialization will succeed

* Mark bad deserialization as dead fork

* Add test for corrupted blobs in blocktree and replay_stage
2019-07-07 14:37:12 -07:00
Tyera Eulberg 66552d7047
Credit-Only Accounts: Cache account balance for thread-safe load/store (#4691)
* Implement CreditOnlyLocks

* Update credit-only atomic on account load

* Update credit-only atomic after bank.freeze_lock; store credits if all credit-only lock references are dropped

* Commit credit-only credits on bank freeze

* Update core to CreditAccountLocks

* Impl credit-only in System Transfer

* Rework CreditAccountLocks, test, and fix bugs

* Review comments: Pass CreditAccountLocks by reference; Tighten up insert block

* Only store credits on completed slot

* Check balance in bench_exchange funding to ensure commit_credits has completed

* Add is_debitable info to KeyedAccount meta to pass into programs

* Reinstate CreditOnlyLocks check on lock_account

* Rework CreditAccountLocks to remove strong_count usage

* Add multi-threaded credit-only locks test

* Improve RwLocks usage

* Review comments: panic if bad things happen; tighter code

* Assert lock_accounts race does not happen

* Revert panic if bad things happen; not a bad thing
2019-06-27 17:25:10 -04:00
carllin d6737b8cc9
Set epoch schedule in set_root in leader schedule cache (#4821) 2019-06-26 00:19:48 -07:00
anatoly yakovenko 29611fb61d
tower consensus naming (#4598)
s/locktower/tower/g
2019-06-24 13:41:23 -07:00
carllin aacb38864c
Mark dead forks in replay stage (#4715)
* Add DeadSlots column family

* Filter dead forks from get_slots_since

* Mark erroring slots as dead in replay stage, add test

* Mark dead forks in progress instead of removing them

* Fix logging process_entries failures in replay_stage

* Unignore test_fail_entry_verification_leader
2019-06-20 15:50:41 -07:00
Sagar Dhawan 8019bff391 Fixes for storage program and rework storage stage (#4654)
automerge
2019-06-11 18:27:47 -07:00
Rob Walker 3217a1d70c
use highest staked node as bootstrap leader, remove bootstrap_leader from genesis_block (#4635)
* use highest staked node as bootstrap leader, remove bootstrap_leader from genesis_block

* clippy

* fixup

* fixup
2019-06-11 11:44:58 -07:00
Rob Walker 028e111fbc
remove payer from vote instructions (#4475) 2019-05-31 11:45:17 -07:00
Sathish 182096dc1a
Create bank snapshots (#4244)
* Revert "Revert "Create bank snapshots (#3671)" (#4243)"

This reverts commit 81fa69d347.

* keep saved and unsaved copies of status cache

* fix format check

* bench for status cache serialize

* misc cleanup

* remove appendvec storage on purge

* fix accounts restore

* cleanup

* Pass snapshot path as args

* Fix clippy
2019-05-30 21:31:35 -07:00
carllin 534244b322
Fix set_roots to use cached bank parents instead of searching blocktree (#4466) 2019-05-29 09:43:22 -07:00
carllin d772a27936 Plumb ClusterInfoRepairListener (#4428)
automerge
2019-05-24 19:20:09 -07:00
Michael Vines cfe5afd34c
_id => _pubkey variable renaming (#4419)
* wallet: rename *_account_id to *_account_pubkey

* s/from_id/from_pubkey/g

* s/node_id/node_pubkey/g

* s/stake_id/stake_pubkey/g

* s/voter_id/voter_pubkey/g

* s/vote_id/vote_pubkey/g

* s/delegate_id/delegate_pubkey/g

* s/account_id/account_pubkey/g

* s/to_id/to_pubkey/g

* s/my_id/my_pubkey/g

* cargo fmt

* s/staker_id/staker_pubkey/g

* s/mining_pool_id/mining_pool_pubkey/g

* s/leader_id/leader_pubkey/g

* cargo fmt

* s/funding_id/funding_pubkey/g
2019-05-23 23:20:04 -07:00
Michael Vines 2ed77b040a
create_genesis_block() now returns a struct (#4403) 2019-05-22 20:39:00 -07:00
Rob Walker 578c2ad3ea
add bank hash to votes (#4381) 2019-05-21 21:45:38 -07:00
carllin f1e5edee14
Modify Roots Column To Support Multiple Roots (#4321)
* Fix 1) Roots column family to handle storing multiple slots, 2) Store all slots on the rooted path in the roots column family
2019-05-20 19:04:18 -07:00
Sagar Dhawan af82b0dce9 Fix sending root slots instead of current slot (#4354)
automerge
2019-05-20 15:01:55 -07:00
Rob Walker 86e03a6d1b
support issuing vote instructions from system account (#4338)
* issue vote instructions from system account

* fixup

* bring back KeypairUtil
2019-05-20 13:32:32 -07:00
Sagar Dhawan 06eb2364f2
Handle missed slots in storage stage (#4337)
* Handle missed slots in storage stage

* Fix test compile

* Make test use the new missed slot support
2019-05-18 15:24:50 -07:00
Pankaj Garg 9476fe5ce3
Use log levels for datapoint metrics (#4335)
* Use log levels for datapoint metrics

* address review comments

* fix cyclomatic complexity
2019-05-17 17:34:05 -07:00