Skip to main content

get_cache_key

Function get_cache_key 

Source
pub fn get_cache_key(ctx: &Ctx, method: &str, uri: &Uri) -> CacheKey
Expand description

Generates a cache key from the request method, URI and state context. The key includes an optional namespace and other key components if configured in the context.

ยงArguments

  • ctx - The Ctx context containing cache configuration.
  • method - The HTTP method as a string.
  • uri - The request URI.

Returns: A CacheKey combining the namespace, custom keys (if any), method and URI.