rpc-http-threads cli arg (#8890)

* Add optional `rpc-http-threads` cli arg

* Update `http::ServerBuilder`threads
This commit is contained in:
tgmichel
2021-06-08 13:18:57 +02:00
committed by GitHub
parent 74793a83a5
commit a4bfd40a1b
8 changed files with 27 additions and 1 deletions
+2
View File
@@ -89,6 +89,8 @@ pub struct Configuration {
pub rpc_ipc: Option<String>,
/// Maximum number of connections for WebSockets RPC server. `None` if default.
pub rpc_ws_max_connections: Option<usize>,
/// Size of the RPC HTTP server thread pool. `None` if default.
pub rpc_http_threads: Option<usize>,
/// CORS settings for HTTP & WS servers. `None` if all origins are allowed.
pub rpc_cors: Option<Vec<String>>,
/// RPC methods to expose (by default only a safe subset or all of them).
+1
View File
@@ -381,6 +381,7 @@ fn start_rpc_servers<
config.rpc_http,
|address| sc_rpc_server::start_http(
address,
config.rpc_http_threads,
config.rpc_cors.as_ref(),
gen_handler(
deny_unsafe(&address, &config.rpc_methods),