[][src]Crate tower_util

Various utility types and functions that are generally with Tower.

Modules

error

Error types

future

Future types

Structs

BoxService

A boxed Service + Send trait object.

CallAll

This is a futures::Stream of responses resulting from calling the wrapped tower::Service for each request received on the wrapped Stream.

CallAllUnordered

A stream of responses received from the inner service in received order.

Oneshot

A Future consuming a Service and request, waiting until the Service is ready, and then calling Service::call with the request, and waiting for that Future.

Optional

Optionally forwards requests to an inner service.

Ready

A future that resolves when a Service is ready to accept a request.

ReadyAnd

A future that yields a mutable reference to the service when it is ready to accept a request.

ReadyOneshot

A future that yields the service when it is ready to accept a request.

ServiceFn

A Service implemented by a closure.

UnsyncBoxService

A boxed Service trait object.

Enums

Either

Combine two different service types into a single type.

Traits

ServiceExt

An extension trait for Services that provides a variety of convenient adapters

Functions

service_fn

Returns a new ServiceFn with the given closure.