shikumi-cache-redis 0.1.3.0 → 0.1.3.1
raw patch · 3 files changed
+57/−44 lines, 3 filesdep ~baikaidep ~effectfuldep ~shikumi-cachePVP ok
version bump matches the API change (PVP)
Dependency ranges changed: baikai, effectful, shikumi-cache, shikumi-cache-redis
API changes (from Hackage documentation)
Files
- CHANGELOG.md +4/−0
- shikumi-cache-redis.cabal +50/−41
- src/Shikumi/Cache/Backend/Redis.hs +3/−3
CHANGELOG.md view
@@ -2,6 +2,10 @@ ## Unreleased +## 0.1.3.1 — 2026-10-05++- Move the dependency on `mori://shinzui/baikai/packages/baikai` to `>=0.7.1.0 && <0.8` and widen the `effectful` bound to `>=2.6 && <2.8`, so both effectful 2.6 and 2.7 are supported (effectful 2.7 needs `baikai-effectful` 0.4.0.2, effectful 2.6 needs 0.4.0.1). Bounds only; no source changed.+ ## 0.1.3.0 — 2026-09-08 - Raise the internal `shikumi-cache` bound to `^>=0.2.0.0` for the breaking cache release.
shikumi-cache-redis.cabal view
@@ -1,8 +1,8 @@-cabal-version: 3.4-name: shikumi-cache-redis-version: 0.1.3.0-synopsis: Redis-backed shikumi cache (EP-6)-category: AI+cabal-version: 3.4+name: shikumi-cache-redis+version: 0.1.3.1+synopsis: Redis-backed shikumi cache (EP-6)+category: AI description: A Redis backend for shikumi's @Cache@ effect (EP-6), kept in a separate package so the heavy @hedis@ client and a running Redis server are only@@ -11,20 +11,26 @@ a @CachedResponse@ (the @Response@ round-trip comes from @shikumi-cache@'s @Shikumi.Cache.ResponseJSON@). -license: BSD-3-Clause-author: Nadeem Bitar-maintainer: nadeem@gmail.com-build-type: Simple+license: BSD-3-Clause+author: Nadeem Bitar+maintainer: nadeem@gmail.com+build-type: Simple extra-doc-files: CHANGELOG.md common common-options ghc-options:- -Wall -Wcompat -Widentities -Wincomplete-uni-patterns- -Wincomplete-record-updates -Wredundant-constraints- -fhide-source-paths -Wmissing-export-lists -Wpartial-fields+ -Wall+ -Wcompat+ -Widentities+ -Wincomplete-uni-patterns+ -Wincomplete-record-updates+ -Wredundant-constraints+ -fhide-source-paths+ -Wmissing-export-lists+ -Wpartial-fields -Wmissing-deriving-strategies - default-language: GHC2024+ default-language: GHC2024 default-extensions: DeriveAnyClass DuplicateRecordFields@@ -32,37 +38,40 @@ OverloadedStrings library- import: common-options- hs-source-dirs: src+ import: common-options+ hs-source-dirs: src exposed-modules: Shikumi.Cache.Backend.Redis build-depends:- , aeson >=2.2 && <2.3- , base >=4.20 && <5- , bytestring >=0.11 && <0.13- , effectful >=2.5 && <2.7- , hedis >=0.15 && <0.17- , shikumi-cache ^>=0.2.0.0- , text ^>=2.1+ aeson >=2.2 && <2.3,+ base >=4.20 && <5,+ bytestring >=0.11 && <0.13,+ effectful >=2.6 && <2.8,+ hedis >=0.15 && <0.17,+ shikumi-cache ^>=0.2.0.1,+ text ^>=2.1, test-suite shikumi-cache-redis-test- import: common-options- type: exitcode-stdio-1.0+ import: common-options+ type: exitcode-stdio-1.0 hs-source-dirs: test- main-is: Main.hs- ghc-options: -threaded -with-rtsopts=-N+ main-is: Main.hs+ ghc-options:+ -threaded+ -with-rtsopts=-N+ build-depends:- , baikai >=0.7.0.0 && <0.8- , base- , bytestring- , effectful- , generic-lens- , hedis- , lens- , shikumi ^>=0.4.0.0- , shikumi-cache ^>=0.2.0.0- , shikumi-cache-redis ^>=0.1.3.0- , tasty- , tasty-hunit- , text- , time- , vector+ baikai >=0.7.1.0 && <0.8,+ base,+ bytestring,+ effectful,+ generic-lens,+ hedis,+ lens,+ shikumi ^>=0.4.0.0,+ shikumi-cache ^>=0.2.0.1,+ shikumi-cache-redis ^>=0.1.3.1,+ tasty,+ tasty-hunit,+ text,+ time,+ vector,
src/Shikumi/Cache/Backend/Redis.hs view
@@ -6,7 +6,7 @@ -- string key @shikumi:cache:\<hex\>@ (the @shikumi:cache:@ prefix is operational -- namespacing, outside the content hash). By default entries have no Redis-side -- expiry; callers that want Redis to bound storage can opt into @SETEX@ with--- 'openRedisCacheWithTTL'. The value is the UTF-8 JSON of a 'CachedResponse';+-- 'openRedisCacheWithTTL'. The value is the UTF-8 JSON of a t'Shikumi.Cache.Types.CachedResponse'; -- the baikai 'Baikai.Response.Response' round-trip is the one from -- @shikumi-cache@ ("Shikumi.Cache.ResponseJSON"). module Shikumi.Cache.Backend.Redis@@ -43,7 +43,7 @@ defaultRedisTTL = 7 * 24 * 60 * 60 -- | Connect to Redis (verifying the connection eagerly via @checkedConnect@)--- with no Redis-side expiry. Throws 'R.ConnectError' if the server is+-- with no Redis-side expiry. Throws t'Database.Redis.ConnectError' if the server is -- unreachable. openRedisCache :: R.ConnectInfo -> IO RedisCache openRedisCache ci = do@@ -51,7 +51,7 @@ pure (RedisCache conn Nothing) -- | As 'openRedisCache' but with an explicit Redis-side per-entry TTL (seconds).--- This bounds Redis storage independently of the policy-layer 'CacheConfig'+-- This bounds Redis storage independently of the policy-layer 'Shikumi.Cache.CacheConfig' -- expiry in @shikumi-cache@. openRedisCacheWithTTL :: Integer -> R.ConnectInfo -> IO RedisCache openRedisCacheWithTTL ttl ci = do