From 1d68902e637da828c7e7848ac965cbf7b019bc3d Mon Sep 17 00:00:00 2001 From: kevinheavey Date: Sat, 2 Nov 2024 17:56:52 +0400 Subject: [PATCH] remove solana-sdk from solana-quic-client --- Cargo.lock | 4 ++++ programs/sbf/Cargo.lock | 5 ++++- quic-client/Cargo.toml | 6 +++++- quic-client/src/lib.rs | 6 ++---- quic-client/src/nonblocking/quic_client.rs | 10 +++++----- quic-client/src/quic_client.rs | 2 +- 6 files changed, 21 insertions(+), 12 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 8d24b8961f3fd8..ef169bc4b521f5 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -7682,9 +7682,13 @@ dependencies = [ "solana-metrics", "solana-net-utils", "solana-perf", + "solana-pubkey", + "solana-quic-definitions", "solana-rpc-client-api", "solana-sdk", + "solana-signer", "solana-streamer", + "solana-transaction-error", "thiserror", "tokio", ] diff --git a/programs/sbf/Cargo.lock b/programs/sbf/Cargo.lock index 55731ff3f20d11..b69de0da84eafd 100644 --- a/programs/sbf/Cargo.lock +++ b/programs/sbf/Cargo.lock @@ -6024,9 +6024,12 @@ dependencies = [ "solana-measure", "solana-metrics", "solana-net-utils", + "solana-pubkey", + "solana-quic-definitions", "solana-rpc-client-api", - "solana-sdk", + "solana-signer", "solana-streamer", + "solana-transaction-error", "thiserror", "tokio", ] diff --git a/quic-client/Cargo.toml b/quic-client/Cargo.toml index 428b03cb0a6892..cd25128746c37c 100644 --- a/quic-client/Cargo.toml +++ b/quic-client/Cargo.toml @@ -24,7 +24,10 @@ solana-measure = { workspace = true } solana-metrics = { workspace = true } solana-net-utils = { workspace = true } solana-rpc-client-api = { workspace = true } -solana-sdk = { workspace = true } +solana-pubkey = { workspace = true, default-features = false } +solana-signer = { workspace = true, features = ["keypair"] } +solana-quic-definitions = { workspace = true } +solana-transaction-error = { workspace = true } solana-streamer = { workspace = true } thiserror = { workspace = true } tokio = { workspace = true, features = ["full"] } @@ -33,3 +36,4 @@ tokio = { workspace = true, features = ["full"] } crossbeam-channel = { workspace = true } solana-logger = { workspace = true } solana-perf = { workspace = true } +solana-sdk = { workspace = true } diff --git a/quic-client/src/lib.rs b/quic-client/src/lib.rs index e9741777ccb6ac..9e2016441b79bf 100644 --- a/quic-client/src/lib.rs +++ b/quic-client/src/lib.rs @@ -22,10 +22,8 @@ use { }, connection_cache_stats::ConnectionCacheStats, }, - solana_sdk::{ - pubkey::Pubkey, - signature::{Keypair, Signer}, - }, + solana_pubkey::Pubkey, + solana_signer::{keypair::Keypair, Signer}, solana_streamer::{streamer::StakedNodes, tls_certificates::new_dummy_x509_certificate}, std::{ net::{IpAddr, SocketAddr}, diff --git a/quic-client/src/nonblocking/quic_client.rs b/quic-client/src/nonblocking/quic_client.rs index 0d6bede4149f69..8a21920bf5af4f 100644 --- a/quic-client/src/nonblocking/quic_client.rs +++ b/quic-client/src/nonblocking/quic_client.rs @@ -17,15 +17,15 @@ use { }, solana_measure::measure::Measure, solana_net_utils::VALIDATOR_PORT_RANGE, - solana_rpc_client_api::client_error::ErrorKind as ClientErrorKind, - solana_sdk::{ - quic::{QUIC_CONNECTION_HANDSHAKE_TIMEOUT, QUIC_KEEP_ALIVE, QUIC_MAX_TIMEOUT}, - signature::Keypair, - transport::Result as TransportResult, + solana_quic_definitions::{ + QUIC_CONNECTION_HANDSHAKE_TIMEOUT, QUIC_KEEP_ALIVE, QUIC_MAX_TIMEOUT, }, + solana_rpc_client_api::client_error::ErrorKind as ClientErrorKind, + solana_signer::keypair::Keypair, solana_streamer::{ nonblocking::quic::ALPN_TPU_PROTOCOL_ID, tls_certificates::new_dummy_x509_certificate, }, + solana_transaction_error::TransportResult, std::{ net::{IpAddr, Ipv4Addr, SocketAddr, UdpSocket}, sync::{atomic::Ordering, Arc}, diff --git a/quic-client/src/quic_client.rs b/quic-client/src/quic_client.rs index 8c8e8e5338993f..8da4ddce7a5d06 100644 --- a/quic-client/src/quic_client.rs +++ b/quic-client/src/quic_client.rs @@ -12,7 +12,7 @@ use { connection_cache_stats::ConnectionCacheStats, nonblocking::client_connection::ClientConnection as NonblockingClientConnection, }, - solana_sdk::transport::{Result as TransportResult, TransportError}, + solana_transaction_error::{TransportError, TransportResult}, std::{ net::SocketAddr, sync::{atomic::Ordering, Arc, Condvar, Mutex, MutexGuard},