pub struct RpcConfig {Show 16 fields
pub laddr: Address,
pub cors_allowed_origins: Vec<CorsOrigin>,
pub cors_allowed_methods: Vec<CorsMethod>,
pub cors_allowed_headers: Vec<CorsHeader>,
pub grpc_laddr: Option<Address>,
pub grpc_max_open_connections: u64,
pub unsafe_commands: bool,
pub max_open_connections: u64,
pub max_subscription_clients: u64,
pub max_subscriptions_per_client: u64,
pub timeout_broadcast_tx_commit: Timeout,
pub max_body_bytes: u64,
pub max_header_bytes: u64,
pub tls_cert_file: Option<PathBuf>,
pub tls_key_file: Option<PathBuf>,
pub pprof_laddr: Option<Address>,
}Expand description
CometBFT config.toml file’s [rpc] section
Fields§
§laddr: AddressTCP or UNIX socket address for the RPC server to listen on
cors_allowed_origins: Vec<CorsOrigin>A list of origins a cross-domain request can be executed from
Default value [] disables cors support
Use ["*"] to allow any origin
cors_allowed_methods: Vec<CorsMethod>A list of methods the client is allowed to use with cross-domain requests
cors_allowed_headers: Vec<CorsHeader>A list of non simple headers the client is allowed to use with cross-domain requests
grpc_laddr: Option<Address>TCP or UNIX socket address for the gRPC server to listen on
NOTE: This server only supports /broadcast_tx_commit
grpc_max_open_connections: u64Maximum number of simultaneous GRPC connections.
Does not include RPC (HTTP&WebSocket) connections. See max_open_connections.
unsafe_commands: boolActivate unsafe RPC commands like /dial_seeds and /unsafe_flush_mempool
max_open_connections: u64Maximum number of simultaneous connections (including WebSocket).
Does not include gRPC connections. See grpc_max_open_connections.
max_subscription_clients: u64Maximum number of unique clientIDs that can /subscribe.
max_subscriptions_per_client: u64Maximum number of unique queries a given client can /subscribe to.
timeout_broadcast_tx_commit: TimeoutHow long to wait for a tx to be committed during /broadcast_tx_commit.
max_body_bytes: u64Maximum size of request body, in bytes
max_header_bytes: u64Maximum size of request header, in bytes
tls_cert_file: Option<PathBuf>The name of a file containing certificate that is used to create the HTTPS server.
tls_key_file: Option<PathBuf>The name of a file containing matching private key that is used to create the HTTPS server.
pprof_laddr: Option<Address>pprof listen address https://golang.org/pkg/net/http/pprof