Commit Graph

14089 Commits

Author SHA1 Message Date
steviez edc2ab3e48
Test account index and store alignment (#17038)
* Use ReclaimResult::Default() instead of building subtypes

* Add test to ensure account_db store and index are aligned
2021-05-06 14:13:44 -05:00
behzad nouri fa86a335b0
implements cursor for gossip crds table queries (#16952)
VersionedCrdsValue.insert_timestamp is used for fetching crds values
inserted since last query:
https://github.com/solana-labs/solana/blob/ec37a843a/core/src/cluster_info.rs#L1197-L1215
https://github.com/solana-labs/solana/blob/ec37a843a/core/src/cluster_info.rs#L1274-L1298

So it is crucial that insert_timestamp does not go backward in time when
new values are inserted into the table. However std::time::SystemTime is
not monotonic, or due to workload, lock contention, thread scheduling,
etc, ... new values may be inserted with a stalled timestamp way in the
past. Additionally, reading system time for the above purpose is
inefficient/unnecessary.

This commit adds an ordinal index to crds values indicating their insert
order. Additionally, it implements a new Cursor type for fetching values
inserted since last query.
2021-05-06 14:04:17 +00:00
Ryo Onodera d19526e6c2
Dump rent_collector/inflation with ledger-tool cap (#17069) 2021-05-06 19:29:46 +09:00
dependabot[bot] 2541809c45
chore: bump @babel/preset-env from 7.14.0 to 7.14.1 in /web3.js (#17078)
Bumps [@babel/preset-env](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-env) from 7.14.0 to 7.14.1.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.14.1/packages/babel-preset-env)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-06 09:46:48 +00:00
dependabot[bot] 9cd55e0d98
chore: bump @rollup/plugin-commonjs from 18.0.0 to 18.1.0 in /web3.js (#17077)
Bumps [@rollup/plugin-commonjs](https://github.com/rollup/plugins/tree/HEAD/packages/commonjs) from 18.0.0 to 18.1.0.
- [Release notes](https://github.com/rollup/plugins/releases)
- [Changelog](https://github.com/rollup/plugins/blob/master/packages/commonjs/CHANGELOG.md)
- [Commits](https://github.com/rollup/plugins/commits/commonjs-v18.1.0/packages/commonjs)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-06 09:36:35 +00:00
dependabot[bot] b8fc69a45b
chore: bump @typescript-eslint/eslint-plugin in /web3.js (#17076)
Bumps [@typescript-eslint/eslint-plugin](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin) from 4.22.0 to 4.22.1.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v4.22.1/packages/eslint-plugin)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-06 09:34:14 +00:00
dependabot[bot] 5103bc11b4
chore:(deps): bump @solana/spl-token-registry in /explorer (#17075)
Bumps [@solana/spl-token-registry](https://github.com/solana-labs/token-list) from 0.2.68 to 0.2.71.
- [Release notes](https://github.com/solana-labs/token-list/releases)
- [Changelog](https://github.com/solana-labs/token-list/blob/main/CHANGELOG.md)
- [Commits](https://github.com/solana-labs/token-list/compare/v0.2.68...v0.2.71)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-06 09:18:09 +00:00
dependabot[bot] 66d0348c72
chore:(deps): bump superstruct from 0.15.1 to 0.15.2 in /explorer (#17073)
Bumps [superstruct](https://github.com/ianstormtaylor/superstruct) from 0.15.1 to 0.15.2.
- [Release notes](https://github.com/ianstormtaylor/superstruct/releases)
- [Changelog](https://github.com/ianstormtaylor/superstruct/blob/main/Changelog.md)
- [Commits](https://github.com/ianstormtaylor/superstruct/compare/v0.15.1...v0.15.2)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-06 09:00:57 +00:00
Trent Nelson cb5e000615 CLI: Print gossip nodes with `cli-output` crate 2021-05-06 07:49:47 +00:00
dependabot[bot] d4aa7d512c
chore: bump rollup from 2.46.0 to 2.47.0 in /web3.js (#17030)
Bumps [rollup](https://github.com/rollup/rollup) from 2.46.0 to 2.47.0.
- [Release notes](https://github.com/rollup/rollup/releases)
- [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rollup/rollup/compare/v2.46.0...v2.47.0)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-06 11:41:43 +08:00
dependabot[bot] 5d655eb516
chore:(deps): bump @types/react from 17.0.4 to 17.0.5 in /explorer (#17053)
Bumps [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react) from 17.0.4 to 17.0.5.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-06 11:41:29 +08:00
Justin Starry 9c92531ea0
explorer: update package-lock.json to v2 (#17067) 2021-05-06 02:34:14 +00:00
Ashwin Sekar 12c2cd4e86
Fix net shaper script to properly query interfaces (#17065)
Previously was using ifconfig which is not available on gce
2021-05-05 19:02:38 -07:00
Michael Vines 7d1637d89a RpcClient now respects the retry-after server response header when getting rate limited 2021-05-05 18:11:57 -07:00
Brooks Prumo 9bca18603b
Add Brooks's pubkey to authorized keys (#17063) 2021-05-05 23:11:20 +00:00
Jeff Washington (jwash) ffbe8906ed
get root lock once (#16829) 2021-05-05 15:17:45 -05:00
Brooks Prumo e6f49a3e79
Clean unrooted unfrozen banks (#16580) (#17003)
Cleanup pubkeys when an unrooted, unfrozen bank is dropped.  This is a
continuation of PR #16911.
2021-05-05 15:02:02 -05:00
Michael Vines 9ba2c53b85 Add --tower argument to specify where tower files are persisted 2021-05-05 12:20:39 -07:00
Josh 769136f586
feat: associated token program card (#17043) 2021-05-05 11:49:05 -07:00
Jeff Washington (jwash) ab7c96aa81
insert accounts in parallel when building initial index (#17040)
* insert accounts in parallel when building initial index

* rename nits from pr review

* rename nits from pr review

* rename nits from pr review

* rename nits from pr review
2021-05-05 17:08:45 +00:00
Stephen Akridge 3e0fed48e7 Don't recognize temp snapshots as possible snapshots to open 2021-05-05 08:45:03 -07:00
Jeff Washington (jwash) 5786be13a4
flatten_hash_intermediate sets capacity first (#17013)
* flatten_hash_intermediate sets capacity first

* use iterator instead of for
2021-05-05 09:07:05 -05:00
dependabot[bot] a125388f6e
chore: bump @types/node from 15.0.1 to 15.0.2 in /web3.js (#17056)
Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 15.0.1 to 15.0.2.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-05 10:28:50 +00:00
dependabot[bot] 33443170de
chore: bump @typescript-eslint/parser from 4.22.0 to 4.22.1 in /web3.js (#17055)
Bumps [@typescript-eslint/parser](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/parser) from 4.22.0 to 4.22.1.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/parser/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v4.22.1/packages/parser)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-05 10:04:58 +00:00
dependabot[bot] 4b7083c38a
chore: bump @rollup/plugin-node-resolve in /web3.js (#17054)
Bumps [@rollup/plugin-node-resolve](https://github.com/rollup/plugins/tree/HEAD/packages/node-resolve) from 11.2.1 to 13.0.0.
- [Release notes](https://github.com/rollup/plugins/releases)
- [Changelog](https://github.com/rollup/plugins/blob/master/packages/node-resolve/CHANGELOG.md)
- [Commits](https://github.com/rollup/plugins/commits/commonjs-v13.0.0/packages/node-resolve)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-05 09:54:27 +00:00
Justin Starry a8f84a5622
fix: fix flow type declaration (#17049)
* fix: fix flow type declaration

* chore: fix prettier
2021-05-05 17:50:55 +08:00
dependabot[bot] 34599ad57d
chore: bump @rollup/plugin-commonjs from 18.0.0 to 18.1.0 in /web3.js (#17052)
Bumps [@rollup/plugin-commonjs](https://github.com/rollup/plugins/tree/HEAD/packages/commonjs) from 18.0.0 to 18.1.0.
- [Release notes](https://github.com/rollup/plugins/releases)
- [Changelog](https://github.com/rollup/plugins/blob/master/packages/commonjs/CHANGELOG.md)
- [Commits](https://github.com/rollup/plugins/commits/commonjs-v18.1.0/packages/commonjs)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-05 09:25:25 +00:00
dependabot[bot] e619b101c9
chore: bump @typescript-eslint/eslint-plugin in /web3.js (#17051)
Bumps [@typescript-eslint/eslint-plugin](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin) from 4.22.0 to 4.22.1.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v4.22.1/packages/eslint-plugin)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-05 09:16:49 +00:00
dependabot[bot] 7e774ee90f
chore:(deps): bump @types/node from 15.0.1 to 15.0.2 in /explorer (#17050)
Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 15.0.1 to 15.0.2.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-05 09:07:23 +00:00
dependabot[bot] 8f0b410714
chore: bump @babel/preset-env from 7.14.0 to 7.14.1 in /web3.js (#17031)
Bumps [@babel/preset-env](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-env) from 7.14.0 to 7.14.1.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.14.1/packages/babel-preset-env)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-05 14:31:19 +08:00
Sebastian.Bor 6d11d5dd9f chore: conflate use statement 2021-05-04 08:34:35 -07:00
Sebastian.Bor 4ede5117f9 fix: add bpf_loader_upgradeable to ProgramTest default builtins 2021-05-04 08:34:35 -07:00
Ruud van Asseldonk 9abfa65920
Document that Transaction::sign might panic (#17026) 2021-05-04 08:32:21 -07:00
Tyera Eulberg 46d2755205
Correct days/year (#17024) 2021-05-04 10:00:30 +00:00
dependabot[bot] f5862c03ec
chore: bump codecov from 3.8.1 to 3.8.2 in /web3.js (#17029)
Bumps [codecov](https://github.com/codecov/codecov-node) from 3.8.1 to 3.8.2.
- [Release notes](https://github.com/codecov/codecov-node/releases)
- [Changelog](https://github.com/codecov/codecov-node/blob/master/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-node/compare/v3.8.1...v3.8.2)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-04 09:15:55 +00:00
dependabot[bot] efbb4a5a00
chore:(deps): bump @solana/spl-token-registry in /explorer (#17028)
Bumps [@solana/spl-token-registry](https://github.com/solana-labs/token-list) from 0.2.67 to 0.2.68.
- [Release notes](https://github.com/solana-labs/token-list/releases)
- [Changelog](https://github.com/solana-labs/token-list/blob/main/CHANGELOG.md)
- [Commits](https://github.com/solana-labs/token-list/compare/v0.2.67...v0.2.68)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-04 09:07:16 +00:00
Trent Nelson f17b80236f test-validator: Plumb --limit-ledger-size 2021-05-04 08:45:24 +00:00
carllin bc7e741514
Integrate gossip votes into switching threshold (#16973) 2021-05-04 00:51:42 -07:00
Colin Gray 9ff17a1c18 Update web3.js import sample 2021-05-03 23:32:45 -07:00
Solana Maintainers 0ebfa08860 Remove ramp-tps 2021-05-04 02:06:50 +00:00
Tyera Eulberg 694c674aa6
Implement Bip32 for seed-phrase/passphrase signing (#16942)
* Add Keypair helpers for bip32 derivation

* Plumb bip32 for SignerSourceKind::Ask

* Support full-path querystring

* Use as_ref

* Add public wrappers for from_uri cases

* Support master root derivations (and fix too-deep print

* Add ask:// HD documentation

* Update ASK elsewhere in docs
2021-05-03 19:58:56 -06:00
publish-docs.sh 6318705607 Add keys 2021-05-03 17:18:54 -07:00
publish-docs.sh b948a18841 Key rotation 2021-05-03 17:18:54 -07:00
publish-docs.sh b2778f34f5 Rotate keys 2021-05-03 17:18:54 -07:00
behzad nouri 7cea2c4466 validates gossip addresses before sending pull-requests
IP addresses need to be validated before sending packets to them.
This commit, sends a ping packet to nodes before any pull requests.
Pull requests are then only sent to the nodes which have responded with
the correct hash of their respective ping packet.
2021-05-03 18:21:06 +00:00
behzad nouri 2231017b35 uses Mutex instead of RwLock for ping_cache 2021-05-03 18:21:06 +00:00
sakridge d94e4ef7c9
More docs for bank.rs (#17006) 2021-05-03 17:37:18 +00:00
Jeff Washington (jwash) 92b8b20ca5
AccountSharedData.lamports private (#16985) 2021-05-03 17:25:31 +00:00
behzad nouri a698e34744
patches local pending push messages processing (#16833)
process_push_messages writes local pending push messages to the crds
table, but it discards the return value:
https://github.com/solana-labs/solana/blob/cf779c63c/core/src/crds_gossip.rs#L96-L102

In order to exclude outdated values from the next pull-request, we need
to record the hash of values purged/overridden by the local push
messages, otherwise pull-responses will return outdated values back to
the node:
https://github.com/solana-labs/solana/blob/c1829dd00/core/src/crds_gossip_pull.rs#L447-L452

Additionally, gossip packets arrive and are processed out of order. So,
local pending push messages should be flushed *before* generating bloom
filters for pull-requests, preventing pull-responses returning the same
values back to the node itself. This requires flipping order of
generating pull and push messages:
https://github.com/solana-labs/solana/blob/cf779c63c/core/src/cluster_info.rs#L1757-L1762

Both above bugs cause redundant traffic and bandwidth waste in gossip
pull-responses.
2021-05-03 16:00:17 +00:00
Jeff Washington (jwash) 541aa5ad85
tests: lamports -> lamports() (#16982) 2021-05-03 10:45:54 -05:00