fix(memcached): don't 500 upon hitting item size limit
This commit is contained in:
parent
6f04a6b693
commit
d79a539f71
@ -241,7 +241,7 @@ memcachedBySet mExp (Binary.encode -> k) v = do
|
|||||||
let cKey = toMemcachedKey memcachedKey (Proxy @a) k
|
let cKey = toMemcachedKey memcachedKey (Proxy @a) k
|
||||||
aad = memcachedAAD cKey mExpiry
|
aad = memcachedAAD cKey mExpiry
|
||||||
mCiphertext = AEAD.aead memcachedKey mNonce decrypted aad
|
mCiphertext = AEAD.aead memcachedKey mNonce decrypted aad
|
||||||
liftIO $ Memcached.set zeroBits (fromMaybe zeroBits mExp') cKey (Binary.runPut $ putMemcachedValue MemcachedValue{..}) memcachedConn
|
liftIO . handle (\(_ :: Memcached.MemcachedException) -> return ()) $ Memcached.set zeroBits (fromMaybe zeroBits mExp') cKey (Binary.runPut $ putMemcachedValue MemcachedValue{..}) memcachedConn
|
||||||
$logDebugS "memcached" $ "Cache store: " <> tshow mExpiry
|
$logDebugS "memcached" $ "Cache store: " <> tshow mExpiry
|
||||||
|
|
||||||
mLocal <- getsYesod appMemcachedLocal
|
mLocal <- getsYesod appMemcachedLocal
|
||||||
|
|||||||
Reference in New Issue
Block a user