shibuya-pgmq-adapter 0.2.0.0 → 0.3.0.0
raw patch · 5 files changed
+41/−14 lines, 5 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- CHANGELOG.md +27/−0
- shibuya-pgmq-adapter.cabal +7/−7
- test/Shibuya/Adapter/Pgmq/ChaosSpec.hs +2/−2
- test/Shibuya/Adapter/Pgmq/IntegrationSpec.hs +2/−2
- test/TestUtils.hs +3/−3
CHANGELOG.md view
@@ -1,5 +1,32 @@ # Changelog +## 0.3.0.0 — 2026-04-24++Upgraded to `pgmq-hs` 0.2.0.0 series+(`pgmq-core`, `pgmq-hasql`, `pgmq-effectful`, `pgmq-migration`+all at `0.2.0.0`).++### Breaking Changes++- Consumers that pin the `Pgmq.Effectful.PgmqError` name in their own+ `runError` / `runErrorNoCallStack` stack must migrate to+ `PgmqRuntimeError`. The old type is still re-exported as a+ deprecated alias for one release.+- Spans emitted by the traced interpreter now follow OpenTelemetry+ semantic-conventions v1.24. Span names (`"publish my-queue"`,+ `"receive my-queue"`) and attribute keys (`messaging.operation`,+ `messaging.system`, `messaging.destination.name`) have changed.+ Dashboards and alerts keyed on the old names will need updating.+- Callers of `Pgmq.Effectful.Traced.sendMessageTraced` must pass an+ `OpenTelemetry.Trace.TracerProvider` instead of an+ `OpenTelemetry.Trace.Tracer`. If you only have a `Tracer` in scope,+ use `OpenTelemetry.Trace.Core.getTracerTracerProvider` to derive the+ provider.++### Other Changes++- No user-visible changes to `shibuya-pgmq-adapter`'s own API.+ ## 0.2.0.0 — 2026-04-22 Version bumped to track `shibuya-core` 0.2.0.0. No user-visible changes
shibuya-pgmq-adapter.cabal view
@@ -1,6 +1,6 @@ cabal-version: 3.14 name: shibuya-pgmq-adapter-version: 0.2.0.0+version: 0.3.0.0 synopsis: PGMQ adapter for the Shibuya queue processing framework description: A Shibuya adapter that integrates with pgmq (PostgreSQL Message Queue)@@ -43,10 +43,10 @@ base ^>=4.21.0.0, bytestring ^>=0.12, effectful-core ^>=2.6.1.0,- pgmq-core ^>=0.1,- pgmq-effectful ^>=0.1,- pgmq-hasql ^>=0.1,- shibuya-core ^>=0.2.0.0,+ pgmq-core ^>=0.2,+ pgmq-effectful ^>=0.2,+ pgmq-hasql ^>=0.2,+ shibuya-core ^>=0.3.0.0, stm ^>=2.5, streamly ^>=0.11, streamly-core ^>=0.3,@@ -110,10 +110,10 @@ pgmq-core, pgmq-effectful, pgmq-hasql,- pgmq-migration,+ pgmq-migration ^>=0.2, quickcheck-instances ^>=0.3, random,- shibuya-core ^>=0.2.0.0,+ shibuya-core ^>=0.3.0.0, shibuya-pgmq-adapter, stm, streamly ^>=0.11,
test/Shibuya/Adapter/Pgmq/ChaosSpec.hs view
@@ -20,7 +20,7 @@ import Effectful (Eff, IOE, liftIO, runEff, (:>)) import Effectful.Error.Static (Error, runErrorNoCallStack) import Hasql.Pool qualified as Pool-import Pgmq.Effectful (Pgmq, PgmqError, runPgmq)+import Pgmq.Effectful (Pgmq, PgmqRuntimeError, runPgmq) import Pgmq.Effectful qualified as PgmqEff import Pgmq.Hasql.Sessions qualified as Sessions import Pgmq.Hasql.Statements.Types (ReadMessage (..), SendMessage (..), SendMessageWithHeaders (..))@@ -69,7 +69,7 @@ Right () -> pure () -- | Run an Eff action with Pgmq effect against a pool, throwing on error.-runAdapterIO :: Pool.Pool -> Eff '[Pgmq, Error PgmqError, IOE] a -> IO a+runAdapterIO :: Pool.Pool -> Eff '[Pgmq, Error PgmqRuntimeError, IOE] a -> IO a runAdapterIO pool action = do result <- runEff $ runErrorNoCallStack $ runPgmq pool action case result of
test/Shibuya/Adapter/Pgmq/IntegrationSpec.hs view
@@ -18,7 +18,7 @@ import Effectful (Eff, IOE, liftIO, runEff) import Effectful.Error.Static (Error, runErrorNoCallStack) import Hasql.Pool qualified as Pool-import Pgmq.Effectful (Pgmq, PgmqError, runPgmq)+import Pgmq.Effectful (Pgmq, PgmqRuntimeError, runPgmq) import Pgmq.Effectful qualified as PgmqEff import Pgmq.Hasql.Sessions qualified as Sessions import Pgmq.Hasql.Statements.Types (MessageQuery (..), ReadMessage (..), SendMessage (..), VisibilityTimeoutQuery (..))@@ -62,7 +62,7 @@ Right () -> pure () -- | Run an Eff action with Pgmq effect against a pool, throwing on error.-runAdapterIO :: Pool.Pool -> Eff '[Pgmq, Error PgmqError, IOE] a -> IO a+runAdapterIO :: Pool.Pool -> Eff '[Pgmq, Error PgmqRuntimeError, IOE] a -> IO a runAdapterIO pool action = do result <- runEff $ runErrorNoCallStack $ runPgmq pool action case result of
test/TestUtils.hs view
@@ -20,7 +20,7 @@ import Effectful (Eff, IOE, runEff) import Effectful.Error.Static (Error, runErrorNoCallStack) import Hasql.Pool qualified as Pool-import Pgmq.Effectful (Pgmq, PgmqError, runPgmq)+import Pgmq.Effectful (Pgmq, PgmqRuntimeError, runPgmq) import Pgmq.Effectful qualified as Pgmq import Pgmq.Hasql.Sessions qualified as Sessions import Pgmq.Hasql.Statements.Types (SendMessage (..), SendMessageWithHeaders (..))@@ -29,8 +29,8 @@ import TmpPostgres (runPgmqSession) -- | Run an Eff action with Pgmq effect against a pool.--- This handles the Error PgmqError effect and throws on errors.-runWithPool :: Pool.Pool -> Eff '[Pgmq, Error PgmqError, IOE] a -> IO a+-- This handles the Error PgmqRuntimeError effect and throws on errors.+runWithPool :: Pool.Pool -> Eff '[Pgmq, Error PgmqRuntimeError, IOE] a -> IO a runWithPool pool action = do result <- runEff $ runErrorNoCallStack $ runPgmq pool action case result of