Skip to main content

Module runtime_transport

Module runtime_transport 

Source
Expand description

Runtime transport that connects on first request, which can take either of an HTTP, WebSocket, or IPC transport. Retries are handled by a client layer (e.g., RetryBackoffLayer) when used.

Re-exportsยง

use crate::DEFAULT_USER_AGENT; ๐Ÿ”’
use crate::REQUEST_TIMEOUT; ๐Ÿ”’
use crate::provider::mpp::transport::LazyMppHttpTransport; ๐Ÿ”’
use crate::provider::mpp::transport::lazy_mpp_ws_connect; ๐Ÿ”’
use crate::provider::redact_url; ๐Ÿ”’
use alloy_json_rpc::RequestPacket; ๐Ÿ”’
use alloy_json_rpc::ResponsePacket; ๐Ÿ”’
use alloy_pubsub::PubSubConnect; ๐Ÿ”’
use alloy_pubsub::PubSubFrontend; ๐Ÿ”’
use alloy_rpc_types_engine::Claims; ๐Ÿ”’
use alloy_rpc_types_engine::JwtSecret; ๐Ÿ”’
use alloy_transport::Authorization; ๐Ÿ”’
use alloy_transport::BoxTransport; ๐Ÿ”’
use alloy_transport::TransportError; ๐Ÿ”’
use alloy_transport::TransportFut; ๐Ÿ”’
use alloy_transport::utils::guess_local_url; ๐Ÿ”’
use alloy_transport_ipc::IpcConnect; ๐Ÿ”’
use alloy_transport_ws::WsConnect; ๐Ÿ”’
use regex::Captures; ๐Ÿ”’
use regex::Regex; ๐Ÿ”’
use reqwest::header::HeaderName; ๐Ÿ”’
use reqwest::header::HeaderValue; ๐Ÿ”’
use std::error::Error as StdError; ๐Ÿ”’
use std::fmt; ๐Ÿ”’
use std::path::PathBuf; ๐Ÿ”’
use std::str::FromStr; ๐Ÿ”’
use std::sync::Arc; ๐Ÿ”’
use std::sync::LazyLock; ๐Ÿ”’
use thiserror::Error; ๐Ÿ”’
use tokio::runtime::Handle; ๐Ÿ”’
use tokio::runtime::Id; ๐Ÿ”’
use tokio::sync::RwLock; ๐Ÿ”’
use tower::Service; ๐Ÿ”’
use url::Url; ๐Ÿ”’

Structsยง

RuntimeTransport
Runtime transport that only connects on first request.
RuntimeTransportBuilder
A builder for RuntimeTransport.

Enumsยง

InnerTransport
An enum representing the different transports that can be used to connect to a runtime. Only meant to be used internally by RuntimeTransport.
RuntimeTransportError
Error type for the runtime transport.

Constantsยง

KNOWN_MPP_HOSTS ๐Ÿ”’
Known MPP-enabled RPC host suffixes.

Staticsยง

HTTP_URL_RE ๐Ÿ”’

Functionsยง

build_auth ๐Ÿ”’
is_known_mpp_endpoint ๐Ÿ”’
Returns true if url points to a known MPP-enabled RPC service.
redact_http_transport_error ๐Ÿ”’
url_to_file_path ๐Ÿ”’ Non-Windows