Commit Graph

4544 Commits

Author SHA1 Message Date
411f154827 Reduce log spam 2019-02-26 11:12:05 -08:00
6dcb97af9e Move PohService and PohRecorder out of banking_stage and into fullnode (#2852)
* Move PohService out of banking_stage and into fullnode.

* 10 second slots
2019-02-26 10:48:18 -08:00
9420ba52e9 Squash the new working bank to ensure zero-balance accounts get purged 2019-02-26 10:09:31 -08:00
ec35c1fc79 Fix leader scheduling in replay stage 2019-02-26 09:51:12 -07:00
b752511f41 Attempt to pull the completed replication work into the book 2019-02-26 09:23:12 -07:00
af206111e2 Hoist new leader scheduler up to protocol level
Attempt to feel similar to LeaderScheduler to easy migration.
2019-02-26 08:23:01 -08:00
ba50e1ac81 Move data plane fanout chapter out of proposals 2019-02-26 09:20:09 -07:00
f9f493ee7a Tighten up storage_stage changes 2019-02-26 09:05:00 -07:00
137233b4a1 Add EntryMeta wrapper 2019-02-26 09:05:00 -07:00
3897b66270 Let the bank creator decide where to send transaction fees 2019-02-26 08:06:08 -07:00
feefdca969 Minor cleanup to Bank and LastIdQueue 2019-02-26 06:46:38 -08:00
25690ff078 merge_parents() => squash() (#2943) 2019-02-25 20:34:05 -08:00
897279eddb Encapsulate log::Level so counter macro users don't need to use it 2019-02-25 20:01:30 -08:00
5f5725a4ea Re-add leader scheduler 2019-02-25 19:28:24 -08:00
6a61f25735 Only install rust-bpf if rust-bpf version changes (#2939) 2019-02-25 19:09:16 -08:00
454c66f988 fixup! 2019-02-25 18:17:36 -08:00
3e893ffddc Remove max_tick_height, leader_scheduler from broadcast_service 2019-02-25 18:17:36 -08:00
58eebd7f6c Remove tick counting from broadast service 2019-02-25 18:17:36 -08:00
ba5077701d Avoid possible simplified lowering of passed struct (#2938) 2019-02-25 17:05:59 -08:00
2f44555437 Fix fullnode test 2019-02-25 16:55:22 -08:00
299b642803 Cleanup fullnode rotate integration test, and unignore two tests 2019-02-25 16:55:22 -08:00
a2bf59cbba Ignore rust toolchain and sysroot 2019-02-25 16:40:35 -08:00
329382f016 Pull BPF enabled rustc and sysroot into SDK (#2936) 2019-02-25 15:35:45 -08:00
67c9bbc6b2 * drop parents once merged (#2930)
* add bank.id() which can be used by BankForks, blocktree_processor
* add bank.hash(), make hash_internal_state() private
* add bank.freeze()/is_frozen(), also useful for blocktree_processor, eventual freeze()ing in replay
2019-02-25 14:05:02 -08:00
6088b3bfc8 Replace DEFAULT_SLOT_HEIGHT with 0 2019-02-25 13:09:13 -08:00
2be7896157 Pull in latest rBPF that includes Rust dependent changes (#2929) 2019-02-25 12:42:48 -08:00
0b37f530ae Start replay stage from the slot-relative blob index, not the global entry height 2019-02-25 11:38:46 -08:00
c13ae10d31 Fix replay_stage to 1) skip leader slots, 2) create/set working banks properly 2019-02-25 11:38:46 -08:00
1e15e6375a Check for entry height in the unchanging bank_forks_info instead of a racy check to blocktree 2019-02-25 11:38:46 -08:00
ed684c5ec6 Build docker image with rust 1.32 2019-02-25 09:16:11 -08:00
2fbdec59cb Generalize access to staked nodes 2019-02-25 08:49:43 -08:00
710f88edda Handle edge cases earlier
We have lots of tests that work off genesis block.  Also, one
might want to generate a future leader schedule under the assumption
the stakers stay the same.
2019-02-25 08:49:43 -08:00
db899a2813 Inline LeaderSchedule::new_from_bank()
Breaks circular dependency and offers more flexibility in bank's
usage.
2019-02-25 08:49:43 -08:00
aad0d90fdd Use epoch_height to generate schedule instead of last_id
I had suggested the last_id, but that puts an unnecessary dependency
on LastIdsQueue. Using epoch height is pretty interesting in that
given the same set of stakers, you simply increment the seed once
per epoch.

Also, tighten up the LeaderSchedule code.
2019-02-25 08:49:43 -08:00
72b4834446 Add Bank::prev_slot_leader() and Bank::next_slot_leader() 2019-02-25 08:49:43 -08:00
ec48c58df1 Award tx fees to validators in new leader schedule
Also, generalize the leader_schedule functions a bit to allow for
prev_slot_leader and next_slot_leader, should they be needed.
2019-02-25 08:49:43 -08:00
0947ec59c9 Expose the new leader schedule functionality from the bank. 2019-02-25 08:49:43 -08:00
d67211305c Ignore slow benchmarks 2019-02-24 23:15:05 -07:00
c65046e1a2 Use PohRecorder as the Poh synchronization point. (#2926)
Cleanup poh_recorder and poh_service.

* ticks are sent only if poh.tick_height > WorkingBank::min_tick_height and <= WorkingBank::max_tick_height
* entries are recorded only if poh.tick_height >= WorkingBank::min_tick_height and < WorkingBank::max_tick_height
2019-02-24 08:59:49 -08:00
ba7d121724 Switch to Bank::staked_nodes(); want node_id, not staker_id
Also, update LeaderScheduler's code to use node_id as well.
Unfortuntely, no unit tests for this, because there's currently
only one way to set staker_id/node_id, and they are both set
to the same value.
2019-02-24 07:52:44 -07:00
a1070e9572 Split ActiveStakers over Bank and LeaderScheduler 2019-02-24 07:52:44 -07:00
f89e83ae49 Delete redundant code 2019-02-23 16:09:00 -08:00
264f502ed7 Query the bank for the current slot leader 2019-02-23 15:51:37 -07:00
c5876ddca9 Make LeaderScheduler::new_with_window_len private
It's useful for unit-testing, but generally isn't a variable
validators should be modifying. Blockstream and BlockstreamService
were the only ones using it. Switching them from a hard-coded 10
to the default didn't cause any test failures, so running with it.
2019-02-23 14:48:27 -07:00
fdf6cae6fb Use bank for leader scheduler's config
This ensures GenesisBlock is always configured with the same
ticks_per_slot as LeaderScheduler. This will make it easier
to migrate to bank-generated schedules.
2019-02-23 14:48:27 -07:00
d26f836212 tmp_copy_ledger -> tmp_copy_blocktree 2019-02-23 08:32:05 -07:00
da98982732 Deprecate tmp_copy_ledger
This should allow us to get rid of all the manual routing of
ticks_per_slot in the test suite.
2019-02-23 07:57:45 -07:00
cc10e84ab7 sample_ledger -> sample_blocktree 2019-02-23 07:08:11 -07:00
6cd91cd7ec Hold slots_per_epoch, not ticks_per_epoch
Same as bank and less invariants to check
2019-02-22 22:02:23 -07:00
e19dbdc527 Use Bank for ticks_per_slot 2019-02-22 22:02:23 -07:00