abstract class ExchangeFilterFunctions
Implementations of ExchangeFilterFunction that provide various useful request filter operations, such as basic authentication, error handling, etc.
Author
Rob Winch
Author
Arjen Poutsma
Since
5.0
ExchangeFilterFunctions()
Implementations of ExchangeFilterFunction that provide various useful request filter operations, such as basic authentication, error handling, etc. |
static val BASIC_AUTHENTICATION_CREDENTIALS_ATTRIBUTE: String
Name of the ClientRequest attribute that contains the Credentials, as used by |
open static fun basicAuthentication(username: String, password: String): ExchangeFilterFunction
Return a filter that adds an Authorization header for HTTP Basic Authentication, based on the given username and password. Note that Basic Authentication only supports characters in the open static fun basicAuthentication(): ExchangeFilterFunction
Return a filter that adds an Authorization header for HTTP Basic Authentication, based on the Credentials provided in the request attributes. If the attribute is not found, no authorization header is added. Note that Basic Authentication only supports characters in the |
|
open static fun statusError(statusPredicate: Predicate<HttpStatus>, exceptionFunction: Function<ClientResponse, out Throwable>): ExchangeFilterFunction
Return a filter that returns a given Throwable as response if the given HttpStatus predicate matches. |