Module service

Source
Expand description

HTTP service and service factory traits.

Traits§

HttpService
A trait representing an HTTP service.
HttpServiceFactory
A trait representing an HTTP service factory.

Structs§

ServiceCloneFactory
A HttpServiceFactory that simply clones the given service for each new connection.

Functions§

service_clone_factory
Create a ServiceCloneFactory from a given service.

Structs§

FnHttpService
A HttpService that is created from a function.

Functions§

fn_http_service
Create a FnHttpService from a given function.

Structs§

FnHttpServiceFactory
A HttpServiceFactory that creates a FnHttpService from a function.

Functions§

fn_http_service_factory
Create a FnHttpServiceFactory from a given function.

Structs§

TowerMakeServiceFactorytower
A HttpServiceFactory that wraps a tower::MakeService. The given tower::MakeService will be called to create a new service for each new connection.

Functions§

custom_tower_make_service_factorytower
Create a TowerMakeServiceFactory from a given tower::MakeService and target value.
tower_make_service_factorytower
Create a TowerMakeServiceFactory from a given tower::MakeService.

Structs§

TowerMakeServiceWithAddrFactorytower
A HttpServiceFactory that wraps a tower::MakeService that takes a SocketAddr as input.

Functions§

tower_make_service_with_addr_factorytower
Create a TowerMakeServiceWithAddrFactory from a given tower::MakeService.