packages feed

amqp 0.21.0 → 0.22.0

raw patch · 3 files changed

+6/−2 lines, 3 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

Files

Network/AMQP/Internal.hs view
@@ -778,7 +778,7 @@     SimpleMethod Channel_close_ok <- request c $ SimpleMethod $ Channel_close 0 (ShortString "") 0 0
     withMVar (connChannels $ connection c) $ \chans -> do
         case IM.lookup (fromIntegral $ channelID c) chans of
-            Just (_, thrID) -> killThread thrID
+            Just (_, thrID) -> throwTo thrID $ ChannelClosedException Normal "closeChannel was called"
             Nothing -> return ()
 
 -- | writes multiple frames to the channel atomically
amqp.cabal view
@@ -1,5 +1,5 @@ Name:                amqp
-Version:             0.21.0
+Version:             0.22.0
 Synopsis:            Client library for AMQP servers (currently only RabbitMQ)
 Description:         Client library for AMQP servers (currently only RabbitMQ)
 License:             BSD3
changelog.md view
@@ -1,3 +1,7 @@+### Version 0.22.0
+
+* `closeChannel` now uses a `ChannelClosedException` to kill the channel-thread instead of `ThreadKilled`. This fixes a bug in 0.21.0 that led to errors being printed on the screen when `closeChannel` was called.
+
 ### Version 0.21.0
 
 * added method `isNormalChannelClose`