glimr/cache/cache

Cache Shared Types

Provides common types used across all cache drivers including file-based and Redis caching backends.

Types

Represents errors that can occur during cache operations. Includes variants for missing keys, serialization failures, connection issues, expiration, and compute errors.

pub type CacheError {
  NotFound
  SerializationError(message: String)
  ConnectionError(message: String)
  Expired
  ComputeError(message: String)
}

Constructors

  • NotFound

    The requested key was not found in the cache

  • SerializationError(message: String)

    Failed to serialize or deserialize cache data

  • ConnectionError(message: String)

    Failed to connect to or communicate with the cache store

  • Expired

    The cached value has expired (used internally)

  • ComputeError(message: String)

    A computation error occurred in remember callback

Search Document