deprecate FeeCalculator in BanksClients (#21056)

This commit is contained in:
Jack May
2021-10-28 16:00:09 -07:00
committed by GitHub
parent 0b8fcf0808
commit 3140d7741c
3 changed files with 36 additions and 0 deletions

View File

@ -1,3 +1,5 @@
#![allow(deprecated)]
use {
serde::{Deserialize, Serialize},
solana_sdk::{
@ -6,6 +8,7 @@ use {
commitment_config::CommitmentLevel,
fee_calculator::FeeCalculator,
hash::Hash,
message::Message,
pubkey::Pubkey,
signature::Signature,
transaction::{self, Transaction, TransactionError},
@ -30,6 +33,10 @@ pub struct TransactionStatus {
#[tarpc::service]
pub trait Banks {
async fn send_transaction_with_context(transaction: Transaction);
#[deprecated(
since = "1.9.0",
note = "Please use `get_fee_for_message_with_commitment_and_context` instead"
)]
async fn get_fees_with_commitment_and_context(
commitment: CommitmentLevel,
) -> (FeeCalculator, Hash, Slot);
@ -45,6 +52,10 @@ pub trait Banks {
address: Pubkey,
commitment: CommitmentLevel,
) -> Option<Account>;
async fn get_fee_for_message_with_commitment_and_context(
commitment: CommitmentLevel,
message: Message,
) -> Option<u64>;
}
#[cfg(test)]