Deprecate commitment variants (#14797)

* Deprecate commitment variants

* Add new CommitmentConfig builders

* Add helpers to avoid allowing deprecated variants

* Remove deprecated transaction-status code

* Include new commitment variants in runtime commitment; allow deprecated as long as old variants persist

* Remove deprecated banks code

* Remove deprecated variants in core; allow deprecated in rpc/rpc-subscriptions for now

* Heavier hand with rpc/rpc-subscription commitment

* Remove deprecated variants from local-cluster

* Remove deprecated variants from various tools

* Remove deprecated variants from validator

* Update docs

* Remove deprecated client code

* Add new variants to cli; remove deprecated variants as possible

* Don't send new commitment variants to old clusters

* Retain deprecated method in test_validator_saves_tower

* Fix clippy matches! suggestion for BPF solana-sdk legacy compile test

* Refactor node version check to handle commitment variants and transaction encoding

* Hide deprecated variants from cli help

* Add cli App comments
This commit is contained in:
Tyera Eulberg
2021-01-26 12:23:07 -07:00
committed by GitHub
parent e08d2e6fcc
commit ffa5c7dcc8
37 changed files with 540 additions and 322 deletions

View File

@ -34,7 +34,7 @@ fn test_cli_program_deploy_non_upgradeable() {
let faucet_addr = receiver.recv().unwrap();
let rpc_client =
RpcClient::new_with_commitment(test_validator.rpc_url(), CommitmentConfig::recent());
RpcClient::new_with_commitment(test_validator.rpc_url(), CommitmentConfig::processed());
let mut file = File::open(pathbuf.to_str().unwrap()).unwrap();
let mut program_data = Vec::new();
@ -155,7 +155,7 @@ fn test_cli_program_deploy_no_authority() {
let faucet_addr = receiver.recv().unwrap();
let rpc_client =
RpcClient::new_with_commitment(test_validator.rpc_url(), CommitmentConfig::recent());
RpcClient::new_with_commitment(test_validator.rpc_url(), CommitmentConfig::processed());
let mut file = File::open(pathbuf.to_str().unwrap()).unwrap();
let mut program_data = Vec::new();
@ -243,7 +243,7 @@ fn test_cli_program_deploy_with_authority() {
let faucet_addr = receiver.recv().unwrap();
let rpc_client =
RpcClient::new_with_commitment(test_validator.rpc_url(), CommitmentConfig::recent());
RpcClient::new_with_commitment(test_validator.rpc_url(), CommitmentConfig::processed());
let mut file = File::open(pathbuf.to_str().unwrap()).unwrap();
let mut program_data = Vec::new();
@ -574,7 +574,7 @@ fn test_cli_program_write_buffer() {
let faucet_addr = receiver.recv().unwrap();
let rpc_client =
RpcClient::new_with_commitment(test_validator.rpc_url(), CommitmentConfig::recent());
RpcClient::new_with_commitment(test_validator.rpc_url(), CommitmentConfig::processed());
let mut file = File::open(pathbuf.to_str().unwrap()).unwrap();
let mut program_data = Vec::new();
@ -829,7 +829,7 @@ fn test_cli_program_set_buffer_authority() {
let faucet_addr = receiver.recv().unwrap();
let rpc_client =
RpcClient::new_with_commitment(test_validator.rpc_url(), CommitmentConfig::recent());
RpcClient::new_with_commitment(test_validator.rpc_url(), CommitmentConfig::processed());
let mut file = File::open(pathbuf.to_str().unwrap()).unwrap();
let mut program_data = Vec::new();