Tao Zhu
a21fc3f303
Apply transaction actual execution units to cost_tracker ( #24311 )
...
* Pass the sum of consumed compute units to cost_tracker
* cost model tracks builtins and bpf programs separately, enabling adjust block cost by actual bpf programs execution costs
* Copied nightly-only experimental `checked_add_(un)signed` implementation to sdk
* Add function to update cost tracker with execution cost adjustment
* Review suggestion - using enum instead of struct for CommitTransactionDetails
Co-authored-by: Justin Starry <justin.m.starry@gmail.com>
* review - rename variable to distinguish accumulated_consumed_units from individual compute_units_consumed
* not to use signed integer operations
* Review - using saturating_add_assign!(), and checked_*().unwrap_or()
* Review - using Ordering enum to cmp
* replace checked_ with saturating_
* review - remove unnecessary Option<>
* Review - add function to report number of non-zero units account to metrics
2022-04-21 07:38:07 +00:00
Tyera Eulberg
b42f34a7b8
Update Rpc filters to support token-2022 ( #24541 )
...
* Add TokenAccountState rpc_filter
* Use a method on RpcFliterType instead of helper
2022-04-20 19:18:12 -06:00
dependabot[bot]
40b48f807a
chore: bump libc from 0.2.120 to 0.2.124 ( #24520 )
...
* chore: bump libc from 0.2.120 to 0.2.124
Bumps [libc](https://github.com/rust-lang/libc ) from 0.2.120 to 0.2.124.
- [Release notes](https://github.com/rust-lang/libc/releases )
- [Commits](https://github.com/rust-lang/libc/compare/0.2.120...0.2.124 )
---
updated-dependencies:
- dependency-name: libc
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
* [auto-commit] Update all Cargo lock files
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2022-04-20 15:45:13 -06:00
Jon Cinque
c43afe2d7f
spl: Bump token to v3.3.0 and ATA to v1.0.5 ( #22649 )
...
* Bump spl-token and ATA to v3.3.0
* Add parsers for new token instructions
* Update parser for modified associated-token-account instruction
* Update to use 1.0.5 once it's released
* Update Cargo.lock in programs/bpf
2022-04-20 19:13:42 +02:00
steviez
2a770e9726
Use unsigned_abs() instead of casting abs() ( #24521 )
2022-04-20 12:01:33 -05:00
dependabot[bot]
dd15193c69
chore: bump rayon from 1.5.1 to 1.5.2 ( #24470 )
...
* chore: bump rayon from 1.5.1 to 1.5.2
Bumps [rayon](https://github.com/rayon-rs/rayon ) from 1.5.1 to 1.5.2.
- [Release notes](https://github.com/rayon-rs/rayon/releases )
- [Changelog](https://github.com/rayon-rs/rayon/blob/master/RELEASES.md )
- [Commits](https://github.com/rayon-rs/rayon/commits )
---
updated-dependencies:
- dependency-name: rayon
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
* [auto-commit] Update all Cargo lock files
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2022-04-19 23:17:52 -06:00
Tyera Eulberg
77f6ec5625
Add program_id to TokenBalances structs ( #24513 )
...
* Add program_id to TokenBalances structs
* Update docs
2022-04-19 22:01:22 -06:00
Trent Nelson
50fba01842
rpc-pubsub: reduce metrics/log spam
2022-04-15 01:16:58 -06:00
Tyera Eulberg
f7d557d5ae
Update simulateTransaction rpc handling of return_data, and update docs ( #24355 )
...
* Stringify return_data program_id; also camel-case all fields
* Update simulateTransaction json-rpc docs
* Base64-encode return data in simulation RPC responses
2022-04-14 23:42:08 -06:00
Rachael Pai
aea17c35ae
Add a stringified credential option for LedgerStorage ( #24314 )
...
* add a stringified credential option for LedgerStorage
* fix clippy::useless-format warning
* change CredentialOption to enum CredentialType
* rename credential_option to credential_type
* restore LedgerStorage new fn signature
* fmt
Co-authored-by: Tyera Eulberg <tyera@solana.com>
2022-04-13 14:35:06 -06:00
Tyera Eulberg
fb67ff14de
Remove replica-node crates ( #24152 )
2022-04-06 16:52:19 -06:00
HaoranYi
c9a476e24d
handle channel disconnect ( #24036 )
2022-04-01 13:47:06 -05:00
HaoranYi
51b37f0184
Modify rpc_completed_slot_service to be non-blocking ( #24007 )
...
* timeout for validator exits
* clippy
* print backtrace when panic
* add backtrace package
* increase time out to 30s
* debug logging
* make rpc complete service non blocking
* reduce log level
* remove logging
* recv_timeout
* remove backtrace
* remove sleep
* remove unused variable
* add comments
* Update core/src/validator.rs
Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>
* Update core/src/validator.rs
Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>
* whitespace
* more whitespace
* fix build
Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>
2022-03-31 16:44:23 -05:00
Jon Cinque
7af48465fa
transaction-status: Add return data to meta ( #23688 )
...
* transaction-status: Add return data to meta
* Add return data to simulation results
* Use pretty-hex for printing return data
* Update arg name, make TransactionRecord struct
* Rename TransactionRecord -> ExecutionRecord
2022-03-22 23:17:05 +01:00
Will Hickey
c4ecfa5716
Bump version to v1.11 ( #23807 )
...
* Revert crossbeam_epoch to stable. 0.9.8 only works with nightly
* Remove unneeded unit expression
2022-03-21 17:40:50 -05:00
Trent Nelson
9b32b72990
bigtable: allow custom instance names
2022-03-21 11:26:49 -06:00
Trent Nelson
f513195468
bigtable: add a config ctor for `LedgerStorage`
2022-03-21 11:26:49 -06:00
Tyera Eulberg
63ee00e647
Refactor validator bigtable config
2022-03-21 11:26:49 -06:00
DimAn
739e43ba58
Add ability to get the latest incremental snapshot via RPC ( #23788 )
2022-03-21 11:48:49 -05:00
Lijun Wang
ae76fe2bd7
Made connection cache configurable. ( #23783 )
...
Added command-line argument tpu-use-quic argument.
Changed connection cache to return different connections based on the config.
2022-03-21 09:31:37 -07:00
Will Hickey
2f58c9e501
Bump version to 1.10.4 ( #23743 )
2022-03-17 14:02:13 -05:00
dependabot[bot]
44ab660172
chore: bump libc from 0.2.119 to 0.2.120 ( #23694 )
...
* chore: bump libc from 0.2.119 to 0.2.120
Bumps [libc](https://github.com/rust-lang/libc ) from 0.2.119 to 0.2.120.
- [Release notes](https://github.com/rust-lang/libc/releases )
- [Commits](https://github.com/rust-lang/libc/compare/0.2.119...0.2.120 )
---
updated-dependencies:
- dependency-name: libc
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
* [auto-commit] Update all Cargo lock files
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2022-03-16 00:34:40 -06:00
Justin Starry
8c8f9694e0
Refactor: Sanitized transaction creation ( #23558 )
...
* Refactor: SanitizedTransaction::try_create optionally computes hash
* Refactor: Add SimpleAddressLoader
2022-03-15 12:02:22 +08:00
HaoranYi
0c684721d8
Separate remotely downloaded snapshot archives ( #23510 )
...
* seperate remotely downloaded snapshot archives
* add str const for snapshot download dir
* only walk remote sub directory
* move directory creation outside of loop
* move is_remote to traits
* clippy simplify
* clippy
* clippy
* add unittest
* fix local cluster tests
* look for remote snapshot archive in remote foler
* create remote dir in tests
* use snapshot download dir constant
* extract build_remote_dir fn
* fix build
* code review - walking snapshot archived dirs explicitly
* fix build
* fix build
* fix comments
* Update runtime/src/snapshot_utils.rs
Co-authored-by: Brooks Prumo <brooks@prumo.org>
* clippy
* borrow to avoid copy
Co-authored-by: Brooks Prumo <brooks@prumo.org>
2022-03-14 14:03:59 -05:00
Will Hickey
63bf0f66af
Bump version to 1.10.3 ( #23648 )
2022-03-14 11:18:45 -05:00
dependabot[bot]
b1da7cff66
chore: bump base64 from 0.12.3 to 0.13.0 ( #23616 )
...
* chore: bump base64 from 0.12.3 to 0.13.0
Bumps [base64](https://github.com/marshallpierce/rust-base64 ) from 0.12.3 to 0.13.0.
- [Release notes](https://github.com/marshallpierce/rust-base64/releases )
- [Changelog](https://github.com/marshallpierce/rust-base64/blob/master/RELEASE-NOTES.md )
- [Commits](https://github.com/marshallpierce/rust-base64/compare/v0.12.3...v0.13.0 )
---
updated-dependencies:
- dependency-name: base64
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
* Update Cargo.lock files
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tyera Eulberg <tyera@solana.com>
2022-03-11 16:01:15 -07:00
Brooks Prumo
d20dd21600
Sort tables in Cargo.toml files ( #23602 )
2022-03-11 11:05:57 -06:00
sakridge
9b591286d7
Revert "chore: bump dashmap from 4.0.2 to 5.1.0 ( #23372 )" ( #23592 )
...
This reverts commit 3a0271c113
.
2022-03-11 09:12:27 +01:00
Will Hickey
b444836a97
Bump version to 1.10.2 ( #23597 )
2022-03-10 16:41:06 -06:00
Justin Starry
249d926d1b
Refactor: Add transaction binary encoding enum ( #23546 )
2022-03-09 16:09:08 +08:00
dependabot[bot]
46ec5d563b
chore: bump libc from 0.2.117 to 0.2.119 ( #23527 )
...
* chore: bump libc from 0.2.117 to 0.2.119
Bumps [libc](https://github.com/rust-lang/libc ) from 0.2.117 to 0.2.119.
- [Release notes](https://github.com/rust-lang/libc/releases )
- [Commits](https://github.com/rust-lang/libc/compare/0.2.117...0.2.119 )
---
updated-dependencies:
- dependency-name: libc
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
* [auto-commit] Update all Cargo lock files
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2022-03-08 14:25:38 -07:00
Justin Starry
3114c199bd
Add RPC support for versioned transactions ( #22530 )
...
* Add RPC support for versioned transactions
* fix doc tests
* Add rpc test for versioned txs
* Switch to preflight bank
2022-03-08 15:20:34 +08:00
dependabot[bot]
3a0271c113
chore: bump dashmap from 4.0.2 to 5.1.0 ( #23372 )
...
* chore: bump dashmap from 4.0.2 to 5.1.0
Bumps [dashmap](https://github.com/xacrimon/dashmap ) from 4.0.2 to 5.1.0.
- [Release notes](https://github.com/xacrimon/dashmap/releases )
- [Commits](https://github.com/xacrimon/dashmap/commits/v5.1.0 )
---
updated-dependencies:
- dependency-name: dashmap
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
* [auto-commit] Update all Cargo lock files
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2022-03-07 00:00:26 -05:00
Justin Starry
38db1dead4
Refactor RPC tests ( #23483 )
2022-03-04 18:20:11 +08:00
dependabot[bot]
61d7bdd66f
chore: bump serde_json from 1.0.78 to 1.0.79 ( #23461 )
...
* chore: bump serde_json from 1.0.78 to 1.0.79
Bumps [serde_json](https://github.com/serde-rs/json ) from 1.0.78 to 1.0.79.
- [Release notes](https://github.com/serde-rs/json/releases )
- [Commits](https://github.com/serde-rs/json/compare/v1.0.78...v1.0.79 )
---
updated-dependencies:
- dependency-name: serde_json
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
* [auto-commit] Update all Cargo lock files
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <you@example.com>
2022-03-02 23:38:06 -07:00
Will Hickey
1a99251498
Bump version to 1.10.1 ( #23453 )
2022-03-02 13:47:01 -06:00
Tyera Eulberg
d3ebe8d8f5
Remove unneeded jsonrpc dependencies/features; update do-audit ( #23436 )
...
* Update generic-array note
* Remove unneeded jsonrpc deps
* Remove unneeded jsonrpc features
* Rewrite slot-update test without websocket crate
* Rewrite rpc-subscription test without websocket crate, and remove jsonrpc deps
* Update expected balance to accommodate rent-exempt minimum transfer amount
* Remove obsolete audit ignores
2022-03-02 01:42:01 -07:00
dependabot[bot]
ce4d579499
chore: bump serial_test from 0.5.1 to 0.6.0 ( #23414 )
...
Bumps [serial_test](https://github.com/palfrey/serial_test ) from 0.5.1 to 0.6.0.
- [Release notes](https://github.com/palfrey/serial_test/releases )
- [Commits](https://github.com/palfrey/serial_test/compare/v0.5.1...v0.6.0 )
---
updated-dependencies:
- dependency-name: serial_test
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-03-01 12:13:40 -07:00
Tyera Eulberg
3b5b71ce44
Improve UX querying rpc for blocks at or before the snapshot from boot ( #23403 )
...
* Bump first-available block to first complete block
* Remove obsolete purges in tests (PrimaryIndex toggling no longer in use
* Check first-available block in Rpc check_slot_cleaned_up
2022-02-28 23:57:41 -07:00
Trent Nelson
d4292774c5
checks
2022-02-25 08:05:28 +00:00
Tyera Eulberg
7e08ae1d0c
Revert "Add simulation detection countermeasure ( #22880 )" ( #23261 )
...
This reverts commit c42b80f099
.
2022-02-21 21:15:37 +00:00
buffalu
70ebab2c82
Add rustfmt.toml and `cargo fmt` ( #23238 )
...
* fmt
* formatted
Co-authored-by: Lucas B <buffalu@jito.network>
2022-02-19 13:32:29 +08:00
Trent Nelson
4213ece7bd
rpc: make `getGenesisHash` part of minimal api
2022-02-16 10:05:46 -07:00
Michael Vines
c42b80f099
Add simulation detection countermeasure ( #22880 )
...
* Add simulation detection countermeasures
* Add program and test using TestValidator
* Remove incinerator deposit
* Remove incinerator
* Update Cargo.lock
* Add more features to simulation bank
* Update Cargo.lock per rebase
Co-authored-by: Jon Cinque <jon.cinque@gmail.com>
2022-02-15 13:09:59 +01:00
Lijun Wang
c04438be4b
Retaining transaction logs when transaction plugin is loaded. ( #22874 )
...
Transaction logs are not being saved to the database through the plugin interface.
Summary of Changes
Retain the transaction logs when transaction notification plugin is loaded.
Fixes #
lijunwangs/solana-accountsdb-plugin-postgres#6
2022-02-11 20:29:07 -08:00
Jack May
3d9874b95a
Add fees to tx-wide caps ( #22081 )
2022-02-11 16:23:16 -08:00
Justin Starry
d5dec989b9
Enforce tx metadata upload with static types ( #23028 )
2022-02-10 13:28:18 +08:00
dependabot[bot]
9d036be61b
chore: bump libc from 0.2.115 to 0.2.117 ( #23034 )
...
* chore: bump libc from 0.2.115 to 0.2.117
Bumps [libc](https://github.com/rust-lang/libc ) from 0.2.115 to 0.2.117.
- [Release notes](https://github.com/rust-lang/libc/releases )
- [Commits](https://github.com/rust-lang/libc/compare/0.2.115...0.2.117 )
---
updated-dependencies:
- dependency-name: libc
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
* [auto-commit] Update all Cargo lock files
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2022-02-09 16:49:44 -07:00
Michael Vines
86d465c531
Prepare RPC subsystem for multiple SPL Token program ids
2022-02-09 08:16:00 -08:00
Kirill Fomichev
541b5a4826
Rename struct to imported name ( #22814 )
...
* use imported RpcResponse
* Remove extra map method
* rename result to accounts
* fmt
2022-02-08 12:01:40 -07:00