RPC: Limit request payload size to 50kB
This commit is contained in:
committed by
mergify[bot]
parent
f6cda2579f
commit
32dcce0ac1
@@ -78,6 +78,8 @@ use std::{
|
||||
};
|
||||
use tokio::runtime;
|
||||
|
||||
pub const MAX_REQUEST_PAYLOAD_SIZE: usize = 50 * (1 << 10); // 50kB
|
||||
|
||||
fn new_response<T>(bank: &Bank, value: T) -> RpcResponse<T> {
|
||||
let context = RpcResponseContext { slot: bank.slot() };
|
||||
Response { context, value }
|
||||
|
Reference in New Issue
Block a user