Compare commits

...

44 Commits

Author SHA1 Message Date
81f8368bba testnet-deploy.sh updates 2019-04-26 21:22:02 -07:00
297166e550 v0.11: testnet-deploy updates 2019-04-26 21:21:54 -07:00
7fff610cae Checkout testnet scripts from tip to upstream/0.11 (#4016)
* Checkout testnet scripts from tip to upstream/0.11

* Add back NO_VALIDATOR_SANITY to testnet sanity
2019-04-26 14:53:59 -06:00
5f3bf853c6 Only check CHANNEL_BRANCH if TESTNET_TAG is not set from buildkite (#3701) 2019-04-09 15:04:34 -07:00
fc34c1370b Change GCP region for testnet-perf to us-west1-b 2019-03-18 13:22:26 -07:00
09410fd5c5 Update Cargo.lock for v0.11.1 2019-03-14 17:47:10 -06:00
bfff18ac70 Fix typo in wallet 2019-03-14 17:47:10 -06:00
7239efe1e7 Keep stable dashboard on stable channel at all times 2019-03-11 16:19:51 -07:00
334a7d9502 Move testnet/testnet-perf to the stable channel 2019-03-11 16:16:11 -07:00
bc2d37015d Switch testnet-perf to us-west1-a 2019-02-27 19:29:04 -08:00
d3fcedb179 Switch testnet-perf to us-west1-a 2019-02-27 19:25:02 -08:00
f1a77abffb Fix the custom programs command in net.sh 2019-02-19 13:56:06 -07:00
7acd771271 Add missing cloud_Initilize (due to bad merge of a907ed2) 2019-02-19 09:53:16 -08:00
9c2d58660b Switch to upstream AMIs for non-CUDA EC2 testnets 2019-02-18 18:53:27 -08:00
a907ed2e33 Generate ec2 security group programmatically 2019-02-18 18:53:13 -08:00
9d3c426510 Add optional deploy of custom programs 2019-02-18 11:02:03 -08:00
b0bcc8355f User-initiated builds now select the correct channel 2019-01-22 14:24:55 -08:00
cf99e626c8 Use beta channel for stable dashboard once a beta tag exists 2019-01-22 12:23:03 -08:00
6db61759e0 Failure to write a datapoint should not be fatal 2019-01-16 10:16:20 -08:00
aae08bdae3 Update book URL 2019-01-12 11:36:27 -08:00
5ff22921eb Publish book from both the edge and beta channels 2019-01-12 11:36:27 -08:00
10012be03e Remove channel duplication 2019-01-12 11:36:27 -08:00
17def9fbf5 Avoid -d arg conflict
-D is now "delete"
-d is now "disk type"
2019-01-09 16:59:44 -07:00
b5a03d011f Remove |cargo package| sanity step
Unfortunately due to our multi-crate repo, as soon as
|./scripts/increment-cargo-version.sh| is run after a release, |cargo
package| will fail for crates that depend on other in-tree crates, as
the new crate version has not yet been published to crates.io.
For now this means that we need to continue flying blind and be prepared
to deal with minor publishing issues on each new release.
2019-01-09 09:57:05 -08:00
2d39c4257a v0.11.1 2019-01-08 08:31:39 -08:00
8fb86c9fa7 Add missing description field, required for crate publishing 2019-01-07 23:03:13 -08:00
fc623756df Add fullnode-config crate 2019-01-07 23:03:13 -08:00
d92bd0de27 Use docker rust docker image to avoid rocksdb build errors 2019-01-07 23:03:13 -08:00
c818c20399 package or publish. Also package on branch builds 2019-01-07 23:03:13 -08:00
ed41547f64 Double publish crate timeout 2019-01-07 20:46:42 -08:00
36398bc3f3 Only check TRIGGERED_BUILDKITE_TAG 2019-01-07 19:53:52 -08:00
fa0e1ad356 Don't turn the build red if channel cannot be figured (eg, building a tag) 2019-01-07 19:53:39 -08:00
f56c5dacca Remove some metrics datapoint, as it was causing excessive logging (#2287) (#2291)
- 100 nodes test was bringing down the influx DB server
2019-01-03 10:42:13 -08:00
80e0da132a Rename getConfirmation -> getConfirmationTime 2018-12-22 13:11:10 -08:00
f89debdfa6 Document getConfirmationTime 2018-12-22 13:11:10 -08:00
16f7e46fce Ignore error while enabling nvidia persistence mode (#2265) 2018-12-21 12:47:45 -08:00
3a039c8007 Load nvidia drivers on node startup (#2263) (#2264)
* Load nvidia drivers on node startup

* added new script to enable nvidia driver persistent mode

* remove set -ex
2018-12-21 11:58:06 -08:00
56d5324837 Use CUDA for testnet automation performance calculations (#2259) (#2261) 2018-12-21 05:14:08 -08:00
d3bf0fc707 Use SSD for testnet automation (#2257) (#2258) 2018-12-21 04:52:00 -08:00
f9d8a1d6c0 Rename finality to confirmation (#2250)
* Rename finality to confirmation

* fix cargo fmt errors
2018-12-20 16:03:56 -08:00
70559253ee Use newer votes to calculate confirmation time (#2247) 2018-12-20 16:03:56 -08:00
9c61abe468 Reduce ticks per block to increase voting frequency (#2242) 2018-12-20 16:03:56 -08:00
970954ac3b Stable dashboard can now actually come from the stable channel 2018-12-20 08:06:02 -08:00
39d821ead8 Select correct branch for {testnet,-perf} when using a stable channel tag 2018-12-19 17:47:18 -08:00
62 changed files with 1168 additions and 609 deletions

180
Cargo.lock generated
View File

@ -1715,7 +1715,7 @@ dependencies = [
[[package]] [[package]]
name = "solana" name = "solana"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", "bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"bs58 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", "bs58 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1739,19 +1739,19 @@ dependencies = [
"serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-bpfloader 0.11.0", "solana-bpfloader 0.11.1",
"solana-drone 0.11.0", "solana-drone 0.11.1",
"solana-jsonrpc-core 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", "solana-jsonrpc-core 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-jsonrpc-http-server 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", "solana-jsonrpc-http-server 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-jsonrpc-macros 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", "solana-jsonrpc-macros 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-jsonrpc-pubsub 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", "solana-jsonrpc-pubsub 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-jsonrpc-ws-server 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", "solana-jsonrpc-ws-server 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-logger 0.11.0", "solana-logger 0.11.1",
"solana-metrics 0.11.0", "solana-metrics 0.11.1",
"solana-native-loader 0.11.0", "solana-native-loader 0.11.1",
"solana-netutil 0.11.0", "solana-netutil 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
"solana-system-program 0.11.0", "solana-system-program 0.11.1",
"tokio 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)", "tokio 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)",
"tokio-codec 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", "tokio-codec 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"untrusted 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)", "untrusted 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1759,39 +1759,39 @@ dependencies = [
[[package]] [[package]]
name = "solana-bench-streamer" name = "solana-bench-streamer"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)", "clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)",
"solana 0.11.0", "solana 0.11.1",
"solana-logger 0.11.0", "solana-logger 0.11.1",
"solana-netutil 0.11.0", "solana-netutil 0.11.1",
] ]
[[package]] [[package]]
name = "solana-bench-tps" name = "solana-bench-tps"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)", "clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)",
"rayon 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)", "rayon 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
"solana 0.11.0", "solana 0.11.1",
"solana-drone 0.11.0", "solana-drone 0.11.1",
"solana-logger 0.11.0", "solana-logger 0.11.1",
"solana-metrics 0.11.0", "solana-metrics 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-bpf-noop" name = "solana-bpf-noop"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"rbpf 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "rbpf 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-bpfloader" name = "solana-bpfloader"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", "bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"byteorder 1.2.7 (registry+https://github.com/rust-lang/crates.io-index)", "byteorder 1.2.7 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1799,27 +1799,27 @@ dependencies = [
"libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)", "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
"serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-logger 0.11.0", "solana-logger 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
"solana_rbpf 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", "solana_rbpf 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
] ]
[[package]] [[package]]
name = "solana-budget-program" name = "solana-budget-program"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", "bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"chrono 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "chrono 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
"serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-logger 0.11.0", "solana-logger 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-drone" name = "solana-drone"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", "bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"byteorder 1.2.7 (registry+https://github.com/rust-lang/crates.io-index)", "byteorder 1.2.7 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1828,43 +1828,43 @@ dependencies = [
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
"serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-metrics 0.11.0", "solana-metrics 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
"tokio 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)", "tokio 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)",
"tokio-codec 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", "tokio-codec 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
] ]
[[package]] [[package]]
name = "solana-erc20" name = "solana-erc20"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", "bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
"serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-logger 0.11.0", "solana-logger 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-fullnode" name = "solana-fullnode"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)", "clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
"solana 0.11.0", "solana 0.11.1",
"solana-drone 0.11.0", "solana-drone 0.11.1",
"solana-fullnode-config 0.11.0", "solana-fullnode-config 0.11.1",
"solana-logger 0.11.0", "solana-logger 0.11.1",
"solana-metrics 0.11.0", "solana-metrics 0.11.1",
"solana-netutil 0.11.0", "solana-netutil 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-fullnode-config" name = "solana-fullnode-config"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)", "clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)",
"dirs 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)", "dirs 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1872,19 +1872,19 @@ dependencies = [
"serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-netutil 0.11.0", "solana-netutil 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
"untrusted 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)", "untrusted 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
] ]
[[package]] [[package]]
name = "solana-genesis" name = "solana-genesis"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)", "clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
"solana 0.11.0", "solana 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
@ -2025,70 +2025,70 @@ dependencies = [
[[package]] [[package]]
name = "solana-keygen" name = "solana-keygen"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)", "clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)",
"dirs 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)", "dirs 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-ledger-tool" name = "solana-ledger-tool"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)", "clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
"solana 0.11.0", "solana 0.11.1",
"solana-logger 0.11.0", "solana-logger 0.11.1",
] ]
[[package]] [[package]]
name = "solana-logger" name = "solana-logger"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"env_logger 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)", "env_logger 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
] ]
[[package]] [[package]]
name = "solana-lualoader" name = "solana-lualoader"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", "bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
"rlua 0.15.3 (registry+https://github.com/rust-lang/crates.io-index)", "rlua 0.15.3 (registry+https://github.com/rust-lang/crates.io-index)",
"serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-logger 0.11.0", "solana-logger 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-metrics" name = "solana-metrics"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"influx_db_client 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", "influx_db_client 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
"lazy_static 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)", "lazy_static 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
"rand 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "rand 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
"reqwest 0.9.5 (registry+https://github.com/rust-lang/crates.io-index)", "reqwest 0.9.5 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
"sys-info 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)", "sys-info 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
] ]
[[package]] [[package]]
name = "solana-native-loader" name = "solana-native-loader"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", "bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)", "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
"libloading 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", "libloading 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-netutil" name = "solana-netutil"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"ipnetwork 0.12.8 (registry+https://github.com/rust-lang/crates.io-index)", "ipnetwork 0.12.8 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
@ -2097,33 +2097,33 @@ dependencies = [
"rand 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "rand 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
"reqwest 0.9.5 (registry+https://github.com/rust-lang/crates.io-index)", "reqwest 0.9.5 (registry+https://github.com/rust-lang/crates.io-index)",
"socket2 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)", "socket2 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-logger 0.11.0", "solana-logger 0.11.1",
] ]
[[package]] [[package]]
name = "solana-noop" name = "solana-noop"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-logger 0.11.0", "solana-logger 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-replicator" name = "solana-replicator"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)", "clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
"solana 0.11.0", "solana 0.11.1",
"solana-fullnode-config 0.11.0", "solana-fullnode-config 0.11.1",
"solana-logger 0.11.0", "solana-logger 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-sdk" name = "solana-sdk"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", "bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"bs58 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", "bs58 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
@ -2141,50 +2141,50 @@ dependencies = [
[[package]] [[package]]
name = "solana-storage-program" name = "solana-storage-program"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", "bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
"serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-logger 0.11.0", "solana-logger 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-system-program" name = "solana-system-program"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", "bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
"serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-upload-perf" name = "solana-upload-perf"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-metrics 0.11.0", "solana-metrics 0.11.1",
] ]
[[package]] [[package]]
name = "solana-vote-program" name = "solana-vote-program"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", "bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)", "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
"serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)", "serde_derive 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-logger 0.11.0", "solana-logger 0.11.1",
"solana-metrics 0.11.0", "solana-metrics 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-vote-signer" name = "solana-vote-signer"
version = "0.0.1" version = "0.11.1"
dependencies = [ dependencies = [
"bs58 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", "bs58 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
"clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)", "clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)",
@ -2193,13 +2193,13 @@ dependencies = [
"solana-jsonrpc-core 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)", "solana-jsonrpc-core 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-jsonrpc-http-server 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)", "solana-jsonrpc-http-server 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-jsonrpc-macros 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)", "solana-jsonrpc-macros 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-metrics 0.11.0", "solana-metrics 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]
name = "solana-wallet" name = "solana-wallet"
version = "0.11.0" version = "0.11.1"
dependencies = [ dependencies = [
"bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)", "bincode 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"bs58 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", "bs58 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
@ -2207,10 +2207,10 @@ dependencies = [
"clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)", "clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)",
"dirs 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)", "dirs 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
"solana 0.11.0", "solana 0.11.1",
"solana-drone 0.11.0", "solana-drone 0.11.1",
"solana-logger 0.11.0", "solana-logger 0.11.1",
"solana-sdk 0.11.0", "solana-sdk 0.11.1",
] ]
[[package]] [[package]]

View File

@ -1,7 +1,7 @@
[package] [package]
name = "solana" name = "solana"
description = "Blockchain, Rebuilt for Scale" description = "Blockchain, Rebuilt for Scale"
version = "0.11.0" version = "0.11.1"
documentation = "https://docs.rs/solana" documentation = "https://docs.rs/solana"
homepage = "https://solana.com/" homepage = "https://solana.com/"
readme = "README.md" readme = "README.md"
@ -43,19 +43,19 @@ rocksdb = "0.10.1"
serde = "1.0.82" serde = "1.0.82"
serde_derive = "1.0.82" serde_derive = "1.0.82"
serde_json = "1.0.10" serde_json = "1.0.10"
solana-bpfloader = { path = "programs/native/bpf_loader", version = "0.11.0" } solana-bpfloader = { path = "programs/native/bpf_loader", version = "0.11.1" }
solana-drone = { path = "drone", version = "0.11.0" } solana-drone = { path = "drone", version = "0.11.1" }
solana-jsonrpc-core = "0.4.0" solana-jsonrpc-core = "0.4.0"
solana-jsonrpc-http-server = "0.4.0" solana-jsonrpc-http-server = "0.4.0"
solana-jsonrpc-macros = "0.4.0" solana-jsonrpc-macros = "0.4.0"
solana-jsonrpc-pubsub = "0.4.0" solana-jsonrpc-pubsub = "0.4.0"
solana-jsonrpc-ws-server = "0.4.0" solana-jsonrpc-ws-server = "0.4.0"
solana-logger = { path = "logger", version = "0.11.0" } solana-logger = { path = "logger", version = "0.11.1" }
solana-metrics = { path = "metrics", version = "0.11.0" } solana-metrics = { path = "metrics", version = "0.11.1" }
solana-native-loader = { path = "programs/native/native_loader", version = "0.11.0" } solana-native-loader = { path = "programs/native/native_loader", version = "0.11.1" }
solana-netutil = { path = "netutil", version = "0.11.0" } solana-netutil = { path = "netutil", version = "0.11.1" }
solana-sdk = { path = "sdk", version = "0.11.0" } solana-sdk = { path = "sdk", version = "0.11.1" }
solana-system-program = { path = "programs/native/system", version = "0.11.0" } solana-system-program = { path = "programs/native/system", version = "0.11.1" }
tokio = "0.1" tokio = "0.1"
tokio-codec = "0.1" tokio-codec = "0.1"
untrusted = "0.6.2" untrusted = "0.6.2"

View File

@ -26,7 +26,9 @@ Furthermore, and much to our surprise, it can be implemented using a mechanism t
Architecture Architecture
=== ===
Before you jump into the code, review the online book [Solana: Blockchain Rebuilt for Scale](https://solana-labs.github.io/solana/). Before you jump into the code, review the online book [Solana: Blockchain Rebuilt for Scale](https://solana-labs.github.io/book/).
(The _latest_ development version of the online book is also [available here](https://solana-labs.github.io/book-edge/).)
Developing Developing
=== ===

View File

@ -2,16 +2,16 @@
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018" edition = "2018"
name = "solana-bench-streamer" name = "solana-bench-streamer"
version = "0.11.0" version = "0.11.1"
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0" license = "Apache-2.0"
homepage = "https://solana.com/" homepage = "https://solana.com/"
[dependencies] [dependencies]
clap = "2.32.0" clap = "2.32.0"
solana = { path = "..", version = "0.11.0" } solana = { path = "..", version = "0.11.1" }
solana-logger = { path = "../logger", version = "0.11.0" } solana-logger = { path = "../logger", version = "0.11.1" }
solana-netutil = { path = "../netutil", version = "0.11.0" } solana-netutil = { path = "../netutil", version = "0.11.1" }
[features] [features]
cuda = [] cuda = []

View File

@ -2,7 +2,7 @@
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018" edition = "2018"
name = "solana-bench-tps" name = "solana-bench-tps"
version = "0.11.0" version = "0.11.1"
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0" license = "Apache-2.0"
homepage = "https://solana.com/" homepage = "https://solana.com/"
@ -11,11 +11,11 @@ homepage = "https://solana.com/"
clap = "2.32.0" clap = "2.32.0"
rayon = "1.0.3" rayon = "1.0.3"
serde_json = "1.0.10" serde_json = "1.0.10"
solana = { path = "..", version = "0.11.0" } solana = { path = "..", version = "0.11.1" }
solana-drone = { path = "../drone", version = "0.11.0" } solana-drone = { path = "../drone", version = "0.11.1" }
solana-logger = { path = "../logger", version = "0.11.0" } solana-logger = { path = "../logger", version = "0.11.1" }
solana-metrics = { path = "../metrics", version = "0.11.0" } solana-metrics = { path = "../metrics", version = "0.11.1" }
solana-sdk = { path = "../sdk", version = "0.11.0" } solana-sdk = { path = "../sdk", version = "0.11.1" }
[features] [features]
cuda = [] cuda = []

View File

@ -22,8 +22,9 @@ Methods
--- ---
* [confirmTransaction](#confirmtransaction) * [confirmTransaction](#confirmtransaction)
* [getBalance](#getbalance)
* [getAccountInfo](#getaccountinfo) * [getAccountInfo](#getaccountinfo)
* [getBalance](#getbalance)
* [getConfirmationTime](#getconfirmationTime)
* [getLastId](#getlastid) * [getLastId](#getlastid)
* [getSignatureStatus](#getsignaturestatus) * [getSignatureStatus](#getsignaturestatus)
* [getTransactionCount](#gettransactioncount) * [getTransactionCount](#gettransactioncount)
@ -201,6 +202,25 @@ curl -X POST -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","id":1, "m
{"jsonrpc":"2.0","result":268,"id":1} {"jsonrpc":"2.0","result":268,"id":1}
``` ```
---
### getConfirmationTime
Returns the current cluster confirmation time in milliseconds
##### Parameters:
None
##### Results:
* `integer` - confirmation time in milliseconds, as unsigned 64-bit integer
##### Example:
```bash
// Request
curl -X POST -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","id":1, "method":"getConfirmationTime"}' http://localhost:8899
// Result
{"jsonrpc":"2.0","result":500,"id":1}
```
--- ---
### requestAirdrop ### requestAirdrop

View File

@ -6,7 +6,7 @@ steps:
timeout_in_minutes: 20 timeout_in_minutes: 20
name: "publish docker" name: "publish docker"
- command: "ci/publish-crate.sh" - command: "ci/publish-crate.sh"
timeout_in_minutes: 20 timeout_in_minutes: 40
name: "publish crate" name: "publish crate"
branches: "!master" branches: "!master"
- command: "ci/publish-bpf-sdk.sh" - command: "ci/publish-bpf-sdk.sh"

View File

@ -82,10 +82,26 @@ for tag in "${tags[@]}"; do
fi fi
done done
echo EDGE_CHANNEL=master EDGE_CHANNEL=master
echo BETA_CHANNEL="${beta:+v$beta}" BETA_CHANNEL=${beta:+v$beta}
echo STABLE_CHANNEL="${stable:+v$stable}" STABLE_CHANNEL=${stable:+v$stable}
echo BETA_CHANNEL_LATEST_TAG="${beta_tag:+v$beta_tag}" BETA_CHANNEL_LATEST_TAG=${beta_tag:+v$beta_tag}
echo STABLE_CHANNEL_LATEST_TAG="${stable_tag:+v$stable_tag}" STABLE_CHANNEL_LATEST_TAG=${stable_tag:+v$stable_tag}
if [[ $BUILDKITE_BRANCH = "$STABLE_CHANNEL" ]]; then
CHANNEL=stable
elif [[ $BUILDKITE_BRANCH = "$EDGE_CHANNEL" ]]; then
CHANNEL=edge
elif [[ $BUILDKITE_BRANCH = "$BETA_CHANNEL" ]]; then
CHANNEL=beta
fi
echo EDGE_CHANNEL="$EDGE_CHANNEL"
echo BETA_CHANNEL="$BETA_CHANNEL"
echo BETA_CHANNEL_LATEST_TAG="$BETA_CHANNEL_LATEST_TAG"
echo STABLE_CHANNEL="$STABLE_CHANNEL"
echo STABLE_CHANNEL_LATEST_TAG="$STABLE_CHANNEL_LATEST_TAG"
echo CHANNEL="$CHANNEL"
exit 0 exit 0

View File

@ -16,18 +16,29 @@ echo --- create book repo
git commit -m "${BUILDKITE_COMMIT:-local}" git commit -m "${BUILDKITE_COMMIT:-local}"
) )
echo --- publish eval "$(ci/channel-info.sh)"
if [[ $BUILDKITE_BRANCH = master ]]; then # Only publish the book from the edge and beta channels for now.
cd book/html/ case $CHANNEL in
git remote add origin git@github.com:solana-labs/solana.git edge)
git fetch origin gh-pages repo=git@github.com:solana-labs/book-edge.git
if ! git diff HEAD origin/gh-pages --quiet; then ;;
git push -f origin HEAD:gh-pages beta)
else repo=git@github.com:solana-labs/book.git
echo "Content unchanged, publish skipped" ;;
fi *)
echo "--- publish skipped"
exit 0
;;
esac
echo "--- publish $CHANNEL"
cd book/html/
git remote add origin $repo
git fetch origin master
if ! git diff HEAD origin/master --quiet; then
git push -f origin HEAD:master
else else
echo "Publish skipped" echo "Content unchanged, publish skipped"
fi fi
exit 0 exit 0

View File

@ -19,6 +19,7 @@ CRATES=(
drone drone
programs/native/{budget,bpf_loader,lua_loader,native_loader,noop,system,vote} programs/native/{budget,bpf_loader,lua_loader,native_loader,noop,system,vote}
. .
fullnode-config
fullnode fullnode
genesis genesis
ledger-tool ledger-tool
@ -26,22 +27,18 @@ CRATES=(
) )
maybePackage="echo Package skipped"
maybePublish="echo Publish skipped"
# Only package/publish if this is a tagged release # Only package/publish if this is a tagged release
if [[ -n $BUILDKITE_TAG && -n $TRIGGERED_BUILDKITE_TAG ]]; then [[ -n $TRIGGERED_BUILDKITE_TAG ]] || {
maybePackage="cargo package" echo TRIGGERED_BUILDKITE_TAG unset, skipped
exit 0
}
# Only publish if there's no human around [[ -n "$CRATES_IO_TOKEN" ]] || {
if [[ -n $CI ]]; then echo CRATES_IO_TOKEN undefined
maybePublish="cargo publish --token $CRATES_IO_TOKEN" exit 1
if [[ -z "$CRATES_IO_TOKEN" ]]; then }
echo CRATES_IO_TOKEN undefined
exit 1 cargoCommand="cargo publish --token $CRATES_IO_TOKEN"
fi
fi
fi
for crate in "${CRATES[@]}"; do for crate in "${CRATES[@]}"; do
if [[ ! -r $crate/Cargo.toml ]]; then if [[ ! -r $crate/Cargo.toml ]]; then
@ -49,10 +46,14 @@ for crate in "${CRATES[@]}"; do
exit 1 exit 1
fi fi
echo "-- $crate" echo "-- $crate"
# TODO: Ensure the published version matches the contents of BUILDKITE_TAG # TODO: Ensure the published version matches the contents of
# TRIGGERED_BUILDKITE_TAG
( (
set -x set -x
ci/docker-run.sh rust bash -exc "cd $crate; $maybePackage; $maybePublish" # TODO: the rocksdb package does not build with the stock rust docker image,
# so use the solana rust docker image until this is resolved upstream
ci/docker-run.sh solanalabs/rust:1.31.0 bash -exc "cd $crate; $cargoCommand"
#ci/docker-run.sh rust bash -exc "cd $crate; $cargoCommand"
) )
done done

View File

@ -8,11 +8,11 @@ if [[ -z $BUILDKITE ]]; then
exit 1 exit 1
fi fi
if [[ -z $CHANNEL ]]; then if [[ -z $PUBLISH_CHANNEL ]]; then
CHANNEL=$(buildkite-agent meta-data get "channel" --default "") PUBLISH_CHANNEL=$(buildkite-agent meta-data get "channel" --default "")
fi fi
if [[ -z $CHANNEL ]]; then if [[ -z $PUBLISH_CHANNEL ]]; then
( (
cat <<EOF cat <<EOF
steps: steps:
@ -37,7 +37,7 @@ fi
ci/channel-info.sh ci/channel-info.sh
eval "$(ci/channel-info.sh)" eval "$(ci/channel-info.sh)"
case $CHANNEL in case $PUBLISH_CHANNEL in
edge) edge)
CHANNEL_BRANCH=$EDGE_CHANNEL CHANNEL_BRANCH=$EDGE_CHANNEL
;; ;;
@ -45,10 +45,10 @@ beta)
CHANNEL_BRANCH=$BETA_CHANNEL CHANNEL_BRANCH=$BETA_CHANNEL
;; ;;
stable) stable)
CHANNEL_BRANCH=$BETA_CHANNEL CHANNEL_BRANCH=$STABLE_CHANNEL
;; ;;
*) *)
echo "Error: Invalid CHANNEL=$CHANNEL" echo "Error: Invalid PUBLISH_CHANNEL=$PUBLISH_CHANNEL"
exit 1 exit 1
;; ;;
esac esac
@ -63,11 +63,11 @@ steps:
message: "$BUILDKITE_MESSAGE" message: "$BUILDKITE_MESSAGE"
branch: "$CHANNEL_BRANCH" branch: "$CHANNEL_BRANCH"
env: env:
CHANNEL: "$CHANNEL" PUBLISH_CHANNEL: "$PUBLISH_CHANNEL"
EOF EOF
) | buildkite-agent pipeline upload ) | buildkite-agent pipeline upload
exit 0 exit 0
fi fi
set -x set -x
exec metrics/publish-metrics-dashboard.sh "$CHANNEL" exec metrics/publish-metrics-dashboard.sh "$PUBLISH_CHANNEL"

View File

@ -11,14 +11,6 @@ fi
eval "$(ci/channel-info.sh)" eval "$(ci/channel-info.sh)"
if [[ $BUILDKITE_BRANCH = "$STABLE_CHANNEL" ]]; then
CHANNEL=stable
elif [[ $BUILDKITE_BRANCH = "$EDGE_CHANNEL" ]]; then
CHANNEL=edge
elif [[ $BUILDKITE_BRANCH = "$BETA_CHANNEL" ]]; then
CHANNEL=beta
fi
if [[ -n "$BUILDKITE_TAG" ]]; then if [[ -n "$BUILDKITE_TAG" ]]; then
CHANNEL_OR_TAG=$BUILDKITE_TAG CHANNEL_OR_TAG=$BUILDKITE_TAG
elif [[ -n "$TRIGGERED_BUILDKITE_TAG" ]]; then elif [[ -n "$TRIGGERED_BUILDKITE_TAG" ]]; then

View File

@ -19,14 +19,6 @@ fi
eval "$(ci/channel-info.sh)" eval "$(ci/channel-info.sh)"
if [[ $BUILDKITE_BRANCH = "$STABLE_CHANNEL" ]]; then
CHANNEL=stable
elif [[ $BUILDKITE_BRANCH = "$EDGE_CHANNEL" ]]; then
CHANNEL=edge
elif [[ $BUILDKITE_BRANCH = "$BETA_CHANNEL" ]]; then
CHANNEL=beta
fi
if [[ -z $CHANNEL ]]; then if [[ -z $CHANNEL ]]; then
echo Unable to determine channel to publish into, exiting. echo Unable to determine channel to publish into, exiting.
exit 1 exit 1
@ -61,13 +53,13 @@ if [[ ! -x /usr/bin/multilog ]]; then
sudo apt-get install -y daemontools sudo apt-get install -y daemontools
fi fi
echo --- build: $CHANNEL channel echo "--- build: $CHANNEL channel"
snapcraft snapcraft
source ci/upload-ci-artifact.sh source ci/upload-ci-artifact.sh
upload-ci-artifact solana_*.snap upload-ci-artifact solana_*.snap
if [[ -z $DO_NOT_PUBLISH_SNAP ]]; then if [[ -z $DO_NOT_PUBLISH_SNAP ]]; then
echo --- publish: $CHANNEL channel echo "--- publish: $CHANNEL channel"
$DRYRUN snapcraft push solana_*.snap --release $CHANNEL $DRYRUN snapcraft push solana_*.snap --release "$CHANNEL"
fi fi

View File

@ -25,6 +25,7 @@ launchTestnet() {
echo --- setup "$nodeCount" node test echo --- setup "$nodeCount" node test
net/gce.sh create \ net/gce.sh create \
-b \ -b \
-d pd-ssd \
-n "$nodeCount" -c "$CLIENT_COUNT" \ -n "$nodeCount" -c "$CLIENT_COUNT" \
-G "$LEADER_CPU_MACHINE_TYPE" \ -G "$LEADER_CPU_MACHINE_TYPE" \
-p "$TESTNET_TAG" -z "$TESTNET_ZONE" -p "$TESTNET_TAG" -z "$TESTNET_ZONE"
@ -34,9 +35,9 @@ launchTestnet() {
echo --- start "$nodeCount" node test echo --- start "$nodeCount" node test
if [[ -n $USE_PREBUILT_CHANNEL_TARBALL ]]; then if [[ -n $USE_PREBUILT_CHANNEL_TARBALL ]]; then
net/net.sh start -o noValidatorSanity -t "$CHANNEL" net/net.sh start -f "cuda" -o noValidatorSanity -t "$CHANNEL"
else else
net/net.sh start -o noValidatorSanity -T solana*.tar.bz2 net/net.sh start -f "cuda" -o noValidatorSanity -T solana*.tar.bz2
fi fi
echo --- wait "$ITERATION_WAIT" seconds to complete test echo --- wait "$ITERATION_WAIT" seconds to complete test
@ -56,24 +57,24 @@ launchTestnet() {
WHERE time > now() - 300s GROUP BY time(1s) WHERE time > now() - 300s GROUP BY time(1s)
)' )'
declare q_mean_finality=' declare q_mean_confirmation='
SELECT round(mean("duration_ms")) as "mean_finality" SELECT round(mean("duration_ms")) as "mean_confirmation"
FROM "testnet-automation"."autogen"."leader-finality" FROM "testnet-automation"."autogen"."leader-confirmation"
WHERE time > now() - 300s' WHERE time > now() - 300s'
declare q_max_finality=' declare q_max_confirmation='
SELECT round(max("duration_ms")) as "max_finality" SELECT round(max("duration_ms")) as "max_confirmation"
FROM "testnet-automation"."autogen"."leader-finality" FROM "testnet-automation"."autogen"."leader-confirmation"
WHERE time > now() - 300s' WHERE time > now() - 300s'
declare q_99th_finality=' declare q_99th_confirmation='
SELECT round(percentile("duration_ms", 99)) as "99th_finality" SELECT round(percentile("duration_ms", 99)) as "99th_confirmation"
FROM "testnet-automation"."autogen"."leader-finality" FROM "testnet-automation"."autogen"."leader-confirmation"
WHERE time > now() - 300s' WHERE time > now() - 300s'
curl -G "https://metrics.solana.com:8086/query?u=${INFLUX_USERNAME}&p=${INFLUX_PASSWORD}" \ curl -G "https://metrics.solana.com:8086/query?u=${INFLUX_USERNAME}&p=${INFLUX_PASSWORD}" \
--data-urlencode "db=$INFLUX_DATABASE" \ --data-urlencode "db=$INFLUX_DATABASE" \
--data-urlencode "q=$q_mean_tps;$q_max_tps;$q_mean_finality;$q_max_finality;$q_99th_finality" | --data-urlencode "q=$q_mean_tps;$q_max_tps;$q_mean_confirmation;$q_max_confirmation;$q_99th_confirmation" |
python ci/testnet-automation-json-parser.py >>TPS"$nodeCount".log python ci/testnet-automation-json-parser.py >>TPS"$nodeCount".log
upload-ci-artifact TPS"$nodeCount".log upload-ci-artifact TPS"$nodeCount".log

View File

@ -2,6 +2,7 @@
set -e set -e
cd "$(dirname "$0")"/.. cd "$(dirname "$0")"/..
source ci/upload-ci-artifact.sh
zone= zone=
bootstrapFullNodeAddress= bootstrapFullNodeAddress=
@ -9,12 +10,16 @@ bootstrapFullNodeMachineType=
clientNodeCount=0 clientNodeCount=0
additionalFullNodeCount=10 additionalFullNodeCount=10
publicNetwork=false publicNetwork=false
snapChannel=edge skipSetup=false
skipStart=false
stopNetwork=false
externalNode=false
tarChannelOrTag=edge tarChannelOrTag=edge
delete=false delete=false
enableGpu=false enableGpu=false
bootDiskType=""
leaderRotation=true leaderRotation=true
useTarReleaseChannel=false blockstreamer=false
usage() { usage() {
exitcode=0 exitcode=0
@ -23,29 +28,35 @@ usage() {
echo "Error: $*" echo "Error: $*"
fi fi
cat <<EOF cat <<EOF
usage: $0 [name] [cloud] [zone] [options...] usage: $0 -p network-name -C cloud -z zone1 [-z zone2] ... [-z zoneN] [options...]
Deploys a CD testnet Deploys a CD testnet
name - name of the network mandatory arguments:
cloud - cloud provider to use (gce, ec2) -p [network-name] - name of the network
zone - cloud provider zone to deploy the network into -C [cloud] - cloud provider to use (gce, ec2)
-z [zone] - cloud provider zone to deploy the network into. Must specify at least one zone
options: options:
-s edge|beta|stable - Deploy the specified Snap release channel
(default: $snapChannel)
-t edge|beta|stable|vX.Y.Z - Deploy the latest tarball release for the -t edge|beta|stable|vX.Y.Z - Deploy the latest tarball release for the
specified release channel (edge|beta|stable) or release tag specified release channel (edge|beta|stable) or release tag
(vX.Y.Z) (vX.Y.Z)
(default: $tarChannelOrTag) (default: $tarChannelOrTag)
-n [number] - Number of additional full nodes (default: $additionalFullNodeCount) -n [number] - Number of additional full nodes (default: $additionalFullNodeCount)
-c [number] - Number of client bencher nodes (default: $clientNodeCount) -c [number] - Number of client bencher nodes (default: $clientNodeCount)
-u - Include a Blockstreamer (default: $blockstreamer)
-P - Use public network IP addresses (default: $publicNetwork) -P - Use public network IP addresses (default: $publicNetwork)
-G - Enable GPU, and set count/type of GPUs to use (e.g n1-standard-16 --accelerator count=4,type=nvidia-tesla-k80) -G - Enable GPU, and set count/type of GPUs to use (e.g n1-standard-16 --accelerator count=4,type=nvidia-tesla-k80)
-g - Enable GPU (default: $enableGpu) -g - Enable GPU (default: $enableGpu)
-b - Disable leader rotation -b - Disable leader rotation
-a [address] - Set the bootstrap fullnode's external IP address to this GCE address -a [address] - Set the bootstrap fullnode's external IP address to this GCE address
-d - Delete the network -d [disk-type] - Specify a boot disk type (default None) Use pd-ssd to get ssd on GCE.
-D - Delete the network
-r - Reuse existing node/ledger configuration from a
previous |start| (ie, don't run ./multinode-demo/setup.sh).
-x - External node. Default: false
-s - Skip start. Nodes will still be created or configured, but network software will not be started.
-S - Stop network software without tearing down nodes.
Note: the SOLANA_METRICS_CONFIG environment variable is used to configure Note: the SOLANA_METRICS_CONFIG environment variable is used to configure
metrics metrics
@ -53,19 +64,22 @@ EOF
exit $exitcode exit $exitcode
} }
netName=$1 zone=()
cloudProvider=$2
zone=$3
[[ -n $netName ]] || usage
[[ -n $cloudProvider ]] || usage "Cloud provider not specified"
[[ -n $zone ]] || usage "Zone not specified"
shift 3
while getopts "h?p:Pn:c:s:t:gG:a:db" opt; do while getopts "h?p:Pn:c:t:gG:a:Dbd:rusxz:p:C:S" opt; do
case $opt in case $opt in
h | \?) h | \?)
usage usage
;; ;;
p)
netName=$OPTARG
;;
C)
cloudProvider=$OPTARG
;;
z)
zone+=("$OPTARG")
;;
P) P)
publicNetwork=true publicNetwork=true
;; ;;
@ -75,21 +89,10 @@ while getopts "h?p:Pn:c:s:t:gG:a:db" opt; do
c) c)
clientNodeCount=$OPTARG clientNodeCount=$OPTARG
;; ;;
s)
case $OPTARG in
edge|beta|stable)
snapChannel=$OPTARG
;;
*)
usage "Invalid snap channel: $OPTARG"
;;
esac
;;
t) t)
case $OPTARG in case $OPTARG in
edge|beta|stable|v*) edge|beta|stable|v*)
tarChannelOrTag=$OPTARG tarChannelOrTag=$OPTARG
useTarReleaseChannel=true
;; ;;
*) *)
usage "Invalid release channel: $OPTARG" usage "Invalid release channel: $OPTARG"
@ -110,51 +113,139 @@ while getopts "h?p:Pn:c:s:t:gG:a:db" opt; do
bootstrapFullNodeAddress=$OPTARG bootstrapFullNodeAddress=$OPTARG
;; ;;
d) d)
bootDiskType=$OPTARG
;;
D)
delete=true delete=true
;; ;;
r)
skipSetup=true
;;
s)
skipStart=true
;;
x)
externalNode=true
;;
u)
blockstreamer=true
;;
S)
stopNetwork=true
;;
*) *)
usage "Error: unhandled option: $opt" usage "Error: unhandled option: $opt"
;; ;;
esac esac
done done
[[ -n $netName ]] || usage
[[ -n $cloudProvider ]] || usage "Cloud provider not specified"
[[ -n ${zone[*]} ]] || usage "At least one zone must be specified"
create_args=( shutdown() {
-a "$bootstrapFullNodeAddress" exitcode=$?
-c "$clientNodeCount"
-n "$additionalFullNodeCount"
-p "$netName"
-z "$zone"
)
if $enableGpu; then set +e
if [[ -z $bootstrapFullNodeMachineType ]]; then if [[ -d net/log ]]; then
create_args+=(-g) mv net/log net/log-deploy
else for logfile in net/log-deploy/*; do
create_args+=(-G "$bootstrapFullNodeMachineType") if [[ -f $logfile ]]; then
upload-ci-artifact "$logfile"
tail "$logfile"
fi
done
fi fi
fi exit $exitcode
}
if ! $leaderRotation; then rm -rf net/{log,-deploy}
create_args+=(-b) trap shutdown EXIT INT
fi
if $publicNetwork; then
create_args+=(-P)
fi
set -x set -x
echo "--- $cloudProvider.sh delete" # Build a string to pass zone opts to $cloudProvider.sh: "-z zone1 -z zone2 ..."
time net/"$cloudProvider".sh delete -z "$zone" -p "$netName" zone_args=()
if $delete; then for val in "${zone[@]}"; do
exit 0 zone_args+=("-z $val")
done
if $stopNetwork; then
skipSetup=true
fi fi
echo "--- $cloudProvider.sh create" if $delete; then
time net/"$cloudProvider".sh create "${create_args[@]}" skipSetup=false
fi
# Create the network
if ! $skipSetup; then
echo "--- $cloudProvider.sh delete"
# shellcheck disable=SC2068
time net/"$cloudProvider".sh delete ${zone_args[@]} -p "$netName"
if $delete; then
exit 0
fi
echo "--- $cloudProvider.sh create"
create_args=(
-p "$netName"
-a "$bootstrapFullNodeAddress"
-c "$clientNodeCount"
-n "$additionalFullNodeCount"
)
# shellcheck disable=SC2206
create_args+=(${zone_args[@]})
if $blockstreamer; then
create_args+=(-u)
fi
if [[ -n $bootDiskType ]]; then
create_args+=(-d "$bootDiskType")
fi
if $enableGpu; then
if [[ -z $bootstrapFullNodeMachineType ]]; then
create_args+=(-g)
else
create_args+=(-G "$bootstrapFullNodeMachineType")
fi
fi
if ! $leaderRotation; then
create_args+=(-b)
fi
if $publicNetwork; then
create_args+=(-P)
fi
if $externalNode; then
create_args+=(-x)
fi
time net/"$cloudProvider".sh create "${create_args[@]}"
else
echo "--- $cloudProvider.sh config"
config_args=(
-p "$netName"
)
# shellcheck disable=SC2206
config_args+=(${zone_args[@]})
if $publicNetwork; then
config_args+=(-P)
fi
time net/"$cloudProvider".sh config "${config_args[@]}"
fi
net/init-metrics.sh -e net/init-metrics.sh -e
if $stopNetwork; then
echo --- net.sh stop
time net/net.sh stop
exit 0
fi
echo --- net.sh start echo --- net.sh start
maybeRejectExtraNodes= maybeRejectExtraNodes=
if ! $publicNetwork; then if ! $publicNetwork; then
@ -168,10 +259,38 @@ maybeNoLedgerVerify=
if [[ -n $NO_LEDGER_VERIFY ]]; then if [[ -n $NO_LEDGER_VERIFY ]]; then
maybeNoLedgerVerify="-o noLedgerVerify" maybeNoLedgerVerify="-o noLedgerVerify"
fi fi
# shellcheck disable=SC2086 # Don't want to double quote maybeRejectExtraNodes
if $useTarReleaseChannel; then maybeSkipSetup=
time net/net.sh start -t "$tarChannelOrTag" $maybeRejectExtraNodes $maybeNoValidatorSanity $maybeNoLedgerVerify if $skipSetup; then
else maybeSkipSetup="-r"
time net/net.sh start -s "$snapChannel" $maybeRejectExtraNodes $maybeNoValidatorSanity $maybeNoLedgerVerify
fi fi
exit 0
ok=true
if ! $skipStart; then
(
if $skipSetup; then
# TODO: Enable rolling updates
#op=update
op=restart
else
op=start
fi
maybeUpdateManifestKeypairFile=
# shellcheck disable=SC2154 # SOLANA_INSTALL_UPDATE_MANIFEST_KEYPAIR_x86_64_unknown_linux_gnu comes from .buildkite/env/
if [[ -n $SOLANA_INSTALL_UPDATE_MANIFEST_KEYPAIR_x86_64_unknown_linux_gnu ]]; then
echo "$SOLANA_INSTALL_UPDATE_MANIFEST_KEYPAIR_x86_64_unknown_linux_gnu" > update_manifest_keypair.json
maybeUpdateManifestKeypairFile="-i update_manifest_keypair.json"
fi
# shellcheck disable=SC2086 # Don't want to double quote the $maybeXYZ variables
time net/net.sh $op -t "$tarChannelOrTag" \
$maybeUpdateManifestKeypairFile \
$maybeSkipSetup \
$maybeRejectExtraNodes \
$maybeNoValidatorSanity \
$maybeNoLedgerVerify
) || ok=false
fi
$ok

View File

@ -42,18 +42,28 @@ steps:
value: "testnet-beta" value: "testnet-beta"
- label: "testnet-beta-perf" - label: "testnet-beta-perf"
value: "testnet-beta-perf" value: "testnet-beta-perf"
- label: "testnet-demo"
value: "testnet-demo"
- select: "Operation" - select: "Operation"
key: "testnet-operation" key: "testnet-operation"
default: "sanity-or-restart" default: "sanity-or-restart"
options: options:
- label: "Sanity check. Restart network on failure" - label: "Create new testnet nodes and then start network software. If nodes are already created, they will be deleted and then re-created."
value: "sanity-or-restart" value: "create-and-start"
- label: "Start (or restart) the network" - label: "Create new testnet nodes, but do not start network software. If nodes are already created, they will be deleted and then re-created."
value: "create"
- label: "Start network software on already-created testnet nodes. If software is already running, it will be restarted."
value: "start" value: "start"
- label: "Stop the network" - label: "Stop network software without deleting testnet nodes"
value: "stop" value: "stop"
- label: "Update the network software. Restart network software on failure"
value: "update-or-restart"
- label: "Sanity check. Restart network software on failure"
value: "sanity-or-restart"
- label: "Sanity check only" - label: "Sanity check only"
value: "sanity" value: "sanity"
- label: "Delete all nodes on a testnet. Network software will be stopped first if it is running"
value: "delete"
- command: "ci/$(basename "$0")" - command: "ci/$(basename "$0")"
agents: agents:
- "queue=$BUILDKITE_AGENT_META_DATA_QUEUE" - "queue=$BUILDKITE_AGENT_META_DATA_QUEUE"
@ -62,27 +72,36 @@ EOF
exit 0 exit 0
fi fi
export SOLANA_METRICS_CONFIG="db=$TESTNET,$SOLANA_METRICS_PARTIAL_CONFIG"
echo "SOLANA_METRICS_CONFIG: $SOLANA_METRICS_CONFIG"
ci/channel-info.sh ci/channel-info.sh
eval "$(ci/channel-info.sh)" eval "$(ci/channel-info.sh)"
EC2_ZONES=(us-west-1a sa-east-1a ap-northeast-2a eu-central-1a ca-central-1a)
GCE_ZONES=(us-west1-b asia-east2-a europe-west4-a southamerica-east1-b us-east4-c)
case $TESTNET in case $TESTNET in
testnet-edge|testnet-edge-perf) testnet-edge|testnet-edge-perf)
CHANNEL_OR_TAG=edge CHANNEL_OR_TAG=edge
CHANNEL_BRANCH=$EDGE_CHANNEL CHANNEL_BRANCH=$EDGE_CHANNEL
: "${TESTNET_DB_HOST:=https://clocktower-f1d56615.influxcloud.net:8086}"
;; ;;
testnet-beta|testnet-beta-perf) testnet-beta|testnet-beta-perf)
CHANNEL_OR_TAG=beta CHANNEL_OR_TAG=beta
CHANNEL_BRANCH=$BETA_CHANNEL CHANNEL_BRANCH=$BETA_CHANNEL
: "${TESTNET_DB_HOST:=https://clocktower-f1d56615.influxcloud.net:8086}"
: "${EC2_NODE_COUNT:=10}"
: "${GCE_NODE_COUNT:=}"
;; ;;
testnet|testnet-perf) testnet)
if [[ -n $BETA_CHANNEL_LATEST_TAG ]]; then CHANNEL_OR_TAG=$STABLE_CHANNEL_LATEST_TAG
CHANNEL_OR_TAG=$BETA_CHANNEL_LATEST_TAG CHANNEL_BRANCH=$STABLE_CHANNEL
else : "${TESTNET_DB_HOST:=https://clocktower-f1d56615.influxcloud.net:8086}"
CHANNEL_OR_TAG=$STABLE_CHANNEL_LATEST_TAG ;;
fi testnet-perf)
CHANNEL_OR_TAG=$STABLE_CHANNEL_LATEST_TAG
CHANNEL_BRANCH=$STABLE_CHANNEL
;;
testnet-demo)
CHANNEL_OR_TAG=beta
CHANNEL_BRANCH=$BETA_CHANNEL CHANNEL_BRANCH=$BETA_CHANNEL
;; ;;
*) *)
@ -91,9 +110,21 @@ testnet|testnet-perf)
;; ;;
esac esac
if [[ $BUILDKITE_BRANCH != "$CHANNEL_BRANCH" ]]; then if [[ -n $TESTNET_DB_HOST ]]; then
( SOLANA_METRICS_PARTIAL_CONFIG="host=$TESTNET_DB_HOST,$SOLANA_METRICS_PARTIAL_CONFIG"
cat <<EOF fi
export SOLANA_METRICS_CONFIG="db=$TESTNET,$SOLANA_METRICS_PARTIAL_CONFIG"
echo "SOLANA_METRICS_CONFIG: $SOLANA_METRICS_CONFIG"
source scripts/configure-metrics.sh
if [[ -n $TESTNET_TAG ]]; then
CHANNEL_OR_TAG=$TESTNET_TAG
else
if [[ $BUILDKITE_BRANCH != "$CHANNEL_BRANCH" ]]; then
(
cat <<EOF
steps: steps:
- trigger: "$BUILDKITE_PIPELINE_SLUG" - trigger: "$BUILDKITE_PIPELINE_SLUG"
async: true async: true
@ -103,78 +134,78 @@ steps:
env: env:
TESTNET: "$TESTNET" TESTNET: "$TESTNET"
TESTNET_OP: "$TESTNET_OP" TESTNET_OP: "$TESTNET_OP"
TESTNET_DB_HOST: "$TESTNET_DB_HOST"
EC2_NODE_COUNT: "$EC2_NODE_COUNT"
GCE_NODE_COUNT: "$GCE_NODE_COUNT"
EOF EOF
) | buildkite-agent pipeline upload ) | buildkite-agent pipeline upload
exit 0 exit 0
fi
fi fi
sanity() { sanity() {
echo "--- sanity $TESTNET" echo "--- sanity $TESTNET"
case $TESTNET in case $TESTNET in
testnet-edge) testnet-edge)
# shellcheck disable=2030
# shellcheck disable=2031
( (
set -ex set -x
export NO_LEDGER_VERIFY=1 NO_LEDGER_VERIFY=1 \
export NO_VALIDATOR_SANITY=1 ci/testnet-sanity.sh edge-testnet-solana-com ec2 us-west-1a
ci/testnet-sanity.sh edge-testnet-solana-com ec2 us-west-1a
) )
;; ;;
testnet-edge-perf) testnet-edge-perf)
# shellcheck disable=2030
# shellcheck disable=2031
( (
set -ex set -x
export REJECT_EXTRA_NODES=1 REJECT_EXTRA_NODES=1 \
export NO_LEDGER_VERIFY=1 NO_LEDGER_VERIFY=1 \
export NO_VALIDATOR_SANITY=1 NO_VALIDATOR_SANITY=1 \
ci/testnet-sanity.sh edge-perf-testnet-solana-com ec2 us-west-2b ci/testnet-sanity.sh edge-perf-testnet-solana-com ec2 us-west-2b
) )
;; ;;
testnet-beta) testnet-beta)
# shellcheck disable=2030
# shellcheck disable=2031
( (
set -ex set -x
export NO_LEDGER_VERIFY=1
export NO_VALIDATOR_SANITY=1 ok=true
ci/testnet-sanity.sh beta-testnet-solana-com ec2 us-west-1a if [[ -n $EC2_NODE_COUNT ]]; then
NO_LEDGER_VERIFY=1 \
ci/testnet-sanity.sh beta-testnet-solana-com ec2 "${EC2_ZONES[0]}" || ok=false
elif [[ -n $GCE_NODE_COUNT ]]; then
NO_LEDGER_VERIFY=1 \
ci/testnet-sanity.sh beta-testnet-solana-com gce "${GCE_ZONES[0]}" || ok=false
else
echo "Error: no EC2 or GCE nodes"
ok=false
fi
$ok
) )
;; ;;
testnet-beta-perf) testnet-beta-perf)
# shellcheck disable=2030
# shellcheck disable=2031
( (
set -ex set -x
export REJECT_EXTRA_NODES=1 REJECT_EXTRA_NODES=1 \
export NO_LEDGER_VERIFY=1 NO_LEDGER_VERIFY=1 \
export NO_VALIDATOR_SANITY=1 NO_VALIDATOR_SANITY=1 \
ci/testnet-sanity.sh beta-perf-testnet-solana-com ec2 us-west-2b ci/testnet-sanity.sh beta-perf-testnet-solana-com ec2 us-west-2b
) )
;; ;;
testnet) testnet)
# shellcheck disable=2030
# shellcheck disable=2031
( (
set -ex set -x
export NO_LEDGER_VERIFY=1 NO_LEDGER_VERIFY=1 \
export NO_VALIDATOR_SANITY=1 NO_VALIDATOR_SANITY=1 \
ci/testnet-sanity.sh testnet-solana-com ec2 us-west-1a
#ci/testnet-sanity.sh testnet-solana-com gce us-east1-c #ci/testnet-sanity.sh testnet-solana-com gce us-east1-c
ci/testnet-sanity.sh testnet-solana-com ec2 us-west-1a
) )
;; ;;
testnet-perf) testnet-perf)
# shellcheck disable=2030
# shellcheck disable=2031
( (
set -ex set -x
export REJECT_EXTRA_NODES=1 REJECT_EXTRA_NODES=1 \
export NO_LEDGER_VERIFY=1 NO_LEDGER_VERIFY=1 \
export NO_VALIDATOR_SANITY=1 NO_VALIDATOR_SANITY=1 \
ci/testnet-sanity.sh perf-testnet-solana-com gce us-west1-b
#ci/testnet-sanity.sh perf-testnet-solana-com ec2 us-east-1a #ci/testnet-sanity.sh perf-testnet-solana-com ec2 us-east-1a
ci/testnet-sanity.sh perf-testnet-solana-com gce us-west1-b
) )
;; ;;
*) *)
@ -184,100 +215,146 @@ sanity() {
esac esac
} }
deploy() {
declare maybeCreate=$1
declare maybeStart=$2
declare maybeStop=$3
declare maybeDelete=$4
start() { echo "--- deploy \"$maybeCreate\" \"$maybeStart\" \"$maybeStop\" \"$maybeDelete\""
declare maybeDelete=$1
if [[ -z $maybeDelete ]]; then # Create or recreate the nodes
echo "--- start $TESTNET" if [[ -z $maybeCreate ]]; then
skipCreate=skip
else else
echo "--- stop $TESTNET" skipCreate=""
fi
# Start or restart the network software on the nodes
if [[ -z $maybeStart ]]; then
skipStart=skip
else
skipStart=""
fi fi
case $TESTNET in case $TESTNET in
testnet-edge) testnet-edge)
# shellcheck disable=2030
# shellcheck disable=2031
( (
set -ex set -x
export NO_LEDGER_VERIFY=1 ci/testnet-deploy.sh -p edge-testnet-solana-com -C ec2 -z us-west-1a \
export NO_VALIDATOR_SANITY=1 -t "$CHANNEL_OR_TAG" -n 3 -c 0 -u -P -a eipalloc-0ccd4f2239886fa94 \
ci/testnet-deploy.sh edge-testnet-solana-com ec2 us-west-1a \ ${skipCreate:+-r} \
-t "$CHANNEL_OR_TAG" -n 3 -c 0 -P -a eipalloc-0ccd4f2239886fa94 \ ${skipStart:+-s} \
${maybeDelete:+-d} ${maybeStop:+-S} \
${maybeDelete:+-D}
) )
;; ;;
testnet-edge-perf) testnet-edge-perf)
# shellcheck disable=2030
# shellcheck disable=2031
( (
set -ex set -x
export NO_LEDGER_VERIFY=1 NO_LEDGER_VERIFY=1 \
export NO_VALIDATOR_SANITY=1 NO_VALIDATOR_SANITY=1 \
ci/testnet-deploy.sh edge-perf-testnet-solana-com ec2 us-west-2b \ RUST_LOG=solana=warn \
-g -t "$CHANNEL_OR_TAG" -c 2 \ ci/testnet-deploy.sh -p edge-perf-testnet-solana-com -C ec2 -z us-west-2b \
-b \ -g -t "$CHANNEL_OR_TAG" -c 2 \
${maybeDelete:+-d} -b \
${skipCreate:+-r} \
${skipStart:+-s} \
${maybeStop:+-S} \
${maybeDelete:+-D}
) )
;; ;;
testnet-beta) testnet-beta)
# shellcheck disable=2030
# shellcheck disable=2031
( (
set -ex set -x
export NO_LEDGER_VERIFY=1
export NO_VALIDATOR_SANITY=1 # Build an array to pass as opts to testnet-deploy.sh: "-z zone1 -z zone2 ..."
ci/testnet-deploy.sh beta-testnet-solana-com ec2 us-west-1a \ GCE_ZONE_ARGS=()
-t "$CHANNEL_OR_TAG" -n 3 -c 0 -P -a eipalloc-0f286cf8a0771ce35 \ for val in "${GCE_ZONES[@]}"; do
-b \ GCE_ZONE_ARGS+=("-z $val")
${maybeDelete:+-d} done
EC2_ZONE_ARGS=()
for val in "${EC2_ZONES[@]}"; do
EC2_ZONE_ARGS+=("-z $val")
done
if [[ -n $EC2_NODE_COUNT ]]; then
if [[ -n $GCE_NODE_COUNT ]] || [[ -n $skipStart ]]; then
maybeSkipStart="skip"
fi
# shellcheck disable=SC2068
ci/testnet-deploy.sh -p beta-testnet-solana-com -C ec2 ${EC2_ZONE_ARGS[@]} \
-t "$CHANNEL_OR_TAG" -n "$EC2_NODE_COUNT" -c 0 -u -P -a eipalloc-0f286cf8a0771ce35 \
${skipCreate:+-r} \
${maybeSkipStart:+-s} \
${maybeStop:+-S} \
${maybeDelete:+-D}
fi
if [[ -n $GCE_NODE_COUNT ]]; then
# shellcheck disable=SC2068
ci/testnet-deploy.sh -p beta-testnet-solana-com -C gce ${GCE_ZONE_ARGS[@]} \
-t "$CHANNEL_OR_TAG" -n "$GCE_NODE_COUNT" -c 0 -P \
${skipCreate:+-r} \
${skipStart:+-s} \
${maybeStop:+-S} \
${maybeDelete:+-D} \
${EC2_NODE_COUNT:+-x}
fi
) )
;; ;;
testnet-beta-perf) testnet-beta-perf)
# shellcheck disable=2030
# shellcheck disable=2031
( (
set -ex set -x
export NO_LEDGER_VERIFY=1 NO_LEDGER_VERIFY=1 \
export NO_VALIDATOR_SANITY=1 NO_VALIDATOR_SANITY=1 \
ci/testnet-deploy.sh beta-perf-testnet-solana-com ec2 us-west-2b \ RUST_LOG=solana=warn \
-g -t "$CHANNEL_OR_TAG" -c 2 \ ci/testnet-deploy.sh -p beta-perf-testnet-solana-com -C ec2 -z us-west-2b \
-b \ -g -t "$CHANNEL_OR_TAG" -c 2 \
${maybeDelete:+-d} -b \
${skipCreate:+-r} \
${skipStart:+-s} \
${maybeStop:+-S} \
${maybeDelete:+-D}
) )
;; ;;
testnet) testnet)
# shellcheck disable=2030
# shellcheck disable=2031
( (
set -ex set -x
export NO_LEDGER_VERIFY=1 NO_VALIDATOR_SANITY=1 \
export NO_VALIDATOR_SANITY=1 ci/testnet-deploy.sh -p testnet-solana-com -C ec2 -z us-west-1a \
#ci/testnet-deploy.sh testnet-solana-com gce us-east1-c \ -t "$CHANNEL_OR_TAG" -n 3 -c 0 -u -P -a eipalloc-0fa502bf95f6f18b2 \
# -s "$CHANNEL_OR_TAG" -n 3 -c 0 -P -a testnet-solana-com \ -b \
# ${maybeDelete:+-d} ${skipCreate:+-r} \
ci/testnet-deploy.sh testnet-solana-com ec2 us-west-1a \ ${skipStart:+-s} \
-t "$CHANNEL_OR_TAG" -n 3 -c 0 -P -a eipalloc-0fa502bf95f6f18b2 \ ${maybeStop:+-S} \
-b \ ${maybeDelete:+-D}
${maybeDelete:+-d}
) )
;; ;;
testnet-perf) testnet-perf)
# shellcheck disable=2030
# shellcheck disable=2031
( (
set -ex set -x
export NO_LEDGER_VERIFY=1 NO_LEDGER_VERIFY=1 \
export NO_VALIDATOR_SANITY=1 NO_VALIDATOR_SANITY=1 \
ci/testnet-deploy.sh perf-testnet-solana-com gce us-west1-b \ RUST_LOG=solana=warn \
-G "n1-standard-16 --accelerator count=2,type=nvidia-tesla-v100" \ ci/testnet-deploy.sh -p perf-testnet-solana-com -C gce -z us-west1-b \
-t "$CHANNEL_OR_TAG" -c 2 \ -G "n1-standard-16 --accelerator count=2,type=nvidia-tesla-v100" \
-b \ -t "$CHANNEL_OR_TAG" -c 2 \
-d pd-ssd \ -b \
${maybeDelete:+-d} -d pd-ssd \
#ci/testnet-deploy.sh perf-testnet-solana-com ec2 us-east-1a \ ${skipCreate:+-r} \
# -g \ ${skipStart:+-s} \
# -t "$CHANNEL_OR_TAG" -c 2 \ ${maybeStop:+-S} \
# ${maybeDelete:+-d} ${maybeDelete:+-D}
)
;;
testnet-demo)
(
set -x
echo "Demo net not yet implemented!"
exit 1
) )
;; ;;
*) *)
@ -287,29 +364,119 @@ start() {
esac esac
} }
ENABLED_LOCKFILE="${HOME}/${TESTNET}.is_enabled"
CREATED_LOCKFILE="${HOME}/${TESTNET}.is_created"
create-and-start() {
rm -f "${CREATED_LOCKFILE}"
deploy create start
touch "${CREATED_LOCKFILE}"
}
create() {
rm -f "${CREATED_LOCKFILE}"
deploy create
touch "${CREATED_LOCKFILE}"
}
start() {
if [[ -f ${CREATED_LOCKFILE} ]]; then
deploy "" start
else
echo "Unable to start ${TESTNET}. Are the nodes created?
Re-run ci/testnet-manager.sh with \$TESTNET_OP=create or \$TESTNET_OP=create-and-start"
exit 1
fi
}
stop() { stop() {
start delete deploy "" ""
}
delete() {
deploy "" "" "" delete
rm -f "${CREATED_LOCKFILE}"
}
enable_testnet() {
touch "${ENABLED_LOCKFILE}"
echo "+++ $TESTNET now enabled"
}
disable_testnet() {
rm -f "${ENABLED_LOCKFILE}"
echo "+++ $TESTNET now disabled"
}
is_testnet_enabled() {
if [[ ! -f ${ENABLED_LOCKFILE} ]]; then
echo "--- ${TESTNET} is currently disabled. Enable ${TESTNET} by running ci/testnet-manager.sh with \$TESTNET_OP=enable, then re-run with current settings."
exit 0
fi
} }
case $TESTNET_OP in case $TESTNET_OP in
sanity) enable)
sanity enable_testnet
;;
disable)
disable_testnet
delete
;;
create-and-start)
is_testnet_enabled
create-and-start
;;
create)
is_testnet_enabled
create
;; ;;
start) start)
is_testnet_enabled
start start
;; ;;
stop) stop)
is_testnet_enabled
stop stop
;; ;;
sanity)
is_testnet_enabled
sanity
;;
delete)
is_testnet_enabled
delete
;;
update-or-restart)
is_testnet_enabled
if start; then
echo Update successful
else
echo "+++ Update failed, restarting the network"
$metricsWriteDatapoint "testnet-manager update-failure=1"
create-and-start
fi
;;
sanity-or-restart) sanity-or-restart)
is_testnet_enabled
if sanity; then if sanity; then
echo Pass echo Pass
else else
echo "Sanity failed, restarting the network" echo "+++ Sanity failed, updating the network"
echo "^^^ +++" $metricsWriteDatapoint "testnet-manager sanity-failure=1"
start
# TODO: Restore attempt to restart the cluster before recreating it
# See https://github.com/solana-labs/solana/issues/3774
if false; then
if start; then
echo Update successful
else
echo "+++ Update failed, restarting the network"
$metricsWriteDatapoint "testnet-manager update-failure=1"
create-and-start
fi
else
create-and-start
fi
fi fi
;; ;;
*)
echo "Error: Invalid TESTNET_OP=$TESTNET_OP"
exit 1
;;
esac esac
echo --- fin echo --- fin

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-drone" name = "solana-drone"
version = "0.11.0" version = "0.11.1"
description = "Solana Drone" description = "Solana Drone"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -19,8 +19,8 @@ clap = "2.31"
log = "0.4.2" log = "0.4.2"
serde = "1.0.82" serde = "1.0.82"
serde_derive = "1.0.82" serde_derive = "1.0.82"
solana-sdk = { path = "../sdk", version = "0.11.0" } solana-sdk = { path = "../sdk", version = "0.11.1" }
solana-metrics = { path = "../metrics", version = "0.11.0" } solana-metrics = { path = "../metrics", version = "0.11.1" }
tokio = "0.1" tokio = "0.1"
tokio-codec = "0.1" tokio-codec = "0.1"

View File

@ -2,7 +2,8 @@
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018" edition = "2018"
name = "solana-fullnode-config" name = "solana-fullnode-config"
version = "0.11.0" description = "Blockchain, Rebuilt for Scale"
version = "0.11.1"
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0" license = "Apache-2.0"
homepage = "https://solana.com/" homepage = "https://solana.com/"
@ -14,8 +15,8 @@ log = "0.4.2"
serde = "1.0.82" serde = "1.0.82"
serde_derive = "1.0.82" serde_derive = "1.0.82"
serde_json = "1.0.10" serde_json = "1.0.10"
solana-netutil = { path = "../netutil", version = "0.11.0" } solana-netutil = { path = "../netutil", version = "0.11.1" }
solana-sdk = { path = "../sdk", version = "0.11.0" } solana-sdk = { path = "../sdk", version = "0.11.1" }
untrusted = "0.6.2" untrusted = "0.6.2"
[features] [features]

View File

@ -2,7 +2,8 @@
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018" edition = "2018"
name = "solana-fullnode" name = "solana-fullnode"
version = "0.11.0" description = "Blockchain, Rebuilt for Scale"
version = "0.11.1"
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0" license = "Apache-2.0"
homepage = "https://solana.com/" homepage = "https://solana.com/"
@ -11,13 +12,13 @@ homepage = "https://solana.com/"
clap = "2.32.0" clap = "2.32.0"
log = "0.4.2" log = "0.4.2"
serde_json = "1.0.10" serde_json = "1.0.10"
solana = { path = "..", version = "0.11.0" } solana = { path = "..", version = "0.11.1" }
solana-drone = { path = "../drone", version = "0.11.0" } solana-drone = { path = "../drone", version = "0.11.1" }
solana-fullnode-config = { path = "../fullnode-config", version = "0.11.0" } solana-fullnode-config = { path = "../fullnode-config", version = "0.11.1" }
solana-logger = { path = "../logger", version = "0.11.0" } solana-logger = { path = "../logger", version = "0.11.1" }
solana-netutil = { path = "../netutil", version = "0.11.0" } solana-netutil = { path = "../netutil", version = "0.11.1" }
solana-metrics = { path = "../metrics", version = "0.11.0" } solana-metrics = { path = "../metrics", version = "0.11.1" }
solana-sdk = { path = "../sdk", version = "0.11.0" } solana-sdk = { path = "../sdk", version = "0.11.1" }
[features] [features]
chacha = [] chacha = []

View File

@ -2,7 +2,8 @@
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018" edition = "2018"
name = "solana-genesis" name = "solana-genesis"
version = "0.11.0" description = "Blockchain, Rebuilt for Scale"
version = "0.11.1"
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0" license = "Apache-2.0"
homepage = "https://solana.com/" homepage = "https://solana.com/"
@ -10,8 +11,8 @@ homepage = "https://solana.com/"
[dependencies] [dependencies]
clap = "2.32.0" clap = "2.32.0"
serde_json = "1.0.10" serde_json = "1.0.10"
solana = { path = "..", version = "0.11.0" } solana = { path = "..", version = "0.11.1" }
solana-sdk = { path = "../sdk", version = "0.11.0" } solana-sdk = { path = "../sdk", version = "0.11.1" }
[features] [features]
cuda = [] cuda = []

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-keygen" name = "solana-keygen"
version = "0.11.0" version = "0.11.1"
description = "Solana key generation utility" description = "Solana key generation utility"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -14,7 +14,7 @@ cuda = []
[dependencies] [dependencies]
dirs = "1.0.2" dirs = "1.0.2"
clap = "2.31" clap = "2.31"
solana-sdk = { path = "../sdk", version = "0.11.0" } solana-sdk = { path = "../sdk", version = "0.11.1" }
[[bin]] [[bin]]
name = "solana-keygen" name = "solana-keygen"

View File

@ -2,7 +2,8 @@
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018" edition = "2018"
name = "solana-ledger-tool" name = "solana-ledger-tool"
version = "0.11.0" description = "Blockchain, Rebuilt for Scale"
version = "0.11.1"
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0" license = "Apache-2.0"
homepage = "https://solana.com/" homepage = "https://solana.com/"
@ -10,8 +11,8 @@ homepage = "https://solana.com/"
[dependencies] [dependencies]
clap = "2.32.0" clap = "2.32.0"
serde_json = "1.0.10" serde_json = "1.0.10"
solana = { path = "..", version = "0.11.0" } solana = { path = "..", version = "0.11.1" }
solana-logger = { path = "../logger", version = "0.11.0" } solana-logger = { path = "../logger", version = "0.11.1" }
[features] [features]
cuda = [] cuda = []

View File

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

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-metrics" name = "solana-metrics"
version = "0.11.0" version = "0.11.1"
description = "Solana Metrics" description = "Solana Metrics"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -14,7 +14,7 @@ log = "0.4.2"
reqwest = "0.9.0" reqwest = "0.9.0"
lazy_static = "1.2.0" lazy_static = "1.2.0"
sys-info = "0.5.6" sys-info = "0.5.6"
solana-sdk = { path = "../sdk", version = "0.11.0" } solana-sdk = { path = "../sdk", version = "0.11.1" }
[dev-dependencies] [dev-dependencies]
rand = "0.6.1" rand = "0.6.1"

View File

@ -722,7 +722,7 @@
], ],
"orderByTime": "ASC", "orderByTime": "ASC",
"policy": "default", "policy": "default",
"query": "SELECT mean(\"duration_ms\") FROM \"$testnet\".\"autogen\".\"leader-finality\" WHERE $timeFilter \n\n\n", "query": "SELECT mean(\"duration_ms\") FROM \"$testnet\".\"autogen\".\"leader-confirmation\" WHERE $timeFilter \n\n\n",
"rawQuery": true, "rawQuery": true,
"refId": "A", "refId": "A",
"resultFormat": "time_series", "resultFormat": "time_series",
@ -744,7 +744,7 @@
} }
], ],
"thresholds": "", "thresholds": "",
"title": "Mean Finality", "title": "Mean Confirmation",
"type": "singlestat", "type": "singlestat",
"valueFontSize": "70%", "valueFontSize": "70%",
"valueMaps": [ "valueMaps": [
@ -833,7 +833,7 @@
], ],
"orderByTime": "ASC", "orderByTime": "ASC",
"policy": "default", "policy": "default",
"query": "SELECT median(\"duration_ms\") FROM \"$testnet\".\"autogen\".\"leader-finality\" WHERE $timeFilter \n\n\n", "query": "SELECT median(\"duration_ms\") FROM \"$testnet\".\"autogen\".\"leader-confirmation\" WHERE $timeFilter \n\n\n",
"rawQuery": true, "rawQuery": true,
"refId": "A", "refId": "A",
"resultFormat": "time_series", "resultFormat": "time_series",
@ -855,7 +855,7 @@
} }
], ],
"thresholds": "", "thresholds": "",
"title": "Median Finality", "title": "Median Confirmation",
"type": "singlestat", "type": "singlestat",
"valueFontSize": "70%", "valueFontSize": "70%",
"valueMaps": [ "valueMaps": [
@ -944,7 +944,7 @@
], ],
"orderByTime": "ASC", "orderByTime": "ASC",
"policy": "default", "policy": "default",
"query": "SELECT min(\"duration_ms\") FROM \"$testnet\".\"autogen\".\"leader-finality\" WHERE $timeFilter \n\n\n", "query": "SELECT min(\"duration_ms\") FROM \"$testnet\".\"autogen\".\"leader-confirmation\" WHERE $timeFilter \n\n\n",
"rawQuery": true, "rawQuery": true,
"refId": "A", "refId": "A",
"resultFormat": "time_series", "resultFormat": "time_series",
@ -966,7 +966,7 @@
} }
], ],
"thresholds": "", "thresholds": "",
"title": "Min Finality", "title": "Min Confirmation",
"type": "singlestat", "type": "singlestat",
"valueFontSize": "70%", "valueFontSize": "70%",
"valueMaps": [ "valueMaps": [
@ -1055,7 +1055,7 @@
], ],
"orderByTime": "ASC", "orderByTime": "ASC",
"policy": "default", "policy": "default",
"query": "SELECT max(\"duration_ms\") FROM \"$testnet\".\"autogen\".\"leader-finality\" WHERE $timeFilter \n\n\n", "query": "SELECT max(\"duration_ms\") FROM \"$testnet\".\"autogen\".\"leader-confirmation\" WHERE $timeFilter \n\n\n",
"rawQuery": true, "rawQuery": true,
"refId": "A", "refId": "A",
"resultFormat": "time_series", "resultFormat": "time_series",
@ -1077,7 +1077,7 @@
} }
], ],
"thresholds": "", "thresholds": "",
"title": "Max Finality", "title": "Max Confirmation",
"type": "singlestat", "type": "singlestat",
"valueFontSize": "70%", "valueFontSize": "70%",
"valueMaps": [ "valueMaps": [
@ -1166,7 +1166,7 @@
], ],
"orderByTime": "ASC", "orderByTime": "ASC",
"policy": "default", "policy": "default",
"query": "SELECT percentile(\"duration_ms\", 99) FROM \"$testnet\".\"autogen\".\"leader-finality\" WHERE $timeFilter \n\n\n", "query": "SELECT percentile(\"duration_ms\", 99) FROM \"$testnet\".\"autogen\".\"leader-confirmation\" WHERE $timeFilter \n\n\n",
"rawQuery": true, "rawQuery": true,
"refId": "A", "refId": "A",
"resultFormat": "time_series", "resultFormat": "time_series",
@ -1188,7 +1188,7 @@
} }
], ],
"thresholds": "", "thresholds": "",
"title": "Finality (99th percentile)", "title": "Confirmation (99th percentile)",
"type": "singlestat", "type": "singlestat",
"valueFontSize": "70%", "valueFontSize": "70%",
"valueMaps": [ "valueMaps": [
@ -1651,7 +1651,7 @@
"measurement": "counter-cluster_info-vote-count", "measurement": "counter-cluster_info-vote-count",
"orderByTime": "ASC", "orderByTime": "ASC",
"policy": "autogen", "policy": "autogen",
"query": "SELECT mean(\"duration_ms\") FROM \"$testnet\".\"autogen\".\"leader-finality\" WHERE $timeFilter GROUP BY time(1s) FILL(0)\n", "query": "SELECT mean(\"duration_ms\") FROM \"$testnet\".\"autogen\".\"leader-confirmation\" WHERE $timeFilter GROUP BY time(1s) FILL(0)\n",
"rawQuery": true, "rawQuery": true,
"refId": "A", "refId": "A",
"resultFormat": "time_series", "resultFormat": "time_series",
@ -1675,7 +1675,7 @@
"thresholds": [], "thresholds": [],
"timeFrom": null, "timeFrom": null,
"timeShift": null, "timeShift": null,
"title": "Finality", "title": "Time since last Confirmation",
"tooltip": { "tooltip": {
"shared": true, "shared": true,
"sort": 0, "sort": 0,

View File

@ -154,6 +154,11 @@ case $cloudProvider in
gce) gce)
if $enableGpu; then if $enableGpu; then
# Custom Ubuntu 18.04 LTS image with CUDA 9.2 and CUDA 10.0 installed # Custom Ubuntu 18.04 LTS image with CUDA 9.2 and CUDA 10.0 installed
#
# TODO: Unfortunately this image is not public. When this becomes an issue,
# use the stock Ubuntu 18.04 image and programmatically install CUDA after the
# instance boots
#
imageName="ubuntu-1804-bionic-v20181029-with-cuda-10-and-cuda-9-2" imageName="ubuntu-1804-bionic-v20181029-with-cuda-10-and-cuda-9-2"
else else
# Upstream Ubuntu 18.04 LTS image # Upstream Ubuntu 18.04 LTS image
@ -161,23 +166,45 @@ gce)
fi fi
;; ;;
ec2) ec2)
# if $enableGpu; then
# Custom Ubuntu 18.04 LTS image with CUDA 9.2 and CUDA 10.0 installed #
# # Custom Ubuntu 18.04 LTS image with CUDA 9.2 and CUDA 10.0 installed
case $region in # (region global variable is set by cloud_SetZone) #
us-east-1) # TODO: Unfortunately these AMIs are not public. When this becomes an issue,
imageName="ami-0a8bd6fb204473f78" # use the stock Ubuntu 18.04 image and programmatically install CUDA after the
;; # instance boots
us-west-1) #
imageName="ami-07011f0795513c59d" case $region in
;; us-east-1)
us-west-2) imageName="ami-0a8bd6fb204473f78"
imageName="ami-0a11ef42b62b82b68" ;;
;; us-west-1)
*) imageName="ami-07011f0795513c59d"
usage "Unsupported region: $region" ;;
;; us-west-2)
esac imageName="ami-0a11ef42b62b82b68"
;;
*)
usage "Unsupported region: $region"
;;
esac
else
# Select an upstream Ubuntu 18.04 AMI from https://cloud-images.ubuntu.com/locator/ec2/
case $region in
us-east-1)
imageName="ami-0a313d6098716f372"
;;
us-west-1)
imageName="ami-06397100adf427136"
;;
us-west-2)
imageName="ami-0dc34f4b016c9ce49"
;;
*)
usage "Unsupported region: $region"
;;
esac
fi
;; ;;
*) *)
echo "Error: Unknown cloud provider: $cloudProvider" echo "Error: Unknown cloud provider: $cloudProvider"
@ -430,6 +457,10 @@ $(
network-config.sh \ network-config.sh \
remove-docker-interface.sh \ remove-docker-interface.sh \
if "$enableGpu"; then
cat enable-nvidia-persistence-mode.sh
fi
) )
cat > /etc/motd <<EOM cat > /etc/motd <<EOM
@ -440,6 +471,8 @@ touch /.instance-startup-complete
EOF EOF
cloud_Initialize "$prefix"
cloud_CreateInstances "$prefix" "$prefix-bootstrap-leader" 1 \ cloud_CreateInstances "$prefix" "$prefix-bootstrap-leader" 1 \
"$imageName" "$bootstrapLeaderMachineType" "$fullNodeBootDiskSizeInGb" \ "$imageName" "$bootstrapLeaderMachineType" "$fullNodeBootDiskSizeInGb" \
"$startupScript" "$bootstrapLeaderAddress" "$bootDiskType" "$startupScript" "$bootstrapLeaderAddress" "$bootDiskType"

View File

@ -35,6 +35,7 @@ Operate a configured testnet
(ignored if -s or -S is specified) (ignored if -s or -S is specified)
-r - Reuse existing node/ledger configuration from a -r - Reuse existing node/ledger configuration from a
previous |start| (ie, don't run ./mulitnode-demo/setup.sh). previous |start| (ie, don't run ./mulitnode-demo/setup.sh).
-D /path/to/programs - Deploy custom programs from this location
Note: if RUST_LOG is set in the environment it will be propogated into the Note: if RUST_LOG is set in the environment it will be propogated into the
network nodes. network nodes.
@ -59,12 +60,13 @@ sanityExtraArgs=
cargoFeatures= cargoFeatures=
skipSetup=false skipSetup=false
updateNodes=false updateNodes=false
customPrograms=
command=$1 command=$1
[[ -n $command ]] || usage [[ -n $command ]] || usage
shift shift
while getopts "h?S:s:T:t:o:f:r" opt; do while getopts "h?S:s:T:t:o:f:r:D:" opt; do
case $opt in case $opt in
h | \?) h | \?)
usage usage
@ -107,6 +109,9 @@ while getopts "h?S:s:T:t:o:f:r" opt; do
r) r)
skipSetup=true skipSetup=true
;; ;;
D)
customPrograms=$OPTARG
;;
o) o)
case $OPTARG in case $OPTARG in
noLedgerVerify|noValidatorSanity|rejectExtraNodes) noLedgerVerify|noValidatorSanity|rejectExtraNodes)
@ -146,6 +151,9 @@ build() {
$MAYBE_DOCKER bash -c " $MAYBE_DOCKER bash -c "
set -ex set -ex
scripts/cargo-install-all.sh farf \"$cargoFeatures\" scripts/cargo-install-all.sh farf \"$cargoFeatures\"
if [[ -n \"$customPrograms\" ]]; then
scripts/cargo-install-custom-programs.sh farf $customPrograms
fi
" "
) )
echo "Build took $SECONDS seconds" echo "Build took $SECONDS seconds"

View File

@ -101,6 +101,33 @@ cloud_FindInstance() {
__cloud_FindInstances "$name" __cloud_FindInstances "$name"
} }
#
# cloud_Initialize [networkName]
#
# Perform one-time initialization that may be required for the given testnet.
#
# networkName - unique name of this testnet
#
# This function will be called before |cloud_CreateInstances|
cloud_Initialize() {
declare networkName="$1"
__cloud_SshPrivateKeyCheck
(
set -x
aws ec2 delete-key-pair --region "$region" --key-name "$networkName"
aws ec2 import-key-pair --region "$region" --key-name "$networkName" \
--public-key-material file://"${sshPrivateKey}".pub
)
(
set -x
aws ec2 delete-security-group --region "$region" --group-name "$networkName" || true
aws ec2 create-security-group --region "$region" --group-name "$networkName" --description "Created automatically by $0"
rules=$(cat "$(dirname "${BASH_SOURCE[0]}")"/ec2-security-group-config.json)
aws ec2 authorize-security-group-ingress --region "$region" --group-name "$networkName" --cli-input-json "$rules"
)
}
# #
# cloud_CreateInstances [networkName] [namePrefix] [numNodes] [imageName] # cloud_CreateInstances [networkName] [namePrefix] [numNodes] [imageName]
@ -131,21 +158,13 @@ cloud_CreateInstances() {
declare optionalStartupScript="$7" declare optionalStartupScript="$7"
declare optionalAddress="$8" declare optionalAddress="$8"
__cloud_SshPrivateKeyCheck
(
set -x
aws ec2 delete-key-pair --region "$region" --key-name "$networkName"
aws ec2 import-key-pair --region "$region" --key-name "$networkName" \
--public-key-material file://"${sshPrivateKey}".pub
)
declare -a args declare -a args
args=( args=(
--key-name "$networkName" --key-name "$networkName"
--count "$numNodes" --count "$numNodes"
--region "$region" --region "$region"
--placement "AvailabilityZone=$zone" --placement "AvailabilityZone=$zone"
--security-groups testnet --security-groups "$networkName"
--image-id "$imageName" --image-id "$imageName"
--instance-type "$machineType" --instance-type "$machineType"
--tag-specifications "ResourceType=instance,Tags=[{Key=name,Value=$namePrefix}]" --tag-specifications "ResourceType=instance,Tags=[{Key=name,Value=$namePrefix}]"

View File

@ -0,0 +1,137 @@
{
"IpPermissions": [
{
"PrefixListIds": [],
"FromPort": 80,
"IpRanges": [
{
"CidrIp": "0.0.0.0/0",
"Description": "http for block explorer"
}
],
"ToPort": 80,
"IpProtocol": "tcp",
"UserIdGroupPairs": [],
"Ipv6Ranges": [
{
"CidrIpv6": "::/0",
"Description": "http for block explorer"
}
]
},
{
"PrefixListIds": [],
"FromPort": 8000,
"IpRanges": [
{
"Description": "fullnode UDP range",
"CidrIp": "0.0.0.0/0"
}
],
"ToPort": 10000,
"IpProtocol": "udp",
"UserIdGroupPairs": [],
"Ipv6Ranges": [
{
"CidrIpv6": "::/0",
"Description": "fullnode UDP range"
}
]
},
{
"PrefixListIds": [],
"FromPort": 22,
"IpRanges": [
{
"CidrIp": "0.0.0.0/0",
"Description": "ssh"
}
],
"ToPort": 22,
"IpProtocol": "tcp",
"UserIdGroupPairs": [],
"Ipv6Ranges": [
{
"CidrIpv6": "::/0",
"Description": "ssh"
}
]
},
{
"PrefixListIds": [],
"FromPort": 873,
"IpRanges": [
{
"Description": "rsync",
"CidrIp": "0.0.0.0/0"
}
],
"ToPort": 873,
"IpProtocol": "tcp",
"UserIdGroupPairs": [],
"Ipv6Ranges": [
{
"CidrIpv6": "::/0",
"Description": "rsync"
}
]
},
{
"PrefixListIds": [],
"FromPort": 3001,
"IpRanges": [
{
"Description": "blockexplorer API port",
"CidrIp": "0.0.0.0/0"
}
],
"ToPort": 3001,
"IpProtocol": "tcp",
"UserIdGroupPairs": [],
"Ipv6Ranges": [
{
"CidrIpv6": "::/0",
"Description": "blockexplorer API port"
}
]
},
{
"PrefixListIds": [],
"FromPort": 8000,
"IpRanges": [
{
"Description": "fullnode TCP range",
"CidrIp": "0.0.0.0/0"
}
],
"ToPort": 10000,
"IpProtocol": "tcp",
"UserIdGroupPairs": [],
"Ipv6Ranges": [
{
"CidrIpv6": "::/0",
"Description": "fullnode TCP range"
}
]
},
{
"PrefixListIds": [],
"FromPort": 8,
"IpRanges": [
{
"CidrIp": "0.0.0.0/0",
"Description": "allow ping"
}
],
"ToPort": -1,
"IpProtocol": "icmp",
"UserIdGroupPairs": [],
"Ipv6Ranges": [
{
"CidrIpv6": "::/0",
"Description": "allow ping"
}
]
}
]
}

View File

@ -0,0 +1,2 @@
#!/usr/bin/env bash
nvidia-smi -pm ENABLED || true

View File

@ -76,6 +76,21 @@ cloud_FindInstance() {
__cloud_FindInstances "name=$name" __cloud_FindInstances "name=$name"
} }
#
# cloud_Initialize [networkName]
#
# Perform one-time initialization that may be required for the given testnet.
#
# networkName - unique name of this testnet
#
# This function will be called before |cloud_CreateInstances|
cloud_Initialize() {
declare networkName="$1"
# ec2-provider.sh creates firewall rules programmatically, should do the same
# here.
echo "TODO: create $networkName firewall rules programmatically instead of assuming the 'testnet' tag exists"
}
# #
# cloud_CreateInstances [networkName] [namePrefix] [numNodes] [imageName] # cloud_CreateInstances [networkName] [namePrefix] [numNodes] [imageName]
# [machineType] [bootDiskSize] [enableGpu] # [machineType] [bootDiskSize] [enableGpu]

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-netutil" name = "solana-netutil"
version = "0.11.0" version = "0.11.1"
description = "Solana Network Utilities" description = "Solana Network Utilities"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -18,7 +18,7 @@ reqwest = "0.9.0"
socket2 = "0.3.8" socket2 = "0.3.8"
[dev-dependencies] [dev-dependencies]
solana-logger = { path = "../logger", version = "0.11.0" } solana-logger = { path = "../logger", version = "0.11.1" }
[lib] [lib]
name = "solana_netutil" name = "solana_netutil"

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-bpf-noop" name = "solana-bpf-noop"
version = "0.11.0" version = "0.11.1"
description = "Solana BPF noop program" description = "Solana BPF noop program"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -9,4 +9,4 @@ homepage = "https://solana.com/"
[dependencies] [dependencies]
rbpf = "0.1.0" rbpf = "0.1.0"
solana-sdk = { path = "../../../../sdk", version = "0.11.0" } solana-sdk = { path = "../../../../sdk", version = "0.11.1" }

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-bpfloader" name = "solana-bpfloader"
version = "0.11.0" version = "0.11.1"
description = "Solana BPF Loader" description = "Solana BPF Loader"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -19,8 +19,8 @@ libc = "0.2.45"
log = "0.4.2" log = "0.4.2"
solana_rbpf = "=0.1.5" solana_rbpf = "=0.1.5"
serde = "1.0.82" serde = "1.0.82"
solana-logger = { path = "../../../logger", version = "0.11.0" } solana-logger = { path = "../../../logger", version = "0.11.1" }
solana-sdk = { path = "../../../sdk", version = "0.11.0" } solana-sdk = { path = "../../../sdk", version = "0.11.1" }
[lib] [lib]
name = "solana_bpf_loader" name = "solana_bpf_loader"

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-budget-program" name = "solana-budget-program"
version = "0.11.0" version = "0.11.1"
description = "Solana budget program" description = "Solana budget program"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -14,8 +14,8 @@ chrono = { version = "0.4.0", features = ["serde"] }
log = "0.4.2" log = "0.4.2"
serde = "1.0.82" serde = "1.0.82"
serde_derive = "1.0.82" serde_derive = "1.0.82"
solana-logger = { path = "../../../logger", version = "0.11.0" } solana-logger = { path = "../../../logger", version = "0.11.1" }
solana-sdk = { path = "../../../sdk", version = "0.11.0" } solana-sdk = { path = "../../../sdk", version = "0.11.1" }
[lib] [lib]
name = "solana_budget_program" name = "solana_budget_program"

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-erc20" name = "solana-erc20"
version = "0.11.0" version = "0.11.1"
description = "Solana reference erc20 program" description = "Solana reference erc20 program"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -13,8 +13,8 @@ bincode = "1.0.0"
log = "0.4.2" log = "0.4.2"
serde = "1.0.82" serde = "1.0.82"
serde_derive = "1.0.82" serde_derive = "1.0.82"
solana-logger = { path = "../../../logger", version = "0.11.0" } solana-logger = { path = "../../../logger", version = "0.11.1" }
solana-sdk = { path = "../../../sdk", version = "0.11.0" } solana-sdk = { path = "../../../sdk", version = "0.11.1" }
[lib] [lib]
name = "solana_erc20" name = "solana_erc20"

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-lualoader" name = "solana-lualoader"
version = "0.11.0" version = "0.11.1"
description = "Solana Lua Loader" description = "Solana Lua Loader"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -14,8 +14,8 @@ log = "0.4.2"
rlua = "0.15.2" rlua = "0.15.2"
serde = "1.0.82" serde = "1.0.82"
serde_derive = "1.0.82" serde_derive = "1.0.82"
solana-logger = { path = "../../../logger", version = "0.11.0" } solana-logger = { path = "../../../logger", version = "0.11.1" }
solana-sdk = { path = "../../../sdk", version = "0.11.0" } solana-sdk = { path = "../../../sdk", version = "0.11.1" }
[dev-dependencies] [dev-dependencies]
bincode = "1.0.0" bincode = "1.0.0"

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-native-loader" name = "solana-native-loader"
version = "0.11.0" version = "0.11.1"
description = "Solana Native Loader" description = "Solana Native Loader"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -13,7 +13,7 @@ bincode = "1.0.0"
libc = "0.2.45" libc = "0.2.45"
libloading = "0.5.0" libloading = "0.5.0"
log = "0.4.2" log = "0.4.2"
solana-sdk = { path = "../../../sdk", version = "0.11.0" } solana-sdk = { path = "../../../sdk", version = "0.11.1" }
[lib] [lib]
name = "solana_native_loader" name = "solana_native_loader"

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-noop" name = "solana-noop"
version = "0.11.0" version = "0.11.1"
description = "Solana noop program" description = "Solana noop program"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -9,8 +9,8 @@ homepage = "https://solana.com/"
edition = "2018" edition = "2018"
[dependencies] [dependencies]
solana-sdk = { path = "../../../sdk", version = "0.11.0" } solana-sdk = { path = "../../../sdk", version = "0.11.1" }
solana-logger = { path = "../../../logger", version = "0.11.0" } solana-logger = { path = "../../../logger", version = "0.11.1" }
log = "0.4.2" log = "0.4.2"
[lib] [lib]

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-storage-program" name = "solana-storage-program"
version = "0.11.0" version = "0.11.1"
description = "Solana storage program" description = "Solana storage program"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -13,8 +13,8 @@ bincode = "1.0.0"
log = "0.4.2" log = "0.4.2"
serde = "1.0.27" serde = "1.0.27"
serde_derive = "1.0.27" serde_derive = "1.0.27"
solana-logger = { path = "../../../logger", version = "0.11.0" } solana-logger = { path = "../../../logger", version = "0.11.1" }
solana-sdk = { path = "../../../sdk", version = "0.11.0" } solana-sdk = { path = "../../../sdk", version = "0.11.1" }
[lib] [lib]
name = "solana_storage_program" name = "solana_storage_program"

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-system-program" name = "solana-system-program"
version = "0.11.0" version = "0.11.1"
description = "Solana system program" description = "Solana system program"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -12,7 +12,7 @@ edition = "2018"
bincode = "1.0.0" bincode = "1.0.0"
log = "0.4.2" log = "0.4.2"
serde = "1.0.27" serde = "1.0.27"
solana-sdk = { path = "../../../sdk", version = "0.11.0" } solana-sdk = { path = "../../../sdk", version = "0.11.1" }
[lib] [lib]
name = "solana_system_program" name = "solana_system_program"

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-vote-program" name = "solana-vote-program"
version = "0.11.0" version = "0.11.1"
description = "Solana vote program" description = "Solana vote program"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -13,9 +13,9 @@ bincode = "1.0.0"
log = "0.4.2" log = "0.4.2"
serde = "1.0.82" serde = "1.0.82"
serde_derive = "1.0.82" serde_derive = "1.0.82"
solana-logger = { path = "../../../logger", version = "0.11.0" } solana-logger = { path = "../../../logger", version = "0.11.1" }
solana-metrics = { path = "../../../metrics", version = "0.11.0" } solana-metrics = { path = "../../../metrics", version = "0.11.1" }
solana-sdk = { path = "../../../sdk", version = "0.11.0" } solana-sdk = { path = "../../../sdk", version = "0.11.1" }
[lib] [lib]
name = "solana_vote_program" name = "solana_vote_program"

View File

@ -2,7 +2,7 @@
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018" edition = "2018"
name = "solana-replicator" name = "solana-replicator"
version = "0.11.0" version = "0.11.1"
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0" license = "Apache-2.0"
homepage = "https://solana.com/" homepage = "https://solana.com/"
@ -10,10 +10,10 @@ homepage = "https://solana.com/"
[dependencies] [dependencies]
clap = "2.32.0" clap = "2.32.0"
serde_json = "1.0.10" serde_json = "1.0.10"
solana = { path = "..", version = "0.11.0" } solana = { path = "..", version = "0.11.1" }
solana-logger = { path = "../logger", version = "0.11.0" } solana-logger = { path = "../logger", version = "0.11.1" }
solana-fullnode-config = { path = "../fullnode-config", version = "0.11.0" } solana-fullnode-config = { path = "../fullnode-config", version = "0.11.1" }
solana-sdk = { path = "../sdk", version = "0.11.0" } solana-sdk = { path = "../sdk", version = "0.11.1" }
[features] [features]
chacha = ["solana/chacha"] chacha = ["solana/chacha"]

View File

@ -0,0 +1,30 @@
#!/usr/bin/env bash
#
# This script will install all cargo workspace libraries found in
# `programDir` as native programs.
set -e
# Directory to install libraries into
installDir="$(mkdir -p "$1"; cd "$1"; pwd)"
# Where to find custom programs
programDir="$2"
(
set -x
cd "$programDir"
cargo build --all --release
)
for dir in "$programDir"/*; do
for program in $programDir/target/release/deps/lib"$(basename "$dir")".{so,dylib,dll}; do
if [[ -f $program ]]; then
(
set -x
mkdir -p "$installDir/bin/deps"
rm -f "$installDir/bin/deps/$(basename "$program")"
cp -v "$program" "$installDir"/bin/deps
)
fi
done
done

View File

@ -2,7 +2,6 @@
# #
# Send a metrics datapoint # Send a metrics datapoint
# #
set -e
point=$1 point=$1
if [[ -z $point ]]; then if [[ -z $point ]]; then
@ -18,3 +17,4 @@ fi
echo "https://metrics.solana.com:8086/write?db=${INFLUX_DATABASE}&u=${INFLUX_USERNAME}&p=${INFLUX_PASSWORD}" \ echo "https://metrics.solana.com:8086/write?db=${INFLUX_DATABASE}&u=${INFLUX_USERNAME}&p=${INFLUX_PASSWORD}" \
| xargs curl --max-time 5 -XPOST --data-binary "$point" | xargs curl --max-time 5 -XPOST --data-binary "$point"
exit 0

View File

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

View File

@ -4,17 +4,10 @@ set -ex
cd "$(dirname "$0")" cd "$(dirname "$0")"
eval "$(../../ci/channel-info.sh)" eval "$(../../ci/channel-info.sh)"
if [[ $BUILDKITE_BRANCH = "$STABLE_CHANNEL" ]]; then
CHANNEL=stable
elif [[ $BUILDKITE_BRANCH = "$EDGE_CHANNEL" ]]; then
CHANNEL=edge
elif [[ $BUILDKITE_BRANCH = "$BETA_CHANNEL" ]]; then
CHANNEL=beta
fi
if [[ -z $CHANNEL ]]; then if [[ -z $CHANNEL ]]; then
echo Unable to determine channel to publish into, exiting. echo Unable to determine channel to publish into, exiting.
exit 1 echo "^^^ +++"
exit 0
fi fi
rm -rf usr/ rm -rf usr/
@ -23,7 +16,7 @@ rm -rf usr/
cp -f entrypoint.sh usr/bin/solana-entrypoint.sh cp -f entrypoint.sh usr/bin/solana-entrypoint.sh
docker build -t solanalabs/solana:$CHANNEL . docker build -t solanalabs/solana:"$CHANNEL" .
maybeEcho= maybeEcho=
if [[ -z $CI ]]; then if [[ -z $CI ]]; then
@ -37,4 +30,4 @@ else
fi fi
) )
fi fi
$maybeEcho docker push solanalabs/solana:$CHANNEL $maybeEcho docker push solanalabs/solana:"$CHANNEL"

View File

@ -94,8 +94,8 @@ pub struct Bank {
/// FIFO queue of `last_id` items /// FIFO queue of `last_id` items
last_ids: RwLock<StatusDeque<Result<()>>>, last_ids: RwLock<StatusDeque<Result<()>>>,
// The latest finality time for the network // The latest confirmation time for the network
finality_time: AtomicUsize, confirmation_time: AtomicUsize,
// Mapping of account ids to Subscriber ids and sinks to notify on userdata update // Mapping of account ids to Subscriber ids and sinks to notify on userdata update
account_subscriptions: RwLock<HashMap<Pubkey, HashMap<Pubkey, Sink<Account>>>>, account_subscriptions: RwLock<HashMap<Pubkey, HashMap<Pubkey, Sink<Account>>>>,
@ -115,7 +115,7 @@ impl Default for Bank {
Bank { Bank {
accounts: Accounts::default(), accounts: Accounts::default(),
last_ids: RwLock::new(StatusDeque::default()), last_ids: RwLock::new(StatusDeque::default()),
finality_time: AtomicUsize::new(std::usize::MAX), confirmation_time: AtomicUsize::new(std::usize::MAX),
account_subscriptions: RwLock::new(HashMap::new()), account_subscriptions: RwLock::new(HashMap::new()),
signature_subscriptions: RwLock::new(HashMap::new()), signature_subscriptions: RwLock::new(HashMap::new()),
leader_scheduler: Arc::new(RwLock::new(LeaderScheduler::default())), leader_scheduler: Arc::new(RwLock::new(LeaderScheduler::default())),
@ -316,14 +316,14 @@ impl Bank {
} }
/// Looks through a list of tick heights and stakes, and finds the latest /// Looks through a list of tick heights and stakes, and finds the latest
/// tick that has achieved finality /// tick that has achieved confirmation
pub fn get_finality_timestamp( pub fn get_confirmation_timestamp(
&self, &self,
ticks_and_stakes: &mut [(u64, u64)], ticks_and_stakes: &mut [(u64, u64)],
supermajority_stake: u64, supermajority_stake: u64,
) -> Option<u64> { ) -> Option<u64> {
let last_ids = self.last_ids.read().unwrap(); let last_ids = self.last_ids.read().unwrap();
last_ids.get_finality_timestamp(ticks_and_stakes, supermajority_stake) last_ids.get_confirmation_timestamp(ticks_and_stakes, supermajority_stake)
} }
/// Tell the bank which Entry IDs exist on the ledger. This function /// Tell the bank which Entry IDs exist on the ledger. This function
@ -871,12 +871,13 @@ impl Bank {
self.accounts.hash_internal_state() self.accounts.hash_internal_state()
} }
pub fn finality(&self) -> usize { pub fn confirmation_time(&self) -> usize {
self.finality_time.load(Ordering::Relaxed) self.confirmation_time.load(Ordering::Relaxed)
} }
pub fn set_finality(&self, finality: usize) { pub fn set_confirmation_time(&self, confirmation: usize) {
self.finality_time.store(finality, Ordering::Relaxed); self.confirmation_time
.store(confirmation, Ordering::Relaxed);
} }
fn send_account_notifications( fn send_account_notifications(
@ -1403,11 +1404,11 @@ mod tests {
assert_eq!(bank0.hash_internal_state(), bank1.hash_internal_state()); assert_eq!(bank0.hash_internal_state(), bank1.hash_internal_state());
} }
#[test] #[test]
fn test_finality() { fn test_confirmation_time() {
let def_bank = Bank::default(); let def_bank = Bank::default();
assert_eq!(def_bank.finality(), std::usize::MAX); assert_eq!(def_bank.confirmation_time(), std::usize::MAX);
def_bank.set_finality(90); def_bank.set_confirmation_time(90);
assert_eq!(def_bank.finality(), 90); assert_eq!(def_bank.confirmation_time(), 90);
} }
#[test] #[test]
fn test_interleaving_locks() { fn test_interleaving_locks() {

View File

@ -3,7 +3,7 @@
//! can do its processing in parallel with signature verification on the GPU. //! can do its processing in parallel with signature verification on the GPU.
use crate::bank::Bank; use crate::bank::Bank;
use crate::compute_leader_finality_service::ComputeLeaderFinalityService; use crate::compute_leader_confirmation_service::ComputeLeaderConfirmationService;
use crate::counter::Counter; use crate::counter::Counter;
use crate::entry::Entry; use crate::entry::Entry;
use crate::packet::Packets; use crate::packet::Packets;
@ -40,7 +40,7 @@ pub struct BankingStage {
/// Handle to the stage's thread. /// Handle to the stage's thread.
bank_thread_hdls: Vec<JoinHandle<Option<BankingStageReturnType>>>, bank_thread_hdls: Vec<JoinHandle<Option<BankingStageReturnType>>>,
poh_service: PohService, poh_service: PohService,
compute_finality_service: ComputeLeaderFinalityService, compute_confirmation_service: ComputeLeaderConfirmationService,
} }
impl BankingStage { impl BankingStage {
@ -64,8 +64,8 @@ impl BankingStage {
// Once an entry has been recorded, its last_id is registered with the bank. // Once an entry has been recorded, its last_id is registered with the bank.
let poh_service = PohService::new(poh_recorder.clone(), config); let poh_service = PohService::new(poh_recorder.clone(), config);
// Single thread to compute finality // Single thread to compute confirmation
let compute_finality_service = ComputeLeaderFinalityService::new( let compute_confirmation_service = ComputeLeaderConfirmationService::new(
bank.clone(), bank.clone(),
leader_id, leader_id,
poh_service.poh_exit.clone(), poh_service.poh_exit.clone(),
@ -120,7 +120,7 @@ impl BankingStage {
Self { Self {
bank_thread_hdls, bank_thread_hdls,
poh_service, poh_service,
compute_finality_service, compute_confirmation_service,
}, },
entry_receiver, entry_receiver,
) )
@ -239,7 +239,7 @@ impl Service for BankingStage {
} }
} }
self.compute_finality_service.join()?; self.compute_confirmation_service.join()?;
let poh_return_value = self.poh_service.join()?; let poh_return_value = self.poh_service.join()?;
match poh_return_value { match poh_return_value {

View File

@ -1,5 +1,5 @@
//! The `compute_leader_finality_service` module implements the tools necessary //! The `compute_leader_confirmation_service` module implements the tools necessary
//! to generate a thread which regularly calculates the last finality times //! to generate a thread which regularly calculates the last confirmation times
//! observed by the leader //! observed by the leader
use crate::bank::Bank; use crate::bank::Bank;
@ -17,23 +17,23 @@ use std::thread::{self, Builder, JoinHandle};
use std::time::Duration; use std::time::Duration;
#[derive(Debug, PartialEq, Eq)] #[derive(Debug, PartialEq, Eq)]
pub enum FinalityError { pub enum ConfirmationError {
NoValidSupermajority, NoValidSupermajority,
} }
pub const COMPUTE_FINALITY_MS: u64 = 100; pub const COMPUTE_CONFIRMATION_MS: u64 = 100;
pub struct ComputeLeaderFinalityService { pub struct ComputeLeaderConfirmationService {
compute_finality_thread: JoinHandle<()>, compute_confirmation_thread: JoinHandle<()>,
} }
impl ComputeLeaderFinalityService { impl ComputeLeaderConfirmationService {
fn get_last_supermajority_timestamp( fn get_last_supermajority_timestamp(
bank: &Arc<Bank>, bank: &Arc<Bank>,
leader_id: Pubkey, leader_id: Pubkey,
now: u64, now: u64,
last_valid_validator_timestamp: u64, last_valid_validator_timestamp: u64,
) -> result::Result<u64, FinalityError> { ) -> result::Result<u64, ConfirmationError> {
let mut total_stake = 0; let mut total_stake = 0;
let mut ticks_and_stakes: Vec<(u64, u64)> = { let mut ticks_and_stakes: Vec<(u64, u64)> = {
@ -72,14 +72,14 @@ impl ComputeLeaderFinalityService {
let super_majority_stake = (2 * total_stake) / 3; let super_majority_stake = (2 * total_stake) / 3;
if let Some(last_valid_validator_timestamp) = if let Some(last_valid_validator_timestamp) =
bank.get_finality_timestamp(&mut ticks_and_stakes, super_majority_stake) bank.get_confirmation_timestamp(&mut ticks_and_stakes, super_majority_stake)
{ {
return Ok(last_valid_validator_timestamp); return Ok(last_valid_validator_timestamp);
} }
if last_valid_validator_timestamp != 0 { if last_valid_validator_timestamp != 0 {
submit( submit(
influxdb::Point::new(&"leader-finality") influxdb::Point::new(&"leader-confirmation")
.add_field( .add_field(
"duration_ms", "duration_ms",
influxdb::Value::Integer((now - last_valid_validator_timestamp) as i64), influxdb::Value::Integer((now - last_valid_validator_timestamp) as i64),
@ -88,10 +88,10 @@ impl ComputeLeaderFinalityService {
); );
} }
Err(FinalityError::NoValidSupermajority) Err(ConfirmationError::NoValidSupermajority)
} }
pub fn compute_finality( pub fn compute_confirmation(
bank: &Arc<Bank>, bank: &Arc<Bank>,
leader_id: Pubkey, leader_id: Pubkey,
last_valid_validator_timestamp: &mut u64, last_valid_validator_timestamp: &mut u64,
@ -103,53 +103,60 @@ impl ComputeLeaderFinalityService {
now, now,
*last_valid_validator_timestamp, *last_valid_validator_timestamp,
) { ) {
let finality_ms = now - super_majority_timestamp; let confirmation_ms = now - super_majority_timestamp;
*last_valid_validator_timestamp = super_majority_timestamp; *last_valid_validator_timestamp = super_majority_timestamp;
bank.set_finality((now - *last_valid_validator_timestamp) as usize); bank.set_confirmation_time((now - *last_valid_validator_timestamp) as usize);
submit( submit(
influxdb::Point::new(&"leader-finality") influxdb::Point::new(&"leader-confirmation")
.add_field("duration_ms", influxdb::Value::Integer(finality_ms as i64)) .add_field(
"duration_ms",
influxdb::Value::Integer(confirmation_ms as i64),
)
.to_owned(), .to_owned(),
); );
} }
} }
/// Create a new ComputeLeaderFinalityService for computing finality. /// Create a new ComputeLeaderConfirmationService for computing confirmation.
pub fn new(bank: Arc<Bank>, leader_id: Pubkey, exit: Arc<AtomicBool>) -> Self { pub fn new(bank: Arc<Bank>, leader_id: Pubkey, exit: Arc<AtomicBool>) -> Self {
let compute_finality_thread = Builder::new() let compute_confirmation_thread = Builder::new()
.name("solana-leader-finality-stage".to_string()) .name("solana-leader-confirmation-stage".to_string())
.spawn(move || { .spawn(move || {
let mut last_valid_validator_timestamp = 0; let mut last_valid_validator_timestamp = 0;
loop { loop {
if exit.load(Ordering::Relaxed) { if exit.load(Ordering::Relaxed) {
break; break;
} }
Self::compute_finality(&bank, leader_id, &mut last_valid_validator_timestamp); Self::compute_confirmation(
sleep(Duration::from_millis(COMPUTE_FINALITY_MS)); &bank,
leader_id,
&mut last_valid_validator_timestamp,
);
sleep(Duration::from_millis(COMPUTE_CONFIRMATION_MS));
} }
}) })
.unwrap(); .unwrap();
(ComputeLeaderFinalityService { (ComputeLeaderConfirmationService {
compute_finality_thread, compute_confirmation_thread,
}) })
} }
} }
impl Service for ComputeLeaderFinalityService { impl Service for ComputeLeaderConfirmationService {
type JoinReturnType = (); type JoinReturnType = ();
fn join(self) -> thread::Result<()> { fn join(self) -> thread::Result<()> {
self.compute_finality_thread.join() self.compute_confirmation_thread.join()
} }
} }
#[cfg(test)] #[cfg(test)]
pub mod tests { pub mod tests {
use crate::bank::Bank; use crate::bank::Bank;
use crate::compute_leader_finality_service::ComputeLeaderFinalityService; use crate::compute_leader_confirmation_service::ComputeLeaderConfirmationService;
use crate::create_vote_account::*; use crate::create_vote_account::*;
use crate::mint::Mint; use crate::mint::Mint;
@ -164,7 +171,7 @@ pub mod tests {
use std::time::Duration; use std::time::Duration;
#[test] #[test]
fn test_compute_finality() { fn test_compute_confirmation() {
solana_logger::setup(); solana_logger::setup();
let mint = Mint::new(1234); let mint = Mint::new(1234);
@ -206,14 +213,14 @@ pub mod tests {
}) })
.collect(); .collect();
// There isn't 2/3 consensus, so the bank's finality value should be the default // There isn't 2/3 consensus, so the bank's confirmation value should be the default
let mut last_finality_time = 0; let mut last_confirmation_time = 0;
ComputeLeaderFinalityService::compute_finality( ComputeLeaderConfirmationService::compute_confirmation(
&bank, &bank,
dummy_leader_id, dummy_leader_id,
&mut last_finality_time, &mut last_confirmation_time,
); );
assert_eq!(bank.finality(), std::usize::MAX); assert_eq!(bank.confirmation_time(), std::usize::MAX);
// Get another validator to vote, so we now have 2/3 consensus // Get another validator to vote, so we now have 2/3 consensus
let vote_account = &vote_accounts[7]; let vote_account = &vote_accounts[7];
@ -221,12 +228,12 @@ pub mod tests {
let vote_tx = Transaction::vote_new(&vote_account, vote, ids[6], 0); let vote_tx = Transaction::vote_new(&vote_account, vote, ids[6], 0);
bank.process_transaction(&vote_tx).unwrap(); bank.process_transaction(&vote_tx).unwrap();
ComputeLeaderFinalityService::compute_finality( ComputeLeaderConfirmationService::compute_confirmation(
&bank, &bank,
dummy_leader_id, dummy_leader_id,
&mut last_finality_time, &mut last_confirmation_time,
); );
assert!(bank.finality() != std::usize::MAX); assert!(bank.confirmation_time() != std::usize::MAX);
assert!(last_finality_time > 0); assert!(last_confirmation_time > 0);
} }
} }

View File

@ -32,7 +32,7 @@ pub mod create_vote_account;
#[macro_use] #[macro_use]
pub mod contact_info; pub mod contact_info;
pub mod cluster_info; pub mod cluster_info;
pub mod compute_leader_finality_service; pub mod compute_leader_confirmation_service;
pub mod db_ledger; pub mod db_ledger;
pub mod db_window; pub mod db_window;
pub mod entry; pub mod entry;

View File

@ -25,7 +25,7 @@ use std::thread::{self, Builder, JoinHandle};
use std::time::Duration; use std::time::Duration;
use std::time::Instant; use std::time::Instant;
pub const BLOCK_TICK_COUNT: u64 = 8; pub const BLOCK_TICK_COUNT: u64 = 4;
pub const MAX_ENTRY_RECV_PER_ITER: usize = 512; pub const MAX_ENTRY_RECV_PER_ITER: usize = 512;
#[derive(Debug, PartialEq, Eq, Clone)] #[derive(Debug, PartialEq, Eq, Clone)]

View File

@ -135,8 +135,8 @@ build_rpc_trait! {
#[rpc(meta, name = "getBalance")] #[rpc(meta, name = "getBalance")]
fn get_balance(&self, Self::Metadata, String) -> Result<u64>; fn get_balance(&self, Self::Metadata, String) -> Result<u64>;
#[rpc(meta, name = "getFinality")] #[rpc(meta, name = "getConfirmationTime")]
fn get_finality(&self, Self::Metadata) -> Result<usize>; fn get_confirmation_time(&self, Self::Metadata) -> Result<usize>;
#[rpc(meta, name = "getLastId")] #[rpc(meta, name = "getLastId")]
fn get_last_id(&self, Self::Metadata) -> Result<String>; fn get_last_id(&self, Self::Metadata) -> Result<String>;
@ -184,9 +184,9 @@ impl RpcSol for RpcSolImpl {
let pubkey = verify_pubkey(id)?; let pubkey = verify_pubkey(id)?;
meta.request_processor.get_balance(pubkey) meta.request_processor.get_balance(pubkey)
} }
fn get_finality(&self, meta: Self::Metadata) -> Result<usize> { fn get_confirmation_time(&self, meta: Self::Metadata) -> Result<usize> {
info!("get_finality rpc request received"); info!("get_confirmation_time rpc request received");
meta.request_processor.get_finality() meta.request_processor.get_confirmation_time()
} }
fn get_last_id(&self, meta: Self::Metadata) -> Result<String> { fn get_last_id(&self, meta: Self::Metadata) -> Result<String> {
info!("get_last_id rpc request received"); info!("get_last_id rpc request received");
@ -329,8 +329,8 @@ impl JsonRpcRequestProcessor {
let val = self.bank.get_balance(&pubkey); let val = self.bank.get_balance(&pubkey);
Ok(val) Ok(val)
} }
fn get_finality(&self) -> Result<usize> { fn get_confirmation_time(&self) -> Result<usize> {
Ok(self.bank.finality()) Ok(self.bank.confirmation_time())
} }
fn get_last_id(&self) -> Result<String> { fn get_last_id(&self) -> Result<String> {
let id = self.bank.last_id(); let id = self.bank.last_id();
@ -612,11 +612,11 @@ mod tests {
} }
#[test] #[test]
fn test_rpc_get_finality() { fn test_rpc_get_confirmation() {
let bob_pubkey = Keypair::new().pubkey(); let bob_pubkey = Keypair::new().pubkey();
let (io, meta, _last_id, _alice_keypair) = start_rpc_handler_with_tx(bob_pubkey); let (io, meta, _last_id, _alice_keypair) = start_rpc_handler_with_tx(bob_pubkey);
let req = format!(r#"{{"jsonrpc":"2.0","id":1,"method":"getFinality"}}"#); let req = format!(r#"{{"jsonrpc":"2.0","id":1,"method":"getConfirmationTime"}}"#);
let res = io.handle_request_sync(&req, meta); let res = io.handle_request_sync(&req, meta);
let expected = format!(r#"{{"jsonrpc":"2.0","result":18446744073709551615,"id":1}}"#); let expected = format!(r#"{{"jsonrpc":"2.0","result":18446744073709551615,"id":1}}"#);
let expected: Response = let expected: Response =

View File

@ -44,7 +44,7 @@ pub enum RpcRequest {
ConfirmTransaction, ConfirmTransaction,
GetAccountInfo, GetAccountInfo,
GetBalance, GetBalance,
GetFinality, GetConfirmationTime,
GetLastId, GetLastId,
GetSignatureStatus, GetSignatureStatus,
GetTransactionCount, GetTransactionCount,
@ -89,7 +89,7 @@ impl RpcRequest {
RpcRequest::ConfirmTransaction => "confirmTransaction", RpcRequest::ConfirmTransaction => "confirmTransaction",
RpcRequest::GetAccountInfo => "getAccountInfo", RpcRequest::GetAccountInfo => "getAccountInfo",
RpcRequest::GetBalance => "getBalance", RpcRequest::GetBalance => "getBalance",
RpcRequest::GetFinality => "getFinality", RpcRequest::GetConfirmationTime => "getConfirmationTime",
RpcRequest::GetLastId => "getLastId", RpcRequest::GetLastId => "getLastId",
RpcRequest::GetSignatureStatus => "getSignatureStatus", RpcRequest::GetSignatureStatus => "getSignatureStatus",
RpcRequest::GetTransactionCount => "getTransactionCount", RpcRequest::GetTransactionCount => "getTransactionCount",
@ -166,9 +166,9 @@ mod tests {
); );
assert_eq!(request["method"], "getBalance"); assert_eq!(request["method"], "getBalance");
let test_request = RpcRequest::GetFinality; let test_request = RpcRequest::GetConfirmationTime;
let request = test_request.build_request_json(1, None); let request = test_request.build_request_json(1, None);
assert_eq!(request["method"], "getFinality"); assert_eq!(request["method"], "getConfirmationTime");
assert_eq!(request["params"], json!(null)); assert_eq!(request["params"], json!(null));
let test_request = RpcRequest::GetLastId; let test_request = RpcRequest::GetLastId;

View File

@ -44,7 +44,7 @@ struct StatusEntry<T> {
/// when the id was registered, according to network time /// when the id was registered, according to network time
tick_height: u64, tick_height: u64,
/// timestamp when this id was registered, used for stats/finality /// timestamp when this id was registered, used for stats/confirmation
timestamp: u64, timestamp: u64,
/// a map of signature status, used for duplicate detection /// a map of signature status, used for duplicate detection
@ -183,14 +183,14 @@ impl<T: Clone> StatusDeque<T> {
} }
/// Looks through a list of tick heights and stakes, and finds the latest /// Looks through a list of tick heights and stakes, and finds the latest
/// tick that has achieved finality /// tick that has achieved confirmation
pub fn get_finality_timestamp( pub fn get_confirmation_timestamp(
&self, &self,
ticks_and_stakes: &mut [(u64, u64)], ticks_and_stakes: &mut [(u64, u64)],
supermajority_stake: u64, supermajority_stake: u64,
) -> Option<u64> { ) -> Option<u64> {
// Sort by tick height // Sort by tick height
ticks_and_stakes.sort_by(|a, b| a.0.cmp(&b.0)); ticks_and_stakes.sort_by(|a, b| b.0.cmp(&a.0));
let current_tick_height = self.tick_height; let current_tick_height = self.tick_height;
let mut total = 0; let mut total = 0;
for (tick_height, stake) in ticks_and_stakes.iter() { for (tick_height, stake) in ticks_and_stakes.iter() {

View File

@ -41,7 +41,7 @@ pub struct ThinClient {
transaction_count: u64, transaction_count: u64,
balances: HashMap<Pubkey, Account>, balances: HashMap<Pubkey, Account>,
signature_status: bool, signature_status: bool,
finality: Option<usize>, confirmation: Option<usize>,
rpc_client: RpcClient, rpc_client: RpcClient,
} }
@ -87,7 +87,7 @@ impl ThinClient {
transaction_count: 0, transaction_count: 0,
balances: HashMap::new(), balances: HashMap::new(),
signature_status: false, signature_status: false,
finality: None, confirmation: None,
} }
} }
@ -187,23 +187,23 @@ impl ThinClient {
.ok_or_else(|| io::Error::new(io::ErrorKind::Other, "AccountNotFound")) .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "AccountNotFound"))
} }
/// Request the finality from the leader node /// Request the confirmation time from the leader node
pub fn get_finality(&mut self) -> usize { pub fn get_confirmation_time(&mut self) -> usize {
trace!("get_finality"); trace!("get_confirmation_time");
let mut done = false; let mut done = false;
while !done { while !done {
debug!("get_finality send_to {}", &self.rpc_addr); debug!("get_confirmation_time send_to {}", &self.rpc_addr);
let resp = RpcRequest::GetFinality.make_rpc_request(&self.rpc_client, 1, None); let resp = RpcRequest::GetConfirmationTime.make_rpc_request(&self.rpc_client, 1, None);
if let Ok(value) = resp { if let Ok(value) = resp {
done = true; done = true;
let finality = value.as_u64().unwrap() as usize; let confirmation = value.as_u64().unwrap() as usize;
self.finality = Some(finality); self.confirmation = Some(confirmation);
} else { } else {
debug!("thin_client get_finality error: {:?}", resp); debug!("thin_client get_confirmation_time error: {:?}", resp);
} }
} }
self.finality.expect("some finality") self.confirmation.expect("some confirmation")
} }
/// Request the transaction count. If the response packet is dropped by the network, /// Request the transaction count. If the response packet is dropped by the network,
@ -477,8 +477,8 @@ mod tests {
let mut client = ThinClient::new(leader_data.rpc, leader_data.tpu, transactions_socket); let mut client = ThinClient::new(leader_data.rpc, leader_data.tpu, transactions_socket);
let transaction_count = client.transaction_count(); let transaction_count = client.transaction_count();
assert_eq!(transaction_count, 0); assert_eq!(transaction_count, 0);
let finality = client.get_finality(); let confirmation = client.get_confirmation_time();
assert_eq!(finality, 18446744073709551615); assert_eq!(confirmation, 18446744073709551615);
let last_id = client.get_last_id(); let last_id = client.get_last_id();
let signature = client let signature = client
.transfer(500, &alice.keypair(), bob_pubkey, &last_id) .transfer(500, &alice.keypair(), bob_pubkey, &last_id)

12
src/window_service.rs Normal file → Executable file
View File

@ -89,12 +89,6 @@ fn recv_window(
(p.index()?, p.meta.size) (p.index()?, p.meta.size)
}; };
submit(
influxdb::Point::new("window-service")
.add_field("last-recv", influxdb::Value::Integer(pix as i64))
.to_owned(),
);
trace!("{} window pix: {} size: {}", id, pix, meta_size); trace!("{} window pix: {} size: {}", id, pix, meta_size);
let _ = process_blob( let _ = process_blob(
@ -172,12 +166,6 @@ pub fn window_service(
let received = meta.received; let received = meta.received;
let consumed = meta.consumed; let consumed = meta.consumed;
submit(
influxdb::Point::new("window-stage")
.add_field("consumed", influxdb::Value::Integer(consumed as i64))
.to_owned(),
);
// Consumed should never be bigger than received // Consumed should never be bigger than received
assert!(consumed <= received); assert!(consumed <= received);
if received == consumed { if received == consumed {

View File

@ -714,8 +714,8 @@ fn test_multi_node_dynamic_network() {
let mut validators: Vec<_> = t2.into_iter().map(|t| t.join().unwrap()).collect(); let mut validators: Vec<_> = t2.into_iter().map(|t| t.join().unwrap()).collect();
let mut client = mk_client(&leader_data); let mut client = mk_client(&leader_data);
let mut last_finality = client.get_finality(); let mut last_confirmation = client.get_confirmation_time();
info!("Last finality {}", last_finality); info!("Last confirmation {}", last_confirmation);
let start = Instant::now(); let start = Instant::now();
let mut consecutive_success = 0; let mut consecutive_success = 0;
let mut expected_balance = leader_balance; let mut expected_balance = leader_balance;
@ -738,28 +738,28 @@ fn test_multi_node_dynamic_network() {
assert!(e.is_ok(), "err: {:?}", e); assert!(e.is_ok(), "err: {:?}", e);
let now = Instant::now(); let now = Instant::now();
let mut finality = client.get_finality(); let mut confirmation = client.get_confirmation_time();
// Need this to make sure the finality is updated // Need this to make sure the confirmation is updated
// (i.e. the node is not returning stale value) // (i.e. the node is not returning stale value)
while last_finality == finality { while last_confirmation == confirmation {
finality = client.get_finality(); confirmation = client.get_confirmation_time();
} }
while duration_as_ms(&now.elapsed()) < finality as u64 { while duration_as_ms(&now.elapsed()) < confirmation as u64 {
sleep(Duration::from_millis(100)); sleep(Duration::from_millis(100));
finality = client.get_finality() confirmation = client.get_confirmation_time()
} }
last_finality = finality; last_confirmation = confirmation;
let balance = retry_get_balance(&mut client, &bob_pubkey, Some(expected_balance)); let balance = retry_get_balance(&mut client, &bob_pubkey, Some(expected_balance));
assert_eq!(balance, Some(expected_balance)); assert_eq!(balance, Some(expected_balance));
consecutive_success += 1; consecutive_success += 1;
info!( info!(
"SUCCESS[{}] balance: {}, finality: {} ms", "SUCCESS[{}] balance: {}, confirmation: {} ms",
i, expected_balance, last_finality, i, expected_balance, last_confirmation,
); );
if consecutive_success == 10 { if consecutive_success == 10 {

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-upload-perf" name = "solana-upload-perf"
version = "0.11.0" version = "0.11.1"
description = "Metrics Upload Utility" description = "Metrics Upload Utility"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -10,7 +10,7 @@ homepage = "https://solana.com/"
[dependencies] [dependencies]
serde_json = "1.0.10" serde_json = "1.0.10"
solana-metrics = { path = "../metrics", version = "0.11.0" } solana-metrics = { path = "../metrics", version = "0.11.1" }
[[bin]] [[bin]]
name = "solana-upload-perf" name = "solana-upload-perf"

View File

@ -1,6 +1,6 @@
[package] [package]
name = "solana-vote-signer" name = "solana-vote-signer"
version = "0.0.1" version = "0.11.1"
description = "Solana Vote Signing Service" description = "Solana Vote Signing Service"
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
@ -12,8 +12,8 @@ bs58 = "0.2.0"
clap = "2.31" clap = "2.31"
log = "0.4.2" log = "0.4.2"
serde_json = "1.0.10" serde_json = "1.0.10"
solana-sdk = { path = "../sdk", version = "0.11.0" } solana-sdk = { path = "../sdk", version = "0.11.1" }
solana-metrics = { path = "../metrics", version = "0.11.0" } solana-metrics = { path = "../metrics", version = "0.11.1" }
solana-jsonrpc-core = "0.3.0" solana-jsonrpc-core = "0.3.0"
solana-jsonrpc-http-server = "0.3.0" solana-jsonrpc-http-server = "0.3.0"
solana-jsonrpc-macros = "0.3.0" solana-jsonrpc-macros = "0.3.0"

View File

@ -2,7 +2,8 @@
authors = ["Solana Maintainers <maintainers@solana.com>"] authors = ["Solana Maintainers <maintainers@solana.com>"]
edition = "2018" edition = "2018"
name = "solana-wallet" name = "solana-wallet"
version = "0.11.0" description = "Blockchain, Rebuilt for Scale"
version = "0.11.1"
repository = "https://github.com/solana-labs/solana" repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0" license = "Apache-2.0"
homepage = "https://solana.com/" homepage = "https://solana.com/"
@ -14,10 +15,10 @@ clap = "2.32.0"
chrono = { version = "0.4.0", features = ["serde"] } chrono = { version = "0.4.0", features = ["serde"] }
dirs = "1.0.2" dirs = "1.0.2"
serde_json = "1.0.10" serde_json = "1.0.10"
solana = { path = "..", version = "0.11.0" } solana = { path = "..", version = "0.11.1" }
solana-drone = { path = "../drone", version = "0.11.0" } solana-drone = { path = "../drone", version = "0.11.1" }
solana-logger = { path = "../logger", version = "0.11.0" } solana-logger = { path = "../logger", version = "0.11.1" }
solana-sdk = { path = "../sdk", version = "0.11.0" } solana-sdk = { path = "../sdk", version = "0.11.1" }
[features] [features]
cuda = [] cuda = []

View File

@ -602,7 +602,7 @@ pub fn process_command(config: &WalletConfig) -> Result<String, Box<dyn error::E
} }
// Apply time elapsed to contract // Apply time elapsed to contract
WalletCommand::TimeElapsed(to, pubkey, dt) => { WalletCommand::TimeElapsed(to, pubkey, dt) => {
let params = json!(format!("{}", config.id.pubkey())); let params = json!([format!("{}", config.id.pubkey())]);
let balance = RpcRequest::GetBalance let balance = RpcRequest::GetBalance
.make_rpc_request(&rpc_client, 1, Some(params))? .make_rpc_request(&rpc_client, 1, Some(params))?
.as_u64(); .as_u64();