BodyTooLarge

class BodyTooLarge(val limit: Long, val declared: Long?, cause: Throwable?) : TransportFailure(source)

The response body is larger than the transport's limit.

Stable Core. Message: The response body is larger than the limit of <limit> bytes, plus (declared <declared> bytes) when the server declared a length.

Parameters

limit

the transport's limit in bytes; not negative.

declared

the length the server declared, or null; not negative when present.

cause

the lower-level throwable, or null.

Throws

Constructors

Link copied to clipboard
constructor(limit: Long, declared: Long?, cause: Throwable?)
constructor(limit: Long, declared: Long?)

Creates the failure without a cause.

Properties

Link copied to clipboard
open val cause: Throwable?
Link copied to clipboard

The length the server declared, or null.

Link copied to clipboard
val limit: Long

The transport's limit in bytes.

Link copied to clipboard
open val message: String?