Compare commits

...

7 Commits

Author SHA1 Message Date
31f7b3782e Fix Blocktree Config (#7399) (#7468)
automerge
2019-12-13 00:16:19 -08:00
d6169f92c1 Add vote-update-validator subcommand
(cherry picked from commit f7a87d5e52)
2019-12-13 00:19:10 -07:00
7df72d36c4 Publish solana-docker releases (#7460) (#7462)
automerge
2019-12-12 16:50:23 -08:00
5318cdac8f Add solana-watchtower program 2019-12-12 16:21:39 -07:00
00434d5e6e Clarify show-vote-account/uptime output: "node id" really means "validator identity" (#7458)
automerge
2019-12-12 14:50:44 -08:00
ebf644ddef Add uptime column to show-validators (#7441) (#7445)
automerge
2019-12-12 08:27:50 -08:00
5e4fe9c67b Bump version to 0.21.4 2019-12-11 21:35:45 -07:00
91 changed files with 1181 additions and 765 deletions

607
Cargo.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -51,6 +51,7 @@ members = [
"vote-signer",
"cli",
"rayon-threadlimit",
"watchtower",
]
exclude = [

View File

@ -2,7 +2,7 @@
authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-archiver"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
@ -10,10 +10,10 @@ homepage = "https://solana.com/"
[dependencies]
clap = "2.33.0"
console = "0.9.1"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-core = { path = "../core", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-metrics = { path = "../metrics", version = "0.21.3" }
solana-net-utils = { path = "../net-utils", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-core = { path = "../core", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-metrics = { path = "../metrics", version = "0.21.4" }
solana-net-utils = { path = "../net-utils", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }

View File

@ -2,7 +2,7 @@
authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-banking-bench"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
@ -10,11 +10,11 @@ homepage = "https://solana.com/"
[dependencies]
log = "0.4.6"
rayon = "1.2.0"
solana-core = { path = "../core", version = "0.21.3" }
solana-ledger = { path = "../ledger", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-runtime = { path = "../runtime", version = "0.21.3" }
solana-measure = { path = "../measure", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-core = { path = "../core", version = "0.21.4" }
solana-ledger = { path = "../ledger", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-runtime = { path = "../runtime", version = "0.21.4" }
solana-measure = { path = "../measure", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
rand = "0.6.5"
crossbeam-channel = "0.3"

View File

@ -2,7 +2,7 @@
authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-bench-exchange"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
@ -23,19 +23,19 @@ serde = "1.0.102"
serde_derive = "1.0.102"
serde_json = "1.0.41"
serde_yaml = "0.8.11"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-core = { path = "../core", version = "0.21.3" }
solana-genesis = { path = "../genesis", version = "0.21.3" }
solana-client = { path = "../client", version = "0.21.3" }
solana-drone = { path = "../drone", version = "0.21.3" }
solana-exchange-program = { path = "../programs/exchange", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-metrics = { path = "../metrics", version = "0.21.3" }
solana-net-utils = { path = "../net-utils", version = "0.21.3" }
solana-runtime = { path = "../runtime", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-core = { path = "../core", version = "0.21.4" }
solana-genesis = { path = "../genesis", version = "0.21.4" }
solana-client = { path = "../client", version = "0.21.4" }
solana-drone = { path = "../drone", version = "0.21.4" }
solana-exchange-program = { path = "../programs/exchange", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-metrics = { path = "../metrics", version = "0.21.4" }
solana-net-utils = { path = "../net-utils", version = "0.21.4" }
solana-runtime = { path = "../runtime", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
untrusted = "0.7.0"
ws = "0.9.1"
[dev-dependencies]
solana-local-cluster = { path = "../local-cluster", version = "0.21.3" }
solana-local-cluster = { path = "../local-cluster", version = "0.21.4" }

View File

@ -2,14 +2,14 @@
authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-bench-streamer"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
[dependencies]
clap = "2.33.0"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-core = { path = "../core", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-net-utils = { path = "../net-utils", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-core = { path = "../core", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-net-utils = { path = "../net-utils", version = "0.21.4" }

View File

@ -2,7 +2,7 @@
authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-bench-tps"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
@ -16,24 +16,24 @@ serde = "1.0.102"
serde_derive = "1.0.102"
serde_json = "1.0.41"
serde_yaml = "0.8.11"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-core = { path = "../core", version = "0.21.3" }
solana-genesis = { path = "../genesis", version = "0.21.3" }
solana-client = { path = "../client", version = "0.21.3" }
solana-drone = { path = "../drone", version = "0.21.3" }
solana-librapay-api = { path = "../programs/librapay_api", version = "0.21.3", optional = true }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-metrics = { path = "../metrics", version = "0.21.3" }
solana-measure = { path = "../measure", version = "0.21.3" }
solana-net-utils = { path = "../net-utils", version = "0.21.3" }
solana-runtime = { path = "../runtime", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-move-loader-program = { path = "../programs/move_loader", version = "0.21.3", optional = true }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-core = { path = "../core", version = "0.21.4" }
solana-genesis = { path = "../genesis", version = "0.21.4" }
solana-client = { path = "../client", version = "0.21.4" }
solana-drone = { path = "../drone", version = "0.21.4" }
solana-librapay-api = { path = "../programs/librapay_api", version = "0.21.4", optional = true }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-metrics = { path = "../metrics", version = "0.21.4" }
solana-measure = { path = "../measure", version = "0.21.4" }
solana-net-utils = { path = "../net-utils", version = "0.21.4" }
solana-runtime = { path = "../runtime", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
solana-move-loader-program = { path = "../programs/move_loader", version = "0.21.4", optional = true }
[dev-dependencies]
serial_test = "0.2.0"
serial_test_derive = "0.2.0"
solana-local-cluster = { path = "../local-cluster", version = "0.21.3" }
solana-local-cluster = { path = "../local-cluster", version = "0.21.4" }
[features]
move = ["solana-librapay-api", "solana-move-loader-program"]

View File

@ -177,7 +177,7 @@ $ solana send-timestamp <PUBKEY> <PROCESS_ID> --date 2018-12-24T23:59:00
## Usage
### solana-cli
```text
solana-cli 0.21.3
solana-cli 0.21.4
Blockchain, Rebuilt for Scale
USAGE:

View File

@ -156,7 +156,7 @@ The result value will be an RpcResponse JSON object containing an AccountInfo JS
curl -X POST -H "Content-Type: application/json" -d '{"jsonrpc":"2.0", "id":1, "method":"getAccountInfo", "params":["2gVkYWexTHR5Hb2aLeQN3tnngvWzisFKXDUPrgMHpdST"]}' http://localhost:8899
// Result
{"jsonrpc":"2.0","result":{"context":{"slot":1},"value":{"executable":false,"owner":[1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"lamports":1,"data":[3,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,0.21.3,0,0,0,0,0,0,50,48,53,48,45,48,49,45,48,49,84,48,48,58,48,48,58,48,48,90,252,10,7,28,246,140,88,177,98,82,10,227,89,81,18,30,194,101,199,16,11,73,133,20,246,62,114,39,20,113,189,32,50,0,0,0,0,0,0,0,247,15,36,102,167,83,225,42,133,127,82,34,36,224,207,130,109,230,224,188,163,33,213,13,5,117,211,251,65,159,197,51,0,0,0,0,0,0]}},"id":1}
{"jsonrpc":"2.0","result":{"context":{"slot":1},"value":{"executable":false,"owner":[1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"lamports":1,"data":[3,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,0.21.4,0,0,0,0,0,0,50,48,53,48,45,48,49,45,48,49,84,48,48,58,48,48,58,48,48,90,252,10,7,28,246,140,88,177,98,82,10,227,89,81,18,30,194,101,199,16,11,73,133,20,246,62,114,39,20,113,189,32,50,0,0,0,0,0,0,0,247,15,36,102,167,83,225,42,133,127,82,34,36,224,207,130,109,230,224,188,163,33,213,13,5,117,211,251,65,159,197,51,0,0,0,0,0,0]}},"id":1}
```
### getBalance
@ -824,7 +824,7 @@ Subscribe to an account to receive notifications when the lamports or data for a
#### Notification Format:
```bash
{"jsonrpc": "2.0","method": "accountNotification", "params": {"result": {"executable":false,"owner":[1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"lamports":1,"data":[3,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,0.21.3,0,0,0,0,0,0,50,48,53,48,45,48,49,45,48,49,84,48,48,58,48,48,58,48,48,90,252,10,7,28,246,140,88,177,98,82,10,227,89,81,18,30,194,101,199,16,11,73,133,20,246,62,114,39,20,113,189,32,50,0,0,0,0,0,0,0,247,15,36,102,167,83,225,42,133,127,82,34,36,224,207,130,109,230,224,188,163,33,213,13,5,117,211,251,65,159,197,51,0,0,0,0,0,0]},"subscription":0}}
{"jsonrpc": "2.0","method": "accountNotification", "params": {"result": {"executable":false,"owner":[1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"lamports":1,"data":[3,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,0.21.4,0,0,0,0,0,0,50,48,53,48,45,48,49,45,48,49,84,48,48,58,48,48,58,48,48,90,252,10,7,28,246,140,88,177,98,82,10,227,89,81,18,30,194,101,199,16,11,73,133,20,246,62,114,39,20,113,189,32,50,0,0,0,0,0,0,0,247,15,36,102,167,83,225,42,133,127,82,34,36,224,207,130,109,230,224,188,163,33,213,13,5,117,211,251,65,159,197,51,0,0,0,0,0,0]},"subscription":0}}
```
### accountUnsubscribe
@ -882,7 +882,7 @@ Subscribe to a program to receive notifications when the lamports or data for a
* `object` - account info JSON object \(see [getAccountInfo](jsonrpc-api.md#getaccountinfo) for field details\)
```bash
{"jsonrpc":"2.0","method":"programNotification","params":{{"result":["8Rshv2oMkPu5E4opXTRyuyBeZBqQ4S477VG26wUTFxUM",{"executable":false,"lamports":1,"owner":[129,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"data":[1,1,1,0,0,0,0,0,0,0.21.3,0,0,0,0,0,0,50,48,49,56,45,49,50,45,50,52,84,50,51,58,53,57,58,48,48,90,235,233,39,152,15,44,117,176,41,89,100,86,45,61,2,44,251,46,212,37,35,118,163,189,247,84,27,235,178,62,55,89,0,0,0,0,50,0,0,0,0,0,0,0,235,233,39,152,15,44,117,176,41,89,100,86,45,61,2,44,251,46,212,37,35,118,163,189,247,84,27,235,178,62,45,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]}],"subscription":0}}
{"jsonrpc":"2.0","method":"programNotification","params":{{"result":["8Rshv2oMkPu5E4opXTRyuyBeZBqQ4S477VG26wUTFxUM",{"executable":false,"lamports":1,"owner":[129,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"data":[1,1,1,0,0,0,0,0,0,0.21.4,0,0,0,0,0,0,50,48,49,56,45,49,50,45,50,52,84,50,51,58,53,57,58,48,48,90,235,233,39,152,15,44,117,176,41,89,100,86,45,61,2,44,251,46,212,37,35,118,163,189,247,84,27,235,178,62,55,89,0,0,0,0,50,0,0,0,0,0,0,0,235,233,39,152,15,44,117,176,41,89,100,86,45,61,2,44,251,46,212,37,35,118,163,189,247,84,27,235,178,62,45,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]}],"subscription":0}}
```
### programUnsubscribe

View File

@ -81,8 +81,8 @@ With a FEC rate: `16:4`
With FEC rate of `16:16`
* `G = 12800`
* `S = SUM of i=0 -> 32 for binomial(prob_failure = 0.2775, trials = 64, failures = i) = 0.0.21.3`
* `B = (1 - 0.0.21.3) ^ (12800 / 32) = 0.42583`
* `S = SUM of i=0 -> 32 for binomial(prob_failure = 0.2775, trials = 64, failures = i) = 0.0.21.4`
* `B = (1 - 0.0.21.4) ^ (12800 / 32) = 0.42583`
With FEC rate of `32:32`
* `G = 12800`

View File

@ -2,7 +2,7 @@
Follow this guide to setup Solana's key generation tool called `solana-keygen`
{% hint style="warn" %}
After installation, ensure your version is `0.21.3` or higher by running `solana-keygen -V`
After installation, ensure your version is `0.21.4` or higher by running `solana-keygen -V`
{% endhint %}
## Download

View File

@ -1,6 +1,6 @@
[package]
name = "solana-chacha-sys"
version = "0.21.3"
version = "0.21.4"
description = "Solana chacha-sys"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"

View File

@ -33,7 +33,7 @@ else
fi
if [[ -z $CHANNEL_OR_TAG ]]; then
echo +++ Unable to determine channel to publish into, exiting.
echo +++ Unable to determine channel or tag to publish into, exiting.
exit 0
fi

View File

@ -1,6 +1,6 @@
[package]
name = "solana-clap-utils"
version = "0.21.3"
version = "0.21.4"
description = "Solana utilities for the clap"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,7 +12,7 @@ edition = "2018"
clap = "2.33.0"
rpassword = "4.0"
semver = "0.9.0"
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
tiny-bip39 = "0.6.2"
url = "2.1.0"

View File

@ -3,7 +3,7 @@ authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-cli"
description = "Blockchain, Rebuilt for Scale"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
@ -28,24 +28,24 @@ serde = "1.0.102"
serde_derive = "1.0.102"
serde_json = "1.0.41"
serde_yaml = "0.8.11"
solana-budget-program = { path = "../programs/budget", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-client = { path = "../client", version = "0.21.3" }
solana-config-program = { path = "../programs/config", version = "0.21.3" }
solana-drone = { path = "../drone", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-net-utils = { path = "../net-utils", version = "0.21.3" }
solana-runtime = { path = "../runtime", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-stake-program = { path = "../programs/stake", version = "0.21.3" }
solana-storage-program = { path = "../programs/storage", version = "0.21.3" }
solana-vote-program = { path = "../programs/vote", version = "0.21.3" }
solana-vote-signer = { path = "../vote-signer", version = "0.21.3" }
solana-budget-program = { path = "../programs/budget", version = "0.21.4" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-client = { path = "../client", version = "0.21.4" }
solana-config-program = { path = "../programs/config", version = "0.21.4" }
solana-drone = { path = "../drone", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-net-utils = { path = "../net-utils", version = "0.21.4" }
solana-runtime = { path = "../runtime", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
solana-stake-program = { path = "../programs/stake", version = "0.21.4" }
solana-storage-program = { path = "../programs/storage", version = "0.21.4" }
solana-vote-program = { path = "../programs/vote", version = "0.21.4" }
solana-vote-signer = { path = "../vote-signer", version = "0.21.4" }
url = "2.1.0"
[dev-dependencies]
solana-core = { path = "../core", version = "0.21.3" }
solana-budget-program = { path = "../programs/budget", version = "0.21.3" }
solana-core = { path = "../core", version = "0.21.4" }
solana-budget-program = { path = "../programs/budget", version = "0.21.4" }
tempfile = "3.1.0"
[[bin]]

View File

@ -173,7 +173,16 @@ pub enum CliCommand {
aggregate: bool,
span: Option<u64>,
},
VoteAuthorize(Pubkey, Pubkey, VoteAuthorize),
VoteAuthorize {
vote_account_pubkey: Pubkey,
new_authorized_pubkey: Pubkey,
vote_authorize: VoteAuthorize,
},
VoteUpdateValidator {
vote_account_pubkey: Pubkey,
new_identity_pubkey: Pubkey,
authorized_voter: KeypairEq,
},
// Wallet Commands
Address,
Airdrop {
@ -346,6 +355,7 @@ pub fn parse_command(matches: &ArgMatches<'_>) -> Result<CliCommandInfo, Box<dyn
},
// Vote Commands
("create-vote-account", Some(matches)) => parse_vote_create_account(matches),
("vote-update-validator", Some(matches)) => parse_vote_update_validator(matches),
("vote-authorize-voter", Some(matches)) => {
parse_vote_authorize(matches, VoteAuthorize::Voter)
}
@ -1206,15 +1216,28 @@ pub fn process_command(config: &CliConfig) -> ProcessResult {
&vote_account_pubkey,
*use_lamports_unit,
),
CliCommand::VoteAuthorize(vote_account_pubkey, new_authorized_pubkey, vote_authorize) => {
process_vote_authorize(
&rpc_client,
config,
&vote_account_pubkey,
&new_authorized_pubkey,
*vote_authorize,
)
}
CliCommand::VoteAuthorize {
vote_account_pubkey,
new_authorized_pubkey,
vote_authorize,
} => process_vote_authorize(
&rpc_client,
config,
&vote_account_pubkey,
&new_authorized_pubkey,
*vote_authorize,
),
CliCommand::VoteUpdateValidator {
vote_account_pubkey,
new_identity_pubkey,
authorized_voter,
} => process_vote_update_validator(
&rpc_client,
config,
&vote_account_pubkey,
&new_identity_pubkey,
authorized_voter,
),
CliCommand::Uptime {
pubkey: vote_account_pubkey,
aggregate,
@ -2184,8 +2207,20 @@ mod tests {
assert_eq!(signature.unwrap(), SIGNATURE.to_string());
let new_authorized_pubkey = Pubkey::new_rand();
config.command =
CliCommand::VoteAuthorize(bob_pubkey, new_authorized_pubkey, VoteAuthorize::Voter);
config.command = CliCommand::VoteAuthorize {
vote_account_pubkey: bob_pubkey,
new_authorized_pubkey,
vote_authorize: VoteAuthorize::Voter,
};
let signature = process_command(&config);
assert_eq!(signature.unwrap(), SIGNATURE.to_string());
let new_identity_pubkey = Pubkey::new_rand();
config.command = CliCommand::VoteUpdateValidator {
vote_account_pubkey: bob_pubkey,
new_identity_pubkey,
authorized_voter: Keypair::new().into(),
};
let signature = process_command(&config);
assert_eq!(signature.unwrap(), SIGNATURE.to_string());
@ -2368,7 +2403,18 @@ mod tests {
};
assert!(process_command(&config).is_err());
config.command = CliCommand::VoteAuthorize(bob_pubkey, bob_pubkey, VoteAuthorize::Voter);
config.command = CliCommand::VoteAuthorize {
vote_account_pubkey: bob_pubkey,
new_authorized_pubkey: bob_pubkey,
vote_authorize: VoteAuthorize::Voter,
};
assert!(process_command(&config).is_err());
config.command = CliCommand::VoteUpdateValidator {
vote_account_pubkey: bob_pubkey,
new_identity_pubkey: bob_pubkey,
authorized_voter: Keypair::new().into(),
};
assert!(process_command(&config).is_err());
config.command = CliCommand::GetSlot {

View File

@ -13,6 +13,7 @@ use solana_client::{rpc_client::RpcClient, rpc_request::RpcVoteAccountInfo};
use solana_sdk::{
clock::{self, Slot},
commitment_config::CommitmentConfig,
epoch_schedule::{Epoch, EpochSchedule},
hash::Hash,
pubkey::Pubkey,
signature::{Keypair, KeypairUtil},
@ -260,6 +261,20 @@ fn new_spinner_progress_bar() -> ProgressBar {
progress_bar
}
/// Aggregate epoch credit stats and return (total credits, total slots, total epochs)
pub fn aggregate_epoch_credits(
epoch_credits: &[(Epoch, u64, u64)],
epoch_schedule: &EpochSchedule,
) -> (u64, u64, u64) {
epoch_credits
.iter()
.fold((0, 0, 0), |acc, (epoch, credits, prev_credits)| {
let credits_earned = credits - prev_credits;
let slots_in_epoch = epoch_schedule.get_slots_in_epoch(*epoch);
(acc.0 + credits_earned, acc.1 + slots_in_epoch, acc.2 + 1)
})
}
pub fn process_catchup(rpc_client: &RpcClient, node_pubkey: &Pubkey) -> ProcessResult {
let cluster_nodes = rpc_client.get_cluster_nodes()?;
@ -550,6 +565,7 @@ pub fn process_show_gossip(rpc_client: &RpcClient) -> ProcessResult {
}
pub fn process_show_validators(rpc_client: &RpcClient, use_lamports_unit: bool) -> ProcessResult {
let epoch_schedule = rpc_client.get_epoch_schedule()?;
let vote_accounts = rpc_client.get_vote_accounts()?;
let total_active_stake = vote_accounts
.current
@ -592,19 +608,21 @@ pub fn process_show_validators(rpc_client: &RpcClient, use_lamports_unit: bool)
println!(
"{}",
style(format!(
" {:<44} {:<44} {} {} {} {}",
" {:<44} {:<44} {} {} {} {:>7} {}",
"Identity Pubkey",
"Vote Account Pubkey",
"Commission",
"Last Vote",
"Root Block",
"Uptime",
"Active Stake",
))
.bold()
);
fn print_vote_account(
vote_account: &RpcVoteAccountInfo,
vote_account: RpcVoteAccountInfo,
epoch_schedule: &EpochSchedule,
total_active_stake: f64,
use_lamports_unit: bool,
delinquent: bool,
@ -616,8 +634,20 @@ pub fn process_show_validators(rpc_client: &RpcClient, use_lamports_unit: bool)
format!("{}", v)
}
}
fn uptime(epoch_credits: Vec<(Epoch, u64, u64)>, epoch_schedule: &EpochSchedule) -> String {
let (total_credits, total_slots, _) =
aggregate_epoch_credits(&epoch_credits, &epoch_schedule);
if total_slots > 0 {
let total_uptime = 100_f64 * total_credits as f64 / total_slots as f64;
format!("{:.2}%", total_uptime)
} else {
"-".into()
}
}
println!(
"{} {:<44} {:<44} {:>9}% {:>8} {:>10} {:>12}",
"{} {:<44} {:<44} {:>9}% {:>8} {:>10} {:>7} {}",
if delinquent {
WARNING.to_string()
} else {
@ -628,6 +658,7 @@ pub fn process_show_validators(rpc_client: &RpcClient, use_lamports_unit: bool)
vote_account.commission,
non_zero_or_dash(vote_account.last_vote),
non_zero_or_dash(vote_account.root_slot),
uptime(vote_account.epoch_credits, epoch_schedule),
if vote_account.activated_stake > 0 {
format!(
"{} ({:.2}%)",
@ -640,11 +671,23 @@ pub fn process_show_validators(rpc_client: &RpcClient, use_lamports_unit: bool)
);
}
for vote_account in vote_accounts.current.iter() {
print_vote_account(vote_account, total_active_stake, use_lamports_unit, false);
for vote_account in vote_accounts.current.into_iter() {
print_vote_account(
vote_account,
&epoch_schedule,
total_active_stake,
use_lamports_unit,
false,
);
}
for vote_account in vote_accounts.delinquent.iter() {
print_vote_account(vote_account, total_active_stake, use_lamports_unit, true);
for vote_account in vote_accounts.delinquent.into_iter() {
print_vote_account(
vote_account,
&epoch_schedule,
total_active_stake,
use_lamports_unit,
true,
);
}
Ok("".to_string())

View File

@ -1,6 +1,10 @@
use crate::cli::{
build_balance_message, check_account_for_fee, check_unique_pubkeys,
log_instruction_custom_error, CliCommand, CliCommandInfo, CliConfig, CliError, ProcessResult,
use crate::{
cli::{
build_balance_message, check_account_for_fee, check_unique_pubkeys,
log_instruction_custom_error, CliCommand, CliCommandInfo, CliConfig, CliError,
ProcessResult,
},
cluster_query::aggregate_epoch_credits,
};
use clap::{value_t_or_exit, App, Arg, ArgMatches, SubCommand};
use solana_clap_utils::{input_parsers::*, input_validators::*};
@ -34,9 +38,9 @@ impl VoteSubCommands for App<'_, '_> {
.help("Vote account keypair to fund"),
)
.arg(
Arg::with_name("node_pubkey")
Arg::with_name("identity_pubkey")
.index(2)
.value_name("VALIDATOR PUBKEY")
.value_name("VALIDATOR IDENTITY PUBKEY")
.takes_value(true)
.required(true)
.validator(is_pubkey_or_keypair)
@ -66,6 +70,37 @@ impl VoteSubCommands for App<'_, '_> {
.help("Public key of the authorized withdrawer (defaults to cli config pubkey)"),
),
)
.subcommand(
SubCommand::with_name("vote-update-validator")
.about("Update the vote account's validator identity")
.arg(
Arg::with_name("vote_account_pubkey")
.index(1)
.value_name("VOTE ACCOUNT PUBKEY")
.takes_value(true)
.required(true)
.validator(is_pubkey_or_keypair)
.help("Vote account to update"),
)
.arg(
Arg::with_name("new_identity_pubkey")
.index(2)
.value_name("NEW VALIDATOR IDENTITY PUBKEY")
.takes_value(true)
.required(true)
.validator(is_pubkey_or_keypair)
.help("New validator that will vote with this account"),
)
.arg(
Arg::with_name("authorized_voter")
.index(3)
.value_name("AUTHORIZED VOTER KEYPAIR")
.takes_value(true)
.required(true)
.validator(is_keypair)
.help("Authorized voter keypair"),
)
)
.subcommand(
SubCommand::with_name("vote-authorize-voter")
.about("Authorize a new vote signing keypair for the given vote account")
@ -159,7 +194,7 @@ impl VoteSubCommands for App<'_, '_> {
pub fn parse_vote_create_account(matches: &ArgMatches<'_>) -> Result<CliCommandInfo, CliError> {
let vote_account = keypair_of(matches, "vote_account").unwrap();
let node_pubkey = pubkey_of(matches, "node_pubkey").unwrap();
let identity_pubkey = pubkey_of(matches, "identity_pubkey").unwrap();
let commission = value_of(&matches, "commission").unwrap_or(0);
let authorized_voter = pubkey_of(matches, "authorized_voter");
let authorized_withdrawer = pubkey_of(matches, "authorized_withdrawer");
@ -167,7 +202,7 @@ pub fn parse_vote_create_account(matches: &ArgMatches<'_>) -> Result<CliCommandI
Ok(CliCommandInfo {
command: CliCommand::CreateVoteAccount {
vote_account: vote_account.into(),
node_pubkey,
node_pubkey: identity_pubkey,
authorized_voter,
authorized_withdrawer,
commission,
@ -184,11 +219,26 @@ pub fn parse_vote_authorize(
let new_authorized_pubkey = pubkey_of(matches, "new_authorized_pubkey").unwrap();
Ok(CliCommandInfo {
command: CliCommand::VoteAuthorize(
command: CliCommand::VoteAuthorize {
vote_account_pubkey,
new_authorized_pubkey,
vote_authorize,
),
},
require_keypair: true,
})
}
pub fn parse_vote_update_validator(matches: &ArgMatches<'_>) -> Result<CliCommandInfo, CliError> {
let vote_account_pubkey = pubkey_of(matches, "vote_account_pubkey").unwrap();
let new_identity_pubkey = pubkey_of(matches, "new_identity_pubkey").unwrap();
let authorized_voter = keypair_of(matches, "authorized_voter").unwrap();
Ok(CliCommandInfo {
command: CliCommand::VoteUpdateValidator {
vote_account_pubkey,
new_identity_pubkey,
authorized_voter: authorized_voter.into(),
},
require_keypair: true,
})
}
@ -229,7 +279,7 @@ pub fn process_create_vote_account(
rpc_client: &RpcClient,
config: &CliConfig,
vote_account: &Keypair,
node_pubkey: &Pubkey,
identity_pubkey: &Pubkey,
authorized_voter: &Option<Pubkey>,
authorized_withdrawer: &Option<Pubkey>,
commission: u8,
@ -237,7 +287,7 @@ pub fn process_create_vote_account(
let vote_account_pubkey = vote_account.pubkey();
check_unique_pubkeys(
(&vote_account_pubkey, "vote_account_pubkey".to_string()),
(&node_pubkey, "node_pubkey".to_string()),
(&identity_pubkey, "identity_pubkey".to_string()),
)?;
check_unique_pubkeys(
(&config.keypair.pubkey(), "cli keypair".to_string()),
@ -251,7 +301,7 @@ pub fn process_create_vote_account(
1
};
let vote_init = VoteInit {
node_pubkey: *node_pubkey,
node_pubkey: *identity_pubkey,
authorized_voter: authorized_voter.unwrap_or(vote_account_pubkey),
authorized_withdrawer: authorized_withdrawer.unwrap_or(config.keypair.pubkey()),
commission,
@ -313,6 +363,40 @@ pub fn process_vote_authorize(
log_instruction_custom_error::<VoteError>(result)
}
pub fn process_vote_update_validator(
rpc_client: &RpcClient,
config: &CliConfig,
vote_account_pubkey: &Pubkey,
new_identity_pubkey: &Pubkey,
authorized_voter: &Keypair,
) -> ProcessResult {
check_unique_pubkeys(
(vote_account_pubkey, "vote_account_pubkey".to_string()),
(new_identity_pubkey, "new_identity_pubkey".to_string()),
)?;
let (recent_blockhash, fee_calculator) = rpc_client.get_recent_blockhash()?;
let ixs = vec![vote_instruction::update_node(
vote_account_pubkey,
&authorized_voter.pubkey(),
new_identity_pubkey,
)];
let mut tx = Transaction::new_signed_with_payer(
ixs,
Some(&config.keypair.pubkey()),
&[&config.keypair, authorized_voter],
recent_blockhash,
);
check_account_for_fee(
rpc_client,
&config.keypair.pubkey(),
&fee_calculator,
&tx.message,
)?;
let result = rpc_client.send_and_confirm_transaction(&mut tx, &[&config.keypair]);
log_instruction_custom_error::<VoteError>(result)
}
fn get_vote_account(
rpc_client: &RpcClient,
vote_account_pubkey: &Pubkey,
@ -348,7 +432,7 @@ pub fn process_show_vote_account(
"account balance: {}",
build_balance_message(vote_account.lamports, use_lamports_unit, true)
);
println!("node id: {}", vote_state.node_pubkey);
println!("validator identity: {}", vote_state.node_pubkey);
println!("authorized voter: {}", vote_state.authorized_voter);
println!(
"authorized withdrawer: {}",
@ -396,38 +480,42 @@ pub fn process_uptime(
let epoch_schedule = rpc_client.get_epoch_schedule()?;
println!("Node id: {}", vote_state.node_pubkey);
println!("Authorized voter: {}", vote_state.authorized_voter);
println!("validator identity: {}", vote_state.node_pubkey);
println!("authorized voter: {}", vote_state.authorized_voter);
if !vote_state.votes.is_empty() {
println!("Uptime:");
println!("uptime:");
let epoch_credits_vec: Vec<(u64, u64, u64)> = vote_state.epoch_credits().copied().collect();
let epoch_credits = if let Some(x) = span {
epoch_credits_vec.iter().rev().take(x as usize)
let epoch_credits: Vec<(u64, u64, u64)> = if let Some(x) = span {
vote_state
.epoch_credits()
.iter()
.rev()
.take(x as usize)
.cloned()
.collect()
} else {
epoch_credits_vec.iter().rev().take(epoch_credits_vec.len())
vote_state.epoch_credits().iter().rev().cloned().collect()
};
if aggregate {
let (credits_earned, slots_in_epoch, epochs): (u64, u64, u64) =
epoch_credits.fold((0, 0, 0), |acc, (epoch, credits, prev_credits)| {
let credits_earned = credits - prev_credits;
let slots_in_epoch = epoch_schedule.get_slots_in_epoch(*epoch);
(acc.0 + credits_earned, acc.1 + slots_in_epoch, acc.2 + 1)
});
let total_uptime = credits_earned as f64 / slots_in_epoch as f64;
println!("{:.2}% over {} epochs", total_uptime * 100_f64, epochs,);
let (total_credits, total_slots, epochs) =
aggregate_epoch_credits(&epoch_credits, &epoch_schedule);
if total_slots > 0 {
let total_uptime = 100_f64 * total_credits as f64 / total_slots as f64;
println!("{:.2}% over {} epochs", total_uptime, epochs);
} else {
println!("Insufficient voting history available");
}
} else {
for (epoch, credits, prev_credits) in epoch_credits {
let credits_earned = credits - prev_credits;
let slots_in_epoch = epoch_schedule.get_slots_in_epoch(*epoch);
let slots_in_epoch = epoch_schedule.get_slots_in_epoch(epoch);
let uptime = credits_earned as f64 / slots_in_epoch as f64;
println!("- epoch: {} {:.2}% uptime", epoch, uptime * 100_f64,);
}
}
if let Some(x) = span {
if x > epoch_credits_vec.len() as u64 {
if x > vote_state.epoch_credits().len() as u64 {
println!("(span longer than available epochs)");
}
}
@ -453,17 +541,24 @@ mod tests {
let keypair = Keypair::new();
let pubkey = keypair.pubkey();
let pubkey_string = pubkey.to_string();
let keypair2 = Keypair::new();
let pubkey2 = keypair2.pubkey();
let pubkey2_string = pubkey2.to_string();
let test_authorize_voter = test_commands.clone().get_matches_from(vec![
"test",
"vote-authorize-voter",
&pubkey_string,
&pubkey_string,
&pubkey2_string,
]);
assert_eq!(
parse_command(&test_authorize_voter).unwrap(),
CliCommandInfo {
command: CliCommand::VoteAuthorize(pubkey, pubkey, VoteAuthorize::Voter),
command: CliCommand::VoteAuthorize {
vote_account_pubkey: pubkey,
new_authorized_pubkey: pubkey2,
vote_authorize: VoteAuthorize::Voter
},
require_keypair: true
}
);
@ -574,6 +669,27 @@ mod tests {
}
);
let test_update_validator = test_commands.clone().get_matches_from(vec![
"test",
"vote-update-validator",
&pubkey_string,
&pubkey2_string,
&keypair_file,
]);
assert_eq!(
parse_command(&test_update_validator).unwrap(),
CliCommandInfo {
command: CliCommand::VoteUpdateValidator {
vote_account_pubkey: pubkey,
new_identity_pubkey: pubkey2,
authorized_voter: solana_sdk::signature::read_keypair_file(&keypair_file)
.unwrap()
.into(),
},
require_keypair: true
}
);
// Test Uptime Subcommand
let pubkey = Pubkey::new_rand();
let matches = test_commands.clone().get_matches_from(vec![

View File

@ -1,6 +1,6 @@
[package]
name = "solana-client"
version = "0.21.3"
version = "0.21.4"
description = "Solana Client"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -19,10 +19,10 @@ reqwest = { version = "0.9.22", default-features = false, features = ["rustls-tl
serde = "1.0.102"
serde_derive = "1.0.102"
serde_json = "1.0.41"
solana-net-utils = { path = "../net-utils", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-net-utils = { path = "../net-utils", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
[dev-dependencies]
jsonrpc-core = "14.0.3"
jsonrpc-http-server = "14.0.3"
solana-logger = { path = "../logger", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.4" }

View File

@ -97,6 +97,10 @@ pub struct RpcVoteAccountInfo {
/// Whether this account is staked for the current epoch
pub epoch_vote_account: bool,
/// History of how many credits earned by the end of each epoch
/// each tuple is (Epoch, credits, prev_credits)
pub epoch_credits: Vec<(Epoch, u64, u64)>,
/// Most recent slot voted on by this vote account (0 if no votes exist)
pub last_vote: u64,

View File

@ -1,7 +1,7 @@
[package]
name = "solana-core"
description = "Blockchain, Rebuilt for Scale"
version = "0.21.3"
version = "0.21.4"
documentation = "https://docs.rs/solana"
homepage = "https://solana.com/"
readme = "../README.md"
@ -41,25 +41,25 @@ rayon = "1.2.0"
serde = "1.0.102"
serde_derive = "1.0.102"
serde_json = "1.0.41"
solana-budget-program = { path = "../programs/budget", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-chacha-sys = { path = "../chacha-sys", version = "0.21.3" }
solana-client = { path = "../client", version = "0.21.3" }
solana-drone = { path = "../drone", version = "0.21.3" }
solana-budget-program = { path = "../programs/budget", version = "0.21.4" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-chacha-sys = { path = "../chacha-sys", version = "0.21.4" }
solana-client = { path = "../client", version = "0.21.4" }
solana-drone = { path = "../drone", version = "0.21.4" }
ed25519-dalek = "1.0.0-pre.1"
solana-ledger = { path = "../ledger", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-merkle-tree = { path = "../merkle-tree", version = "0.21.3" }
solana-metrics = { path = "../metrics", version = "0.21.3" }
solana-measure = { path = "../measure", version = "0.21.3" }
solana-net-utils = { path = "../net-utils", version = "0.21.3" }
solana-perf = { path = "../perf", version = "0.21.3" }
solana-runtime = { path = "../runtime", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-stake-program = { path = "../programs/stake", version = "0.21.3" }
solana-storage-program = { path = "../programs/storage", version = "0.21.3" }
solana-vote-program = { path = "../programs/vote", version = "0.21.3" }
solana-vote-signer = { path = "../vote-signer", version = "0.21.3" }
solana-ledger = { path = "../ledger", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-merkle-tree = { path = "../merkle-tree", version = "0.21.4" }
solana-metrics = { path = "../metrics", version = "0.21.4" }
solana-measure = { path = "../measure", version = "0.21.4" }
solana-net-utils = { path = "../net-utils", version = "0.21.4" }
solana-perf = { path = "../perf", version = "0.21.4" }
solana-runtime = { path = "../runtime", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
solana-stake-program = { path = "../programs/stake", version = "0.21.4" }
solana-storage-program = { path = "../programs/storage", version = "0.21.4" }
solana-vote-program = { path = "../programs/vote", version = "0.21.4" }
solana-vote-signer = { path = "../vote-signer", version = "0.21.4" }
symlink = "0.1.0"
sys-info = "0.5.8"
tempfile = "3.1.0"
@ -68,7 +68,7 @@ tokio-codec = "0.1"
tokio-fs = "0.1"
tokio-io = "0.1"
untrusted = "0.7.0"
solana-rayon-threadlimit = { path = "../rayon-threadlimit", version = "0.21.3" }
solana-rayon-threadlimit = { path = "../rayon-threadlimit", version = "0.21.4" }
reed-solomon-erasure = { package = "solana-reed-solomon-erasure", version = "4.0.1-3", features = ["simd-accel"] }
[target."cfg(unix)".dependencies]

View File

@ -251,6 +251,7 @@ impl JsonRpcRequestProcessor {
activated_stake: *activated_stake,
commission: vote_state.commission,
root_slot: vote_state.root_slot.unwrap_or(0),
epoch_credits: vote_state.epoch_credits().clone(),
epoch_vote_account,
last_vote,
}
@ -1014,7 +1015,10 @@ pub mod tests {
system_transaction,
transaction::TransactionError,
};
use solana_vote_program::{vote_instruction, vote_state::VoteInit};
use solana_vote_program::{
vote_instruction,
vote_state::{Vote, VoteInit, MAX_LOCKOUT_HISTORY},
};
use std::{
collections::HashMap,
sync::atomic::{AtomicBool, Ordering},
@ -1022,20 +1026,23 @@ pub mod tests {
};
const TEST_MINT_LAMPORTS: u64 = 1_000_000;
const TEST_SLOTS_PER_EPOCH: u64 = 50;
struct RpcHandler {
io: MetaIoHandler<Meta>,
meta: Meta,
bank: Arc<Bank>,
bank_forks: Arc<RwLock<BankForks>>,
blockhash: Hash,
alice: Keypair,
leader_pubkey: Pubkey,
leader_vote_keypair: Keypair,
block_commitment_cache: Arc<RwLock<BlockCommitmentCache>>,
confirmed_block_signatures: Vec<Signature>,
}
fn start_rpc_handler_with_tx(pubkey: &Pubkey) -> RpcHandler {
let (bank_forks, alice) = new_bank_forks();
let (bank_forks, alice, leader_vote_keypair) = new_bank_forks();
let bank = bank_forks.read().unwrap().working_bank();
let commitment_slot0 = BlockCommitment::new([8; MAX_LOCKOUT_HISTORY]);
@ -1077,7 +1084,7 @@ pub mod tests {
let request_processor = Arc::new(RwLock::new(JsonRpcRequestProcessor::new(
JsonRpcConfig::default(),
bank_forks,
bank_forks.clone(),
block_commitment_cache.clone(),
blocktree,
StorageState::default(),
@ -1107,9 +1114,11 @@ pub mod tests {
io,
meta,
bank,
bank_forks,
blockhash,
alice,
leader_pubkey,
leader_vote_keypair,
block_commitment_cache,
confirmed_block_signatures,
}
@ -1120,7 +1129,7 @@ pub mod tests {
let bob_pubkey = Pubkey::new_rand();
let exit = Arc::new(AtomicBool::new(false));
let validator_exit = create_validator_exit(&exit);
let (bank_forks, alice) = new_bank_forks();
let (bank_forks, alice, _) = new_bank_forks();
let bank = bank_forks.read().unwrap().working_bank();
let block_commitment_cache = Arc::new(RwLock::new(BlockCommitmentCache::default()));
let ledger_path = get_tmp_ledger_path!();
@ -1630,20 +1639,23 @@ pub mod tests {
);
}
fn new_bank_forks() -> (Arc<RwLock<BankForks>>, Keypair) {
fn new_bank_forks() -> (Arc<RwLock<BankForks>>, Keypair, Keypair) {
let GenesisConfigInfo {
mut genesis_config,
mint_keypair,
..
voting_keypair,
} = create_genesis_config(TEST_MINT_LAMPORTS);
genesis_config.rent.lamports_per_byte_year = 50;
genesis_config.rent.exemption_threshold = 2.0;
genesis_config.epoch_schedule =
EpochSchedule::custom(TEST_SLOTS_PER_EPOCH, TEST_SLOTS_PER_EPOCH, false);
let bank = Bank::new(&genesis_config);
(
Arc::new(RwLock::new(BankForks::new(bank.slot(), bank))),
mint_keypair,
voting_keypair,
)
}
@ -1905,8 +1917,10 @@ pub mod tests {
let RpcHandler {
io,
meta,
bank,
mut bank,
bank_forks,
alice,
leader_vote_keypair,
..
} = start_rpc_handler_with_tx(&Pubkey::new_rand());
@ -1936,7 +1950,41 @@ pub mod tests {
.expect("process transaction");
assert_eq!(bank.vote_accounts().len(), 2);
let req = format!(r#"{{"jsonrpc":"2.0","id":1,"method":"getVoteAccounts"}}"#);
// Advance bank to the next epoch
for _ in 0..TEST_SLOTS_PER_EPOCH {
bank.freeze();
let instruction = vote_instruction::vote(
&leader_vote_keypair.pubkey(),
&leader_vote_keypair.pubkey(),
Vote {
slots: vec![bank.slot()],
hash: bank.hash(),
},
);
bank = bank_forks.write().unwrap().insert(Bank::new_from_parent(
&bank,
&Pubkey::default(),
bank.slot() + 1,
));
let transaction = Transaction::new_signed_with_payer(
vec![instruction],
Some(&alice.pubkey()),
&[&alice, &leader_vote_keypair],
bank.last_blockhash(),
);
bank.process_transaction(&transaction)
.expect("process transaction");
}
let req = format!(
r#"{{"jsonrpc":"2.0","id":1,"method":"getVoteAccounts","params":{}}}"#,
json!([CommitmentConfig::recent()])
);
let res = io.handle_request_sync(&req, meta.clone());
let result: Value = serde_json::from_str(&res.expect("actual response"))
.expect("actual response deserialization");
@ -1944,12 +1992,19 @@ pub mod tests {
let vote_account_status: RpcVoteAccountStatus =
serde_json::from_value(result["result"].clone()).unwrap();
// The bootstrap leader vote account will be delinquent as it has stake but has never
// voted. The vote account with no stake should not be present.
assert!(vote_account_status.current.is_empty());
assert_eq!(vote_account_status.delinquent.len(), 1);
for vote_account_info in vote_account_status.delinquent {
assert_ne!(vote_account_info.activated_stake, 0);
}
// The vote account with no stake should not be present.
assert!(vote_account_status.delinquent.is_empty());
// The leader vote account should be active and have voting history.
assert_eq!(vote_account_status.current.len(), 1);
let leader_info = &vote_account_status.current[0];
assert_eq!(
leader_info.vote_pubkey,
leader_vote_keypair.pubkey().to_string()
);
assert_ne!(leader_info.activated_stake, 0);
// Subtract one because the last vote always carries over to the next epoch
let expected_credits = TEST_SLOTS_PER_EPOCH - MAX_LOCKOUT_HISTORY as u64 - 1;
assert_eq!(leader_info.epoch_credits, vec![(0, expected_credits, 0)]);
}
}

View File

@ -1,6 +1,6 @@
[package]
name = "solana-crate-features"
version = "0.21.3"
version = "0.21.4"
description = "Solana Crate Features"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-drone"
version = "0.21.3"
version = "0.21.4"
description = "Solana Drone"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -19,10 +19,10 @@ clap = "2.33"
log = "0.4.8"
serde = "1.0.102"
serde_derive = "1.0.102"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-metrics = { path = "../metrics", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-metrics = { path = "../metrics", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
tokio = "0.1"
tokio-codec = "0.1"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-fixed-buf"
version = "0.21.3"
version = "0.21.4"
description = "A fixed-size byte array that supports bincode serde"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-genesis-programs"
version = "0.21.3"
version = "0.21.4"
description = "Solana genesis programs"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -10,16 +10,16 @@ edition = "2018"
[dependencies]
log = { version = "0.4.8" }
solana-bpf-loader-program = { path = "../programs/bpf_loader", version = "0.21.3" }
solana-budget-program = { path = "../programs/budget", version = "0.21.3" }
solana-config-program = { path = "../programs/config", version = "0.21.3" }
solana-exchange-program = { path = "../programs/exchange", version = "0.21.3" }
solana-runtime = { path = "../runtime", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-stake-program = { path = "../programs/stake", version = "0.21.3" }
solana-storage-program = { path = "../programs/storage", version = "0.21.3" }
solana-vest-program = { path = "../programs/vest", version = "0.21.3" }
solana-vote-program = { path = "../programs/vote", version = "0.21.3" }
solana-bpf-loader-program = { path = "../programs/bpf_loader", version = "0.21.4" }
solana-budget-program = { path = "../programs/budget", version = "0.21.4" }
solana-config-program = { path = "../programs/config", version = "0.21.4" }
solana-exchange-program = { path = "../programs/exchange", version = "0.21.4" }
solana-runtime = { path = "../runtime", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
solana-stake-program = { path = "../programs/stake", version = "0.21.4" }
solana-storage-program = { path = "../programs/storage", version = "0.21.4" }
solana-vest-program = { path = "../programs/vest", version = "0.21.4" }
solana-vote-program = { path = "../programs/vote", version = "0.21.4" }
[lib]
crate-type = ["lib"]

View File

@ -3,7 +3,7 @@ authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-genesis"
description = "Blockchain, Rebuilt for Scale"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
@ -16,11 +16,11 @@ serde = "1.0.102"
serde_derive = "1.0.102"
serde_json = "1.0.41"
serde_yaml = "0.8.11"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-genesis-programs = { path = "../genesis-programs", version = "0.21.3" }
solana-ledger = { path = "../ledger", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-stake-program = { path = "../programs/stake", version = "0.21.3" }
solana-storage-program = { path = "../programs/storage", version = "0.21.3" }
solana-vote-program = { path = "../programs/vote", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-genesis-programs = { path = "../genesis-programs", version = "0.21.4" }
solana-ledger = { path = "../ledger", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
solana-stake-program = { path = "../programs/stake", version = "0.21.4" }
solana-storage-program = { path = "../programs/storage", version = "0.21.4" }
solana-vote-program = { path = "../programs/vote", version = "0.21.4" }
tempfile = "3.1.0"

View File

@ -3,19 +3,19 @@ authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-gossip"
description = "Blockchain, Rebuilt for Scale"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
[dependencies]
clap = "2.33.0"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-core = { path = "../core", version = "0.21.3" }
solana-client = { path = "../client", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-net-utils = { path = "../net-utils", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-core = { path = "../core", version = "0.21.4" }
solana-client = { path = "../client", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-net-utils = { path = "../net-utils", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }

View File

@ -3,7 +3,7 @@ authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-install"
description = "The solana cluster software installer"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
@ -26,11 +26,11 @@ reqwest = { version = "0.9.22", default-features = false, features = ["rustls-tl
serde = "1.0.102"
serde_derive = "1.0.102"
serde_yaml = "0.8.11"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-client = { path = "../client", version = "0.21.3" }
solana-config-program = { path = "../programs/config", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-client = { path = "../client", version = "0.21.4" }
solana-config-program = { path = "../programs/config", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
tar = "0.4.26"
tempdir = "0.3.7"
url = "2.1.0"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-keygen"
version = "0.21.3"
version = "0.21.4"
description = "Solana key generation utility"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -14,8 +14,8 @@ clap = "2.33"
dirs = "2.0.2"
num_cpus = "1.11.1"
rpassword = "4.0"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
tiny-bip39 = "0.6.2"
[[bin]]

View File

@ -3,7 +3,7 @@ authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-ledger-tool"
description = "Blockchain, Rebuilt for Scale"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
@ -15,12 +15,12 @@ serde = "1.0.102"
serde_derive = "1.0.102"
serde_json = "1.0.41"
serde_yaml = "0.8.11"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-ledger = { path = "../ledger", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-runtime = { path = "../runtime", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-vote-program = { path = "../programs/vote", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-ledger = { path = "../ledger", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-runtime = { path = "../runtime", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
solana-vote-program = { path = "../programs/vote", version = "0.21.4" }
[dev-dependencies]
assert_cmd = "0.11"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-ledger"
version = "0.21.3"
version = "0.21.4"
description = "Solana ledger"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -29,19 +29,19 @@ rayon = "1.2.0"
reed-solomon-erasure = { package = "solana-reed-solomon-erasure", version = "4.0.1-3", features = ["simd-accel"] }
serde = "1.0.102"
serde_derive = "1.0.102"
solana-client = { path = "../client", version = "0.21.3" }
solana-genesis-programs = { path = "../genesis-programs", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-measure = { path = "../measure", version = "0.21.3" }
solana-merkle-tree = { path = "../merkle-tree", version = "0.21.3" }
solana-metrics = { path = "../metrics", version = "0.21.3" }
solana-perf = { path = "../perf", version = "0.21.3" }
solana-client = { path = "../client", version = "0.21.4" }
solana-genesis-programs = { path = "../genesis-programs", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-measure = { path = "../measure", version = "0.21.4" }
solana-merkle-tree = { path = "../merkle-tree", version = "0.21.4" }
solana-metrics = { path = "../metrics", version = "0.21.4" }
solana-perf = { path = "../perf", version = "0.21.4" }
ed25519-dalek = "1.0.0-pre.1"
solana-rayon-threadlimit = { path = "../rayon-threadlimit", version = "0.21.3" }
solana-runtime = { path = "../runtime", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-stake-program = { path = "../programs/stake", version = "0.21.3" }
solana-vote-program = { path = "../programs/vote", version = "0.21.3" }
solana-rayon-threadlimit = { path = "../rayon-threadlimit", version = "0.21.4" }
solana-runtime = { path = "../runtime", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
solana-stake-program = { path = "../programs/stake", version = "0.21.4" }
solana-vote-program = { path = "../programs/vote", version = "0.21.4" }
sys-info = "0.5.8"
tar = "0.4.26"
tempfile = "3.1.0"
@ -56,7 +56,7 @@ features = ["lz4"]
[dev-dependencies]
assert_matches = "1.3.0"
matches = "0.1.6"
solana-budget-program = { path = "../programs/budget", version = "0.21.3" }
solana-budget-program = { path = "../programs/budget", version = "0.21.4" }
[lib]
crate-type = ["lib"]

View File

@ -716,8 +716,15 @@ fn get_cf_options() -> Options {
// 256 * 8 = 2GB. 6 of these columns should take at most 12GB of RAM
options.set_max_write_buffer_number(8);
options.set_write_buffer_size(MAX_WRITE_BUFFER_SIZE as usize);
options.set_target_file_size_base(MAX_WRITE_BUFFER_SIZE / 10);
options.set_max_bytes_for_level_base(MAX_WRITE_BUFFER_SIZE);
let file_num_compaction_trigger = 4;
// Recommend that this be around the size of level 0. Level 0 estimated size in stable state is
// write_buffer_size * min_write_buffer_number_to_merge * level0_file_num_compaction_trigger
// Source: https://docs.rs/rocksdb/0.6.0/rocksdb/struct.Options.html#method.set_level_zero_file_num_compaction_trigger
let total_size_base = MAX_WRITE_BUFFER_SIZE * file_num_compaction_trigger;
let file_size_base = total_size_base / 10;
options.set_level_zero_file_num_compaction_trigger(file_num_compaction_trigger as i32);
options.set_max_bytes_for_level_base(total_size_base);
options.set_target_file_size_base(file_size_base);
options
}

View File

@ -3,7 +3,7 @@ authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-local-cluster"
description = "Blockchain, Rebuilt for Scale"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
@ -12,23 +12,23 @@ homepage = "https://solana.com/"
itertools = "0.8.1"
log = "0.4.8"
rand = "0.6.5"
solana-config-program = { path = "../programs/config", version = "0.21.3" }
solana-core = { path = "../core", version = "0.21.3" }
solana-client = { path = "../client", version = "0.21.3" }
solana-drone = { path = "../drone", version = "0.21.3" }
solana-exchange-program = { path = "../programs/exchange", version = "0.21.3" }
solana-genesis-programs = { path = "../genesis-programs", version = "0.21.3" }
solana-ledger = { path = "../ledger", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-runtime = { path = "../runtime", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-stake-program = { path = "../programs/stake", version = "0.21.3" }
solana-storage-program = { path = "../programs/storage", version = "0.21.3" }
solana-vest-program = { path = "../programs/vest", version = "0.21.3" }
solana-vote-program = { path = "../programs/vote", version = "0.21.3" }
solana-config-program = { path = "../programs/config", version = "0.21.4" }
solana-core = { path = "../core", version = "0.21.4" }
solana-client = { path = "../client", version = "0.21.4" }
solana-drone = { path = "../drone", version = "0.21.4" }
solana-exchange-program = { path = "../programs/exchange", version = "0.21.4" }
solana-genesis-programs = { path = "../genesis-programs", version = "0.21.4" }
solana-ledger = { path = "../ledger", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-runtime = { path = "../runtime", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
solana-stake-program = { path = "../programs/stake", version = "0.21.4" }
solana-storage-program = { path = "../programs/storage", version = "0.21.4" }
solana-vest-program = { path = "../programs/vest", version = "0.21.4" }
solana-vote-program = { path = "../programs/vote", version = "0.21.4" }
symlink = "0.1.0"
tempfile = "3.1.0"
solana-rayon-threadlimit = { path = "../rayon-threadlimit", version = "0.21.3" }
solana-rayon-threadlimit = { path = "../rayon-threadlimit", version = "0.21.4" }
[dev-dependencies]
serial_test = "0.2.0"

View File

@ -3,7 +3,7 @@ authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-log-analyzer"
description = "The solana cluster network analysis tool"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
@ -17,8 +17,8 @@ semver = "0.9.0"
serde = "1.0.102"
serde_derive = "1.0.102"
serde_json = "1.0.41"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
[[bin]]
name = "solana-log-analyzer"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-logger"
version = "0.21.3"
version = "0.21.4"
description = "Solana Logger"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"

View File

@ -1,7 +1,7 @@
[package]
name = "solana-measure"
description = "Blockchain, Rebuilt for Scale"
version = "0.21.3"
version = "0.21.4"
documentation = "https://docs.rs/solana"
homepage = "https://solana.com/"
readme = "../README.md"
@ -11,4 +11,4 @@ license = "Apache-2.0"
edition = "2018"
[dependencies]
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.4" }

View File

@ -1,6 +1,6 @@
[package]
name = "solana-merkle-tree"
version = "0.21.3"
version = "0.21.4"
description = "Solana Merkle Tree"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -9,7 +9,7 @@ homepage = "https://solana.com/"
edition = "2018"
[dependencies]
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
[dev-dependencies]
hex = "0.4.0"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-metrics"
version = "0.21.3"
version = "0.21.4"
description = "Solana Metrics"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -13,7 +13,7 @@ env_logger = "0.7.1"
lazy_static = "1.4.0"
log = "0.4.8"
reqwest = { version = "0.9.22", default-features = false, features = ["rustls-tls"] }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
sys-info = "0.5.8"
[dev-dependencies]

View File

@ -3,7 +3,7 @@ authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-net-shaper"
description = "The solana cluster network shaping tool"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
@ -16,8 +16,8 @@ semver = "0.9.0"
serde = "1.0.102"
serde_derive = "1.0.102"
serde_json = "1.0.41"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
rand = "0.6.5"
[[bin]]

View File

@ -1,6 +1,6 @@
[package]
name = "solana-net-utils"
version = "0.21.3"
version = "0.21.4"
description = "Solana Network Utilities"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -18,8 +18,8 @@ rand = "0.6.1"
serde = "1.0.102"
serde_derive = "1.0.102"
socket2 = "0.3.11"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
tokio = "0.1"
tokio-codec = "0.1"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-perf"
version = "0.21.3"
version = "0.21.4"
description = "Solana Performance APIs"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -18,11 +18,11 @@ serde_derive = "1.0.102"
dlopen_derive = "0.1.4"
lazy_static = "1.4.0"
log = "0.4.8"
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-rayon-threadlimit = { path = "../rayon-threadlimit", version = "0.21.3" }
solana-budget-program = { path = "../programs/budget", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-metrics = { path = "../metrics", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
solana-rayon-threadlimit = { path = "../rayon-threadlimit", version = "0.21.4" }
solana-budget-program = { path = "../programs/budget", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-metrics = { path = "../metrics", version = "0.21.4" }
[lib]
name = "solana_perf"

View File

@ -1,7 +1,7 @@
[package]
name = "solana-bpf-programs"
description = "Blockchain, Rebuilt for Scale"
version = "0.21.3"
version = "0.21.4"
documentation = "https://docs.rs/solana"
homepage = "https://solana.com/"
readme = "README.md"
@ -22,10 +22,10 @@ walkdir = "2"
bincode = "1.1.4"
byteorder = "1.3.2"
elf = "0.0.10"
solana-bpf-loader-program = { path = "../bpf_loader", version = "0.21.3" }
solana-logger = { path = "../../logger", version = "0.21.3" }
solana-runtime = { path = "../../runtime", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-bpf-loader-program = { path = "../bpf_loader", version = "0.21.4" }
solana-logger = { path = "../../logger", version = "0.21.4" }
solana-runtime = { path = "../../runtime", version = "0.21.4" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
solana_rbpf = "=0.1.19"
[[bench]]

View File

@ -3,7 +3,7 @@
[package]
name = "solana-bpf-rust-128bit"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF test program written in Rust"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,11 +12,11 @@ homepage = "https://solana.com/"
edition = "2018"
[dependencies]
solana-sdk = { path = "../../../../sdk/", version = "0.21.3", default-features = false }
solana-bpf-rust-128bit-dep = { path = "../128bit_dep", version = "0.21.3" }
solana-sdk = { path = "../../../../sdk/", version = "0.21.4", default-features = false }
solana-bpf-rust-128bit-dep = { path = "../128bit_dep", version = "0.21.4" }
[dev_dependencies]
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.3" }
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.4" }
[features]
program = ["solana-sdk/program"]

View File

@ -3,7 +3,7 @@
[package]
name = "solana-bpf-rust-128bit-dep"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF test program written in Rust"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,10 +12,10 @@ homepage = "https://solana.com/"
edition = "2018"
[dependencies]
solana-sdk = { path = "../../../../sdk/", version = "0.21.3", default-features = false }
solana-sdk = { path = "../../../../sdk/", version = "0.21.4", default-features = false }
[dev_dependencies]
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.3" }
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.4" }
[features]
program = ["solana-sdk/program"]

View File

@ -3,7 +3,7 @@
[package]
name = "solana-bpf-rust-alloc"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF test program written in Rust"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,10 +12,10 @@ homepage = "https://solana.com/"
edition = "2018"
[dependencies]
solana-sdk = { path = "../../../../sdk/", version = "0.21.3", default-features = false }
solana-sdk = { path = "../../../../sdk/", version = "0.21.4", default-features = false }
[dev_dependencies]
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.3" }
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.4" }
[features]
program = ["solana-sdk/program"]

View File

@ -3,7 +3,7 @@
[package]
name = "solana-bpf-rust-dep-crate"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF test program written in Rust"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -13,10 +13,10 @@ edition = "2018"
[dependencies]
byteorder = { version = "1", default-features = false }
solana-sdk = { path = "../../../../sdk/", version = "0.21.3", default-features = false }
solana-sdk = { path = "../../../../sdk/", version = "0.21.4", default-features = false }
[dev_dependencies]
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.3" }
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.4" }
[features]
program = ["solana-sdk/program"]

View File

@ -3,7 +3,7 @@
[package]
name = "solana-bpf-rust-external-spend"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF test program written in Rust"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,10 +12,10 @@ homepage = "https://solana.com/"
edition = "2018"
[dependencies]
solana-sdk = { path = "../../../../sdk/", version = "0.21.3", default-features = false }
solana-sdk = { path = "../../../../sdk/", version = "0.21.4", default-features = false }
[dev_dependencies]
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.3" }
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.4" }
[features]
program = ["solana-sdk/program"]

View File

@ -3,7 +3,7 @@
[package]
name = "solana-bpf-rust-iter"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF test program written in Rust"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,10 +12,10 @@ homepage = "https://solana.com/"
edition = "2018"
[dependencies]
solana-sdk = { path = "../../../../sdk/", version = "0.21.3", default-features = false }
solana-sdk = { path = "../../../../sdk/", version = "0.21.4", default-features = false }
[dev_dependencies]
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.3" }
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.4" }
[features]
program = ["solana-sdk/program"]

View File

@ -3,7 +3,7 @@
[package]
name = "solana-bpf-rust-many-args"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF test program written in Rust"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,11 +12,11 @@ homepage = "https://solana.com/"
edition = "2018"
[dependencies]
solana-sdk = { path = "../../../../sdk/", version = "0.21.3", default-features = false }
solana-bpf-rust-many-args-dep = { path = "../many_args_dep", version = "0.21.3" }
solana-sdk = { path = "../../../../sdk/", version = "0.21.4", default-features = false }
solana-bpf-rust-many-args-dep = { path = "../many_args_dep", version = "0.21.4" }
[dev_dependencies]
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.3" }
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.4" }
[features]
program = ["solana-sdk/program"]

View File

@ -3,7 +3,7 @@
[package]
name = "solana-bpf-rust-many-args-dep"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF test program written in Rust"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,10 +12,10 @@ homepage = "https://solana.com/"
edition = "2018"
[dependencies]
solana-sdk = { path = "../../../../sdk/", version = "0.21.3", default-features = false }
solana-sdk = { path = "../../../../sdk/", version = "0.21.4", default-features = false }
[dev_dependencies]
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.3" }
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.4" }
[features]
program = ["solana-sdk/program"]

View File

@ -3,7 +3,7 @@
[package]
name = "solana-bpf-rust-noop"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF test program written in Rust"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,10 +12,10 @@ homepage = "https://solana.com/"
edition = "2018"
[dependencies]
solana-sdk = { path = "../../../../sdk/", version = "0.21.3", default-features = false }
solana-sdk = { path = "../../../../sdk/", version = "0.21.4", default-features = false }
[dev_dependencies]
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.3" }
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.4" }
[features]
program = ["solana-sdk/program"]

View File

@ -3,7 +3,7 @@
[package]
name = "solana-bpf-rust-panic"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF test program written in Rust"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,10 +12,10 @@ homepage = "https://solana.com/"
edition = "2018"
[dependencies]
solana-sdk = { path = "../../../../sdk/", version = "0.21.3", default-features = false }
solana-sdk = { path = "../../../../sdk/", version = "0.21.4", default-features = false }
[dev_dependencies]
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.3" }
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.4" }
[features]
program = ["solana-sdk/program"]

View File

@ -3,7 +3,7 @@
[package]
name = "solana-bpf-rust-param-passing"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF test program written in Rust"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,11 +12,11 @@ homepage = "https://solana.com/"
edition = "2018"
[dependencies]
solana-sdk = { path = "../../../../sdk/", version = "0.21.3", default-features = false }
solana-bpf-rust-param-passing-dep = { path = "../param_passing_dep", version = "0.21.3" }
solana-sdk = { path = "../../../../sdk/", version = "0.21.4", default-features = false }
solana-bpf-rust-param-passing-dep = { path = "../param_passing_dep", version = "0.21.4" }
[dev_dependencies]
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.3" }
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.4" }
[features]
program = ["solana-sdk/program"]

View File

@ -3,7 +3,7 @@
[package]
name = "solana-bpf-rust-param-passing-dep"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF program written in Rust"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,10 +12,10 @@ homepage = "https://solana.com/"
edition = "2018"
[dependencies]
solana-sdk = { path = "../../../../sdk/", version = "0.21.3", default-features = false }
solana-sdk = { path = "../../../../sdk/", version = "0.21.4", default-features = false }
[dev_dependencies]
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.3" }
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.4" }
[features]
program = ["solana-sdk/program"]

View File

@ -3,7 +3,7 @@
[package]
name = "solana-bpf-rust-sysval"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF test program written in Rust"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,10 +12,10 @@ homepage = "https://solana.com/"
edition = "2018"
[dependencies]
solana-sdk = { path = "../../../../sdk/", version = "0.21.3", default-features = false }
solana-sdk = { path = "../../../../sdk/", version = "0.21.4", default-features = false }
[dev_dependencies]
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.3" }
solana-sdk-bpf-test = { path = "../../../../sdk/bpf/rust/test", version = "0.21.4" }
[features]
program = ["solana-sdk/program"]

View File

@ -1,6 +1,6 @@
[package]
name = "solana-bpf-loader-program"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF loader"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -14,8 +14,8 @@ byteorder = "1.3.2"
libc = "0.2.65"
log = "0.4.8"
serde = "1.0.102"
solana-logger = { path = "../../logger", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-logger = { path = "../../logger", version = "0.21.4" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
solana_rbpf = "=0.1.19"
[lib]

View File

@ -1,6 +1,6 @@
[package]
name = "solana-btc-spv-program"
version = "0.21.3"
version = "0.21.4"
description = "Solana Bitcoin spv parsing program"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -16,7 +16,7 @@ num-derive = "0.3"
num-traits = "0.2"
serde = "1.0.102"
serde_derive = "1.0.102"
solana-sdk = { path = "../../sdk", version = "0.21.3"}
solana-sdk = { path = "../../sdk", version = "0.21.4"}
hex = "0.3.2"
[lib]

View File

@ -1,6 +1,6 @@
[package]
name = "btc_spv_bin"
version = "0.21.3"
version = "0.21.4"
description = "Solana Bitcoin spv parsing program"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-budget-program"
version = "0.21.3"
version = "0.21.4"
description = "Solana Budget program"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -16,10 +16,10 @@ num-derive = "0.3"
num-traits = "0.2"
serde = "1.0.102"
serde_derive = "1.0.102"
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
[dev-dependencies]
solana-runtime = { path = "../../runtime", version = "0.21.3" }
solana-runtime = { path = "../../runtime", version = "0.21.4" }
[lib]
crate-type = ["lib", "cdylib"]

View File

@ -1,6 +1,6 @@
[package]
name = "solana-config-program"
version = "0.21.3"
version = "0.21.4"
description = "Solana Config program"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -14,8 +14,8 @@ chrono = { version = "0.4.10", features = ["serde"] }
log = "0.4.8"
serde = "1.0.102"
serde_derive = "1.0.102"
solana-logger = { path = "../../logger", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-logger = { path = "../../logger", version = "0.21.4" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
[lib]
crate-type = ["lib", "cdylib"]

View File

@ -1,6 +1,6 @@
[package]
name = "solana-config-tests"
version = "0.21.3"
version = "0.21.4"
description = "Solana config api tests"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -13,11 +13,11 @@ bincode = "1.2.0"
log = "0.4.8"
serde = "1.0.102"
serde_derive = "1.0.102"
solana-logger = { path = "../../logger", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-config-program = { path = "../config", version = "0.21.3" }
solana-logger = { path = "../../logger", version = "0.21.4" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
solana-config-program = { path = "../config", version = "0.21.4" }
[dev-dependencies]
solana-runtime = { path = "../../runtime", version = "0.21.3" }
solana-runtime = { path = "../../runtime", version = "0.21.4" }
assert_matches = "1.3.0"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-exchange-program"
version = "0.21.3"
version = "0.21.4"
description = "Solana Exchange program"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -13,12 +13,12 @@ bincode = "1.2.0"
log = "0.4.8"
serde = "1.0.102"
serde_derive = "1.0.102"
solana-logger = { path = "../../logger", version = "0.21.3" }
solana-metrics = { path = "../../metrics", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-logger = { path = "../../logger", version = "0.21.4" }
solana-metrics = { path = "../../metrics", version = "0.21.4" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
[dev-dependencies]
solana-runtime = { path = "../../runtime", version = "0.21.3" }
solana-runtime = { path = "../../runtime", version = "0.21.4" }
[lib]
crate-type = ["lib", "cdylib"]

View File

@ -1,6 +1,6 @@
[package]
name = "solana-failure-program"
version = "0.21.3"
version = "0.21.4"
description = "Solana failure program"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -10,10 +10,10 @@ edition = "2018"
[dependencies]
log = "0.4.8"
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
[dev-dependencies]
solana-runtime = { path = "../../runtime", version = "0.21.3" }
solana-runtime = { path = "../../runtime", version = "0.21.4" }
[lib]
crate-type = ["lib", "cdylib"]

View File

@ -1,6 +1,6 @@
[package]
name = "solana-librapay-api"
version = "0.21.3"
version = "0.21.4"
description = "Solana Libra Payment"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -11,10 +11,10 @@ edition = "2018"
[dependencies]
bincode = "1.2.0"
log = "0.4.8"
solana-logger = { path = "../../logger", version = "0.21.3" }
solana-move-loader-program = { path = "../move_loader", version = "0.21.3" }
solana-runtime = { path = "../../runtime", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-logger = { path = "../../logger", version = "0.21.4" }
solana-move-loader-program = { path = "../move_loader", version = "0.21.4" }
solana-runtime = { path = "../../runtime", version = "0.21.4" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
language_e2e_tests = { version = "0.0.1-sol4", package = "solana_libra_language_e2e_tests" }
types = { version = "0.0.1-sol4", package = "solana_libra_types" }

View File

@ -1,6 +1,6 @@
[package]
name = "solana-move-loader-program"
version = "0.21.3"
version = "0.21.4"
description = "Solana Move loader"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -18,8 +18,8 @@ serde = "1.0.102"
serde_bytes = "0.11"
serde_derive = "1.0.102"
serde_json = "1.0.41"
solana-logger = { path = "../../logger", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-logger = { path = "../../logger", version = "0.21.4" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
bytecode_verifier = { version = "0.0.1-sol4", package = "solana_libra_bytecode_verifier" }
canonical_serialization = { version = "0.0.1-sol4", package = "solana_libra_canonical_serialization" }

View File

@ -1,6 +1,6 @@
[package]
name = "solana-noop-program"
version = "0.21.3"
version = "0.21.4"
description = "Solana Noop program"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -10,8 +10,8 @@ edition = "2018"
[dependencies]
log = "0.4.8"
solana-logger = { path = "../../logger", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-logger = { path = "../../logger", version = "0.21.4" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
[lib]
crate-type = ["lib", "cdylib"]

View File

@ -1,6 +1,6 @@
[package]
name = "solana-ownable-api"
version = "0.21.3"
version = "0.21.4"
description = "ownable program API"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,12 +12,12 @@ edition = "2018"
bincode = "1.2.0"
serde = "1.0.102"
serde_derive = "1.0.102"
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
num-derive = "0.3"
num-traits = "0.2"
[dev-dependencies]
solana-runtime = { path = "../../runtime", version = "0.21.3" }
solana-runtime = { path = "../../runtime", version = "0.21.4" }
[lib]
crate-type = ["lib"]

View File

@ -1,6 +1,6 @@
[package]
name = "solana-stake-program"
version = "0.21.3"
version = "0.21.4"
description = "Solana Stake program"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -16,11 +16,11 @@ num-traits = "0.2"
rand = "0.6.5"
serde = "1.0.102"
serde_derive = "1.0.102"
solana-logger = { path = "../../logger", version = "0.21.3" }
solana-metrics = { path = "../../metrics", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-vote-program = { path = "../vote", version = "0.21.3" }
solana-config-program = { path = "../config", version = "0.21.3" }
solana-logger = { path = "../../logger", version = "0.21.4" }
solana-metrics = { path = "../../metrics", version = "0.21.4" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
solana-vote-program = { path = "../vote", version = "0.21.4" }
solana-config-program = { path = "../config", version = "0.21.4" }
[lib]
crate-type = ["lib", "cdylib"]

View File

@ -1,6 +1,6 @@
[package]
name = "solana-stake-tests"
version = "0.21.3"
version = "0.21.4"
description = "Solana stake tests"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -10,11 +10,11 @@ edition = "2018"
[dependencies]
log = "0.4.8"
solana-logger = { path = "../../logger", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-stake-program = { path = "../stake", version = "0.21.3" }
solana-vote-program = { path = "../vote", version = "0.21.3" }
solana-logger = { path = "../../logger", version = "0.21.4" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
solana-stake-program = { path = "../stake", version = "0.21.4" }
solana-vote-program = { path = "../vote", version = "0.21.4" }
[dev-dependencies]
solana-runtime = { path = "../../runtime", version = "0.21.3" }
solana-runtime = { path = "../../runtime", version = "0.21.4" }
assert_matches = "1.3.0"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-storage-program"
version = "0.21.3"
version = "0.21.4"
description = "Solana Storage program"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -16,8 +16,8 @@ num-derive = "0.3"
num-traits = "0.2"
serde = "1.0.102"
serde_derive = "1.0.102"
solana-logger = { path = "../../logger", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-logger = { path = "../../logger", version = "0.21.4" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
[lib]
crate-type = ["lib", "cdylib"]

View File

@ -1,6 +1,6 @@
[package]
name = "solana-storage-tests"
version = "0.21.3"
version = "0.21.4"
description = "Solana storage tests"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -10,11 +10,11 @@ edition = "2018"
[dependencies]
log = "0.4.8"
solana-logger = { path = "../../logger", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-storage-program = { path = "../storage", version = "0.21.3" }
solana-logger = { path = "../../logger", version = "0.21.4" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
solana-storage-program = { path = "../storage", version = "0.21.4" }
[dev-dependencies]
solana-runtime = { path = "../../runtime", version = "0.21.3" }
solana-runtime = { path = "../../runtime", version = "0.21.4" }
assert_matches = "1.3.0"
bincode = "1.2.0"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-vest-program"
version = "0.21.3"
version = "0.21.4"
description = "Solana Vest program"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -16,11 +16,11 @@ num-derive = "0.2"
num-traits = "0.2"
serde = "1.0.102"
serde_derive = "1.0.102"
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-config-program = { path = "../config", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
solana-config-program = { path = "../config", version = "0.21.4" }
[dev-dependencies]
solana-runtime = { path = "../../runtime", version = "0.21.3" }
solana-runtime = { path = "../../runtime", version = "0.21.4" }
[lib]
crate-type = ["lib"]

View File

@ -1,6 +1,6 @@
[package]
name = "solana-vote-program"
version = "0.21.3"
version = "0.21.4"
description = "Solana Vote program"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -15,9 +15,9 @@ num-derive = "0.3"
num-traits = "0.2"
serde = "1.0.102"
serde_derive = "1.0.102"
solana-logger = { path = "../../logger", version = "0.21.3" }
solana-metrics = { path = "../../metrics", version = "0.21.3" }
solana-sdk = { path = "../../sdk", version = "0.21.3" }
solana-logger = { path = "../../logger", version = "0.21.4" }
solana-metrics = { path = "../../metrics", version = "0.21.4" }
solana-sdk = { path = "../../sdk", version = "0.21.4" }
[lib]
crate-type = ["lib", "cdylib"]

View File

@ -63,7 +63,7 @@ pub enum VoteInstruction {
/// Withdraw some amount of funds
Withdraw(u64),
/// Update the vote account's node id
/// Update the vote account's validator identity (node id)
UpdateNode(Pubkey),
}

View File

@ -315,8 +315,8 @@ impl VoteState {
/// Each tuple of (Epoch, u64, u64) is read as (epoch, credits, prev_credits), where
/// credits for each epoch is credits - prev_credits; while redundant this makes
/// calculating rewards over partial epochs nice and simple
pub fn epoch_credits(&self) -> impl Iterator<Item = &(Epoch, u64, u64)> {
self.epoch_credits.iter()
pub fn epoch_credits(&self) -> &Vec<(Epoch, u64, u64)> {
&self.epoch_credits
}
fn pop_expired_votes(&mut self, slot: Slot) {
@ -1194,13 +1194,7 @@ mod tests {
let mut vote_state = VoteState::default();
assert_eq!(vote_state.credits(), 0);
assert_eq!(
vote_state
.epoch_credits()
.cloned()
.collect::<Vec<(Epoch, u64, u64)>>(),
vec![]
);
assert_eq!(vote_state.epoch_credits().clone(), vec![]);
let mut expected = vec![];
let mut credits = 0;
@ -1218,45 +1212,18 @@ mod tests {
}
assert_eq!(vote_state.credits(), credits);
assert_eq!(
vote_state
.epoch_credits()
.cloned()
.collect::<Vec<(Epoch, u64, u64)>>(),
expected
);
assert_eq!(vote_state.epoch_credits().clone(), expected);
}
#[test]
fn test_vote_state_epoch0_no_credits() {
let mut vote_state = VoteState::default();
assert_eq!(
vote_state
.epoch_credits()
.cloned()
.collect::<Vec<(Epoch, u64, u64)>>()
.len(),
0
);
assert_eq!(vote_state.epoch_credits().len(), 0);
vote_state.increment_credits(1);
assert_eq!(
vote_state
.epoch_credits()
.cloned()
.collect::<Vec<(Epoch, u64, u64)>>()
.len(),
0
);
assert_eq!(vote_state.epoch_credits().len(), 0);
vote_state.increment_credits(2);
assert_eq!(
vote_state
.epoch_credits()
.cloned()
.collect::<Vec<(Epoch, u64, u64)>>()
.len(),
1
);
assert_eq!(vote_state.epoch_credits().len(), 1);
}
}

View File

@ -1,6 +1,6 @@
[package]
name = "solana-rayon-threadlimit"
version = "0.21.3"
version = "0.21.4"
description = "solana-rayon-threadlimit"
homepage = "https://solana.com/"
readme = "../README.md"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-runtime"
version = "0.21.3"
version = "0.21.4"
description = "Solana runtime"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -24,17 +24,17 @@ rayon = "1.2.0"
serde = { version = "1.0.102", features = ["rc"] }
serde_derive = "1.0.102"
serde_json = "1.0.41"
solana-logger = { path = "../logger", version = "0.21.3" }
solana-measure = { path = "../measure", version = "0.21.3" }
solana-metrics = { path = "../metrics", version = "0.21.3" }
solana-bpf-loader-program = { path = "../programs/bpf_loader", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-stake-program = { path = "../programs/stake", version = "0.21.3" }
solana-storage-program = { path = "../programs/storage", version = "0.21.3" }
solana-vote-program = { path = "../programs/vote", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-measure = { path = "../measure", version = "0.21.4" }
solana-metrics = { path = "../metrics", version = "0.21.4" }
solana-bpf-loader-program = { path = "../programs/bpf_loader", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
solana-stake-program = { path = "../programs/stake", version = "0.21.4" }
solana-storage-program = { path = "../programs/storage", version = "0.21.4" }
solana-vote-program = { path = "../programs/vote", version = "0.21.4" }
sys-info = "0.5.8"
tempfile = "3.1.0"
solana-rayon-threadlimit = { path = "../rayon-threadlimit", version = "0.21.3" }
solana-rayon-threadlimit = { path = "../rayon-threadlimit", version = "0.21.4" }
itertools = "0.8.2"
[lib]
@ -42,4 +42,4 @@ crate-type = ["lib"]
name = "solana_runtime"
[dev-dependencies]
solana-noop-program = { path = "../programs/noop", version = "0.21.3" }
solana-noop-program = { path = "../programs/noop", version = "0.21.4" }

View File

@ -3,7 +3,7 @@ authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-scripts"
description = "Blockchain, Rebuilt for Scale"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-sdk-c"
version = "0.21.3"
version = "0.21.4"
description = "Solana SDK C"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -18,7 +18,7 @@ bs58 = "0.3.0"
libc = "0.2.65"
rand_chacha = "0.1.1"
rand_core = { version = ">=0.2, <0.4", default-features = false }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
ed25519-dalek = "1.0.0-pre.1"
sha2 = "0.8.0"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-sdk"
version = "0.21.3"
version = "0.21.4"
description = "Solana SDK"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -46,8 +46,8 @@ serde_derive = "1.0.102"
serde_json = { version = "1.0.41", optional = true }
sha2 = "0.8.0"
ed25519-dalek = { version = "1.0.0-pre.1", optional = true }
solana-crate-features = { path = "../crate-features", version = "0.21.3", optional = true }
solana-logger = { path = "../logger", version = "0.21.3", optional = true }
solana-crate-features = { path = "../crate-features", version = "0.21.4", optional = true }
solana-logger = { path = "../logger", version = "0.21.4", optional = true }
solana-sdk-macro = { path = "macro" }
[dev-dependencies]

View File

@ -1,6 +1,6 @@
[package]
name = "solana-sdk-bpf-test"
version = "0.21.3"
version = "0.21.4"
description = "Solana BPF SDK test utilities"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"

View File

@ -5,8 +5,15 @@ cd "$(dirname "$0")"/../..
eval "$(ci/channel-info.sh)"
source ci/rust-version.sh
if [[ -z $CHANNEL ]]; then
echo Unable to determine channel to publish into, exiting.
CHANNEL_OR_TAG=
if [[ -n "$CI_TAG" ]]; then
CHANNEL_OR_TAG=$CI_TAG
else
CHANNEL_OR_TAG=$CHANNEL
fi
if [[ -z $CHANNEL_OR_TAG ]]; then
echo Unable to determine channel or tag to publish into, exiting.
echo "^^^ +++"
exit 0
fi
@ -18,7 +25,7 @@ rm -rf usr/
cp -f ../../run.sh usr/bin/solana-run.sh
docker build -t solanalabs/solana:"$CHANNEL" .
docker build -t solanalabs/solana:"$CHANNEL_OR_TAG" .
maybeEcho=
if [[ -z $CI ]]; then
@ -32,4 +39,4 @@ else
fi
)
fi
$maybeEcho docker push solanalabs/solana:"$CHANNEL"
$maybeEcho docker push solanalabs/solana:"$CHANNEL_OR_TAG"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-sdk-macro"
version = "0.21.3"
version = "0.21.4"
description = "Solana SDK Macro"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"

View File

@ -1,6 +1,6 @@
[package]
name = "solana-upload-perf"
version = "0.21.3"
version = "0.21.4"
description = "Metrics Upload Utility"
authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana"
@ -12,7 +12,7 @@ publish = false
[dependencies]
log = "0.4.8"
serde_json = "1.0.41"
solana-metrics = { path = "../metrics", version = "0.21.3" }
solana-metrics = { path = "../metrics", version = "0.21.4" }
[[bin]]
name = "solana-upload-perf"

View File

@ -3,7 +3,7 @@ authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-validator"
description = "Blockchain, Rebuilt for Scale"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
@ -17,19 +17,19 @@ log = "0.4.8"
indicatif = "0.13.0"
reqwest = { version = "0.9.22", default-features = false }
serde_json = "1.0.41"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-client = { path = "../client", version = "0.21.3" }
solana-core = { path = "../core", version = "0.21.3" }
solana-drone = { path = "../drone", version = "0.21.3" }
solana-ledger = { path = "../ledger", version = "0.21.3" }
solana-logger = { path = "../logger", version = "0.21.3" }
solana-perf = { path = "../perf", version = "0.21.3" }
solana-metrics = { path = "../metrics", version = "0.21.3" }
solana-net-utils = { path = "../net-utils", version = "0.21.3" }
solana-runtime = { path = "../runtime", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-vote-program = { path = "../programs/vote", version = "0.21.3" }
solana-vote-signer = { path = "../vote-signer", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-client = { path = "../client", version = "0.21.4" }
solana-core = { path = "../core", version = "0.21.4" }
solana-drone = { path = "../drone", version = "0.21.4" }
solana-ledger = { path = "../ledger", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-perf = { path = "../perf", version = "0.21.4" }
solana-metrics = { path = "../metrics", version = "0.21.4" }
solana-net-utils = { path = "../net-utils", version = "0.21.4" }
solana-runtime = { path = "../runtime", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
solana-vote-program = { path = "../programs/vote", version = "0.21.4" }
solana-vote-signer = { path = "../vote-signer", version = "0.21.4" }
tar = "0.4.26"
tempfile = "3.1.0"

View File

@ -3,7 +3,7 @@ authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-vote-signer"
description = "Solana Vote Signing Service"
version = "0.21.3"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
@ -17,9 +17,9 @@ jsonrpc-http-server = "14.0.3"
log = "0.4.8"
serde = "1.0.102"
serde_json = "1.0.41"
solana-clap-utils = { path = "../clap-utils", version = "0.21.3" }
solana-metrics = { path = "../metrics", version = "0.21.3" }
solana-sdk = { path = "../sdk", version = "0.21.3" }
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-metrics = { path = "../metrics", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
[lib]
crate-type = ["lib"]

2
watchtower/.gitignore vendored Normal file
View File

@ -0,0 +1,2 @@
/target/
/farf/

23
watchtower/Cargo.toml Normal file
View File

@ -0,0 +1,23 @@
[package]
authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018"
name = "solana-watchtower"
description = "Blockchain, Rebuilt for Scale"
version = "0.21.4"
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
[dependencies]
clap = "2.33.0"
log = "0.4.8"
solana-clap-utils = { path = "../clap-utils", version = "0.21.4" }
solana-client = { path = "../client", version = "0.21.4" }
solana-logger = { path = "../logger", version = "0.21.4" }
solana-metrics = { path = "../metrics", version = "0.21.4" }
solana-sdk = { path = "../sdk", version = "0.21.4" }
[[bin]]
name = "solana-watchtower"
path = "src/main.rs"

16
watchtower/README.md Normal file
View File

@ -0,0 +1,16 @@
The `solana-watchtower` program is used to monitor the health of a cluster. It
periodically polls the cluster over an RPC API to confirm that the transaction
count is advancing, new blockhashes are available, and no validators are
delinquent. Results are reported as InfluxDB metrics.
### Metrics
#### `watchtower-sanity`
On every iteration this data point will be emitted indicating the overall result
using a boolean `ok` field.
#### `watchtower-sanity-failure`
On failure this data point contains details about the specific test that failed via
the following fields:
* `test`: name of the sanity test that failed
* `err`: exact sanity failure message

116
watchtower/src/main.rs Normal file
View File

@ -0,0 +1,116 @@
//! A command-line executable for monitoring the health of a cluster
use clap::{crate_description, crate_name, value_t_or_exit, App, Arg};
use log::*;
use solana_clap_utils::input_validators::is_url;
use solana_client::rpc_client::RpcClient;
use solana_metrics::{datapoint_error, datapoint_info};
use std::{error, io, thread::sleep, time::Duration};
fn main() -> Result<(), Box<dyn error::Error>> {
let matches = App::new(crate_name!())
.about(crate_description!())
.version(solana_clap_utils::version!())
.arg(
Arg::with_name("json_rpc_url")
.long("url")
.value_name("URL")
.takes_value(true)
.required(true)
.validator(is_url)
.help("JSON RPC URL for the cluster"),
)
.arg(
Arg::with_name("interval")
.long("interval")
.value_name("SECONDS")
.takes_value(true)
.default_value("60")
.help("Wait interval seconds between checking the cluster"),
)
.get_matches();
let interval = Duration::from_secs(value_t_or_exit!(matches, "interval", u64));
let json_rpc_url = value_t_or_exit!(matches, "json_rpc_url", String);
solana_logger::setup_with_filter("solana=info");
solana_metrics::set_panic_hook("watchtower");
let rpc_client = RpcClient::new(json_rpc_url.to_string());
let mut last_transaction_count = 0;
loop {
let ok = rpc_client
.get_transaction_count()
.and_then(|transaction_count| {
info!("Current transaction count: {}", transaction_count);
if transaction_count > last_transaction_count {
last_transaction_count = transaction_count;
Ok(true)
} else {
Err(io::Error::new(
io::ErrorKind::Other,
format!(
"Transaction count is not advancing: {} <= {}",
transaction_count, last_transaction_count
),
))
}
})
.unwrap_or_else(|err| {
datapoint_error!(
"watchtower-sanity-failure",
("test", "transaction-count", String),
("err", err.to_string(), String)
);
false
})
&& rpc_client
.get_recent_blockhash()
.and_then(|(blockhash, _fee_calculator)| {
info!("Current blockhash: {}", blockhash);
rpc_client.get_new_blockhash(&blockhash)
})
.and_then(|(blockhash, _fee_calculator)| {
info!("New blockhash: {}", blockhash);
Ok(true)
})
.unwrap_or_else(|err| {
datapoint_error!(
"watchtower-sanity-failure",
("test", "blockhash", String),
("err", err.to_string(), String)
);
false
})
&& rpc_client
.get_vote_accounts()
.and_then(|vote_accounts| {
info!("Current validator count: {}", vote_accounts.current.len());
info!(
"Delinquent validator count: {}",
vote_accounts.delinquent.len()
);
if vote_accounts.delinquent.is_empty() {
Ok(true)
} else {
Err(io::Error::new(
io::ErrorKind::Other,
format!("{} delinquent validators", vote_accounts.delinquent.len()),
))
}
})
.unwrap_or_else(|err| {
datapoint_error!(
"watchtower-sanity-failure",
("test", "delinquent-validators", String),
("err", err.to_string(), String)
);
false
});
datapoint_info!("watchtower-sanity", ("ok", ok, bool));
sleep(interval);
}
}