freckle-app-1.0.3.0: Haskell application toolkit used at Freckle
Safe HaskellNone
LanguageHaskell2010

Freckle.App.Memcached.CacheKey

Synopsis

Documentation

data CacheKey Source #

Instances

Instances details
Eq CacheKey Source # 
Instance details

Defined in Freckle.App.Memcached.CacheKey

Show CacheKey Source # 
Instance details

Defined in Freckle.App.Memcached.CacheKey

Hashable CacheKey Source # 
Instance details

Defined in Freckle.App.Memcached.CacheKey

Methods

hashWithSalt :: Int -> CacheKey -> Int #

hash :: CacheKey -> Int #

cacheKey :: Text -> Either String CacheKey Source #

Build a CacheKey, ensuring it's valid for Memcached

https://github.com/memcached/memcached/blob/master/doc/protocol.txt#L41

Currently the length limit of a key is set at 250 characters (of course,
normally clients wouldn't need to use such long keys); the key must not
include control characters or whitespace.

cacheKeyThrow :: (HasCallStack, MonadIO m) => Text -> m CacheKey Source #

Build a CacheKey and throw if invalid