Struct fastly::limits::RequestLimits[][src]

pub struct RequestLimits { /* fields omitted */ }

The limits for components of an HTTP request.

This is primarily relevant for the client request, and should be set before the client request is read with a method like Request::from_client().

Since the fastly::main attribute macro automatically reads the client request before application code has a chance to run, you should not use the macro if you need to customize the limits.

Default values

LimitDefault value
Header name sizeDEFAULT_MAX_HEADER_NAME_BYTES
Header value sizeDEFAULT_MAX_HEADER_VALUE_BYTES
Method sizeDEFAULT_MAX_METHOD_BYTES
URL sizeDEFAULT_MAX_URL_BYTES

Implementations

impl RequestLimits[src]

pub fn set_all_default()[src]

Set all request limits to their default values.

pub fn set_all_disabled()[src]

Disable all request limits.

Note that the overall WebAssembly heap size limit still applies.

pub fn get_max_header_name_bytes() -> Option<usize>[src]

Get the current request header name size limit.

pub fn set_max_header_name_bytes(max: Option<usize>)[src]

Set the request header name size limit.

pub fn get_max_header_value_bytes() -> Option<usize>[src]

Get the current request header value size limit.

pub fn set_max_header_value_bytes(max: Option<usize>)[src]

Set the request header value size limit.

pub fn get_max_method_bytes() -> Option<usize>[src]

Get the current request method size limit.

pub fn set_max_method_bytes(max: Option<usize>)[src]

Set the request method size limit.

pub fn get_max_url_bytes() -> Option<usize>[src]

Get the current request URL size limit.

pub fn set_max_url_bytes(max: Option<usize>)[src]

Set the request URL size limit.

Trait Implementations

impl Clone for RequestLimits[src]

impl Copy for RequestLimits[src]

impl Debug for RequestLimits[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.