Crate http_cache

Source
Expand description

A caching middleware that follows HTTP caching rules, thanks to http-cache-semantics. By default, it uses cacache as the backend cache manager.

§Features

The following features are available. By default manager-cacache and cacache-async-std are enabled.

  • manager-cacache (default): enable cacache, a high-performance disk cache, backend manager.
  • cacache-async-std (default): enable async-std runtime support for cacache.
  • cacache-tokio (disabled): enable tokio runtime support for cacache.
  • manager-moka (disabled): enable moka, a high-performance in-memory cache, backend manager.
  • with-http-types (disabled): enable http-types type conversion support

Structs§

Enums§

Constants§

  • x-cache header: Value will be HIT if the response was served from cache, MISS if not
  • x-cache-lookup header: Value will be HIT if a response existed in cache, MISS if not

Traits§

  • A trait providing methods for storing, reading, and removing cache records.
  • Describes the functionality required for interfacing with HTTP client middleware

Type Aliases§