1334 Commits

Author SHA1 Message Date
Tyera Eulberg
754c65c066
Refactor RPC subscriptions account handling (#9888)
* Switch subscriptions to use commitment instead of confirmations

* Add bank method to return account and last-modified slot

* Add last_modified_slot to subscription data and use to filter account subscriptions

* Update tests to non-zero last_notified_slot

* Add accounts subscriptions to test; fails at higher tx load

* Pass BankForks to RpcSubscriptions

* Use BankForks on add_account_subscription to properly initialize last_notified_slot

* Bundle subscriptions

* Check for non-equality

* Use commitment to initialize last_notified_slot; revert context.slot chage
2020-05-07 00:23:06 -06:00
dependabot-preview[bot]
e951f8d0ed
Bump libloading from 0.6.1 to 0.6.2 (#9895)
* Bump libloading from 0.6.1 to 0.6.2

Bumps [libloading](https://github.com/nagisa/rust_libloading) from 0.6.1 to 0.6.2.
- [Release notes](https://github.com/nagisa/rust_libloading/releases)
- [Commits](https://github.com/nagisa/rust_libloading/compare/0.6.1...0.6.2)

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

* [auto-commit] Update all Cargo lock files

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2020-05-06 08:19:39 -07:00
carllin
3442f36f8a
Repair alternate versions of dead slots (#9805)
Co-authored-by: Carl <carl@solana.com>
2020-05-05 14:07:21 -07:00
jon-chuang
16af67d5e1
Focus bench on squash and fix log errors (#9759)
* Focus bench on squash

Squash performance does not depend on adding a small number accounts. It mainly depends on total number of accounts that need to be hashed during freeze operation. New bank means a clone of accounts db, so we don't get previous errors in log.

* Fix fmt and add slot counter
2020-05-05 08:33:41 -07:00
Tyera Eulberg
f5b0d13f08
Rpc: add getLargestAccounts endpoint (#9869)
automerge
2020-05-04 16:46:10 -07:00
sakridge
f37f83fd12
Fuzzer test and fixes (#9853) 2020-05-02 08:07:52 -07:00
sakridge
894549f002
Put empty accounts in the accounts list on load (#9840)
Indexing into accounts array does not match account_keys otherwise.
Also enforce program accounts not at index 0
Enforce at least 1 Read-write signing fee-payer account.
2020-05-01 17:23:33 -07:00
Michael Vines
8dfe0affd4
Add incinerator sysvar (#9815) 2020-04-30 22:04:08 -07:00
Michael Vines
230df0ec0c
Upgrade to Rust 1.43.0 (#9754) 2020-04-29 18:02:05 -07:00
Stephen Akridge
eb24f3df84 Update dalek version 2020-04-28 21:02:47 -06:00
Jack May
068f12fd6f
Add Cross-program invocations (#9582) 2020-04-28 14:33:56 -07:00
sakridge
aac580686f
fix test compilation from add_static_program change (#9755) 2020-04-27 23:37:08 -07:00
Jack May
efad193180
Make default programs static (#9717) 2020-04-27 21:05:12 -07:00
anatoly yakovenko
8ef097bf6f
Input values are not sanitized after they are deserialized, making it far too easy for Leo to earn SOL (#9706)
* sanitize gossip protocol messages
* sanitize transactions
* crds protocol sanitize
2020-04-27 11:06:00 -07:00
Ryo Onodera
9918539229
Introduce type alias Ancestors (#9699)
* Introduce type alias AncestorList

* Rename AncestorList => Ancestors
2020-04-27 11:07:03 +09:00
sakridge
e907c0e650
Filter program ids to store (#9721)
automerge
2020-04-26 00:11:37 -07:00
Greg Fitzgerald
76b1c2baf0
One less alloc per transaction (#9705)
* One less alloc per transaction

* Fix benches

* Fix compiler warnings in bench build

* Fix move build

* Fix bench
2020-04-24 13:03:46 -06:00
dependabot-preview[bot]
d2cef8ed9b
Bump num_cpus from 1.12.0 to 1.13.0 (#9682)
* Bump num_cpus from 1.12.0 to 1.13.0

Bumps [num_cpus](https://github.com/seanmonstar/num_cpus) from 1.12.0 to 1.13.0.
- [Release notes](https://github.com/seanmonstar/num_cpus/releases)
- [Changelog](https://github.com/seanmonstar/num_cpus/blob/master/CHANGELOG.md)
- [Commits](https://github.com/seanmonstar/num_cpus/compare/v1.12.0...v1.13.0)

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

* [auto-commit] Update all Cargo lock files

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2020-04-23 13:08:06 -07:00
Greg Fitzgerald
a6ad660e5e
Merge stake::withdraw instructions (#9617) 2020-04-20 18:16:50 -06:00
Jack May
b1a0abc7a6
Bump libloading to v0.6.1 (#9615)
automerge
2020-04-20 16:46:06 -07:00
Jack May
d08517db8c
Nit picks (#9580) 2020-04-18 22:39:08 -07:00
Jack May
58887c591b
Add and update tests (#9566) 2020-04-18 17:04:13 -07:00
Michael Vines
47ae57610a Only build x86_64-unknown-linux-gnu on docs.rs 2020-04-16 19:06:17 -07:00
Jack May
241a05fc52
Add native loader entry points (#9486) 2020-04-15 09:41:29 -07:00
sakridge
217828a849
Reduce accounts_db prints (#9469) 2020-04-15 09:05:54 -07:00
Ryo Onodera
c77ed82caa
Use same max_age regardless of leader/not-leader (#9423)
automerge
2020-04-14 00:34:41 -07:00
dependabot-preview[bot]
a0f0e199b7 Bump libc from 0.2.68 to 0.2.69
Bumps [libc](https://github.com/rust-lang/libc) from 0.2.68 to 0.2.69.
- [Release notes](https://github.com/rust-lang/libc/releases)
- [Commits](https://github.com/rust-lang/libc/compare/0.2.68...0.2.69)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-04-13 17:30:02 -07:00
sakridge
99655206c8
Calculate account refs fix (#9447) 2020-04-11 12:52:10 -07:00
Jack May
ad0482be73
Revert "Add native loader entry points (#9275)" Breaks genesis_config abi (#9377)
This reverts commit ed86d8d1fcd29c3c5000cc1aa4fda0b681319a65.
2020-04-08 14:36:18 -07:00
carllin
4522e85ac4
Add Metrics/Dashboards tracking block production (#9342)
* Add metric tracking blocks/dropped blocks

Co-authored-by: Carl <carl@solana.com>
2020-04-08 14:35:24 -07:00
Ryo Onodera
b28ec430e4
Introduce background stale AppendVec shrink mechanism (#9219)
* Introduce background AppendVec shrink mechanism

* Support ledger tool

* Clean up

* save

* save

* Fix CI

* More clean up

* Add tests

* Clean up yet more

* Use account.hash...

* Fix typo....

* Add comment

* Rename accounts_cleanup_service
2020-04-06 17:30:23 +09:00
dependabot-preview[bot]
8cdf406dd3 Bump serde from 1.0.105 to 1.0.106
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.105 to 1.0.106.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.105...v1.0.106)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-04-04 15:13:52 -07:00
Jack May
ed86d8d1fc
Add native loader entry points (#9275) 2020-04-03 17:40:59 -07:00
Jack May
268e04cb4a
Rename CustomError to Custom (#9207) 2020-04-01 09:01:11 -07:00
Jack May
130c0b484d
Enforce an executable's rent exemption in the runtime (#9134) 2020-03-31 10:07:38 -07:00
Tyera Eulberg
50fa577af8
Use cluster confirmations in rpc and pubsub (#9138)
* Add runtime methods to simply get status and slot

* Add helper function to get slot confirmation_count from BlockCommitmentCache

* Return cluster confirmations in getSignatureStatus

* Remove use of invalid get_signature_confirmation_status

* Remove unused methods

* Update pubsub to use cluster confirmations

* Fix test_check_signature_subscribe failure

* Refactor confirmations to read commitment cache only once

* Review comments

* Use bank, root from BlockCommitmentCache

* Update docs

* Add metric for block-commitment aggregations

Co-authored-by: Justin Starry <justin@solana.com>
2020-03-30 17:53:25 -06:00
sakridge
b1771b92ec
Calculate ref counts earlier to prevent bad clean (#9147) 2020-03-29 14:42:34 -07:00
Ryo Onodera
729cc4e04f
Sanitize zero lamport accounts in append vecs (#9083) 2020-03-29 15:45:45 +09:00
Michael Vines
d7fa40087c
Bump version to 1.2.0 2020-03-28 09:44:13 -07:00
Jack May
e2491c6322
Prevent add/subtract from executable account (#9132) 2020-03-27 16:43:25 -07:00
Justin Starry
5d9298543f
Exclude all executable accounts from rent collection (#9116)
* Whitelist executable accounts for rent exemption

* nudge
2020-03-27 23:28:18 +08:00
carllin
f3d556e3f9
Refactor VoteTracker (#9084)
* Refactor VoteTracker

Co-authored-by: Carl <carl@solana.com>
2020-03-26 17:55:17 -07:00
Jack May
8d4cecdb77
Account data may not change once the executable bit is set (#9099)
automerge
2020-03-26 17:10:11 -07:00
Ryo Onodera
2623c71ed3
Use type aliases/resulting var names consistently (#9060) 2020-03-26 13:08:56 +09:00
Justin Starry
ef3af104ae
Return appropriate error for invalid program account (#9047)
automerge
2020-03-25 13:23:05 -07:00
carllin
9dc69d9843
Store and compute node/stake state in EpochStakes struct (#8958)
* Store and compute needed bank state in EpochStakes struct
2020-03-25 12:19:15 -07:00
sakridge
45348b2c83
Remove accounts unwrap (#9062)
automerge
2020-03-25 10:21:30 -07:00
Justin Starry
eed8087d87
Respect confirmations param for signature subscription notifications (#9019)
automerge
2020-03-23 17:00:34 -07:00
sakridge
c530fbd22b
Remove thread-priority crate which is not cross-platform (#9023) 2020-03-23 12:18:52 -07:00
Tyera Eulberg
1b8f9e75dd
Update getSignatureStatus: support multiple signatures, include slot in each response item (#9022)
* Rename enable-rpc-get-confirmed-block

* Rename RpcTransactionStatus -> RpcTransactionStatusMeta

* Return simplified RpcTransactionStatus; Add support for multiple transactions

* Update docs

* typo
2020-03-23 11:25:39 -06:00