Expand description
Limits for RPC and store parameters and payload sizes.
§Rationale
- Parameter limits are kept across all multi-value RPC parameters. This caps worst-case SQL
INclauses and keeps responses comfortably under the 4 MiB payload budget enforced in the store. - Limits are enforced both at the RPC boundary and inside the store to prevent bypasses and to avoid expensive queries even if validation is skipped earlier in the stack.
MAX_PAGINATED_PAYLOAD_BYTESis set to 4 MiB (e.g. 1000 nullifier rows at ~36 B each, 1000 transactions summaries streamed in chunks).
Add new limits here so callers share the same values and rationale.
Structs§
- Query
Limit Error - Query
Param Account IdLimit - Used for the following RPC endpoints
- Query
Param Block Limit - Only used internally, not exposed via public RPC.
- Query
Param Note Commitment Limit - Used for internal queries retrieving note inclusion proofs by commitment.
- Query
Param Note IdLimit - Used for the following RPC endpoints
select_notes_by_id - Query
Param Note TagLimit - Used for the following RPC endpoints
- Query
Param Nullifier Limit - Used for the following RPC endpoints
- Query
Param Nullifier Prefix Limit - Used for the following RPC endpoints
- Query
Param Storage MapKey Total Limit - Used for the following RPC endpoints
Constants§
- GENERAL_
REQUEST_ LIMIT - Basic request limit.
- MAX_
RESPONSE_ PAYLOAD_ BYTES - Maximum payload size (in bytes) for paginated responses returned by the store.
Traits§
- Query
Param Limiter - Checks limits against the desired query parameters, per query parameter and bails if they exceed a defined value.