packages feed

groundhog-mysql 0.8 → 0.8.0.1

raw patch · 3 files changed

+14/−2 lines, 3 filesdep ~groundhogPVP: minor bump suggested

API additions: PVP suggests at least a minor version bump

Dependency ranges changed: groundhog

API changes (from Hackage documentation)

+ Database.Groundhog.MySQL: instance Database.Groundhog.Core.TryConnectionManager Database.Groundhog.MySQL.MySQL

Files

Database/Groundhog/MySQL.hs view
@@ -152,6 +152,15 @@     liftIO $ MySQL.commit c     return x +instance TryConnectionManager MySQL where+  tryWithConn f g conn@(MySQL c) = do+    liftIO $ MySQL.execute_ c "start transaction"+    x <- g (f conn)+    case x of+      Left _ -> liftIO $ MySQL.rollback c+      Right _ -> liftIO $ MySQL.commit c+    return x+ instance ExtractConnection MySQL MySQL where   extractConn f conn = f conn 
changelog view
@@ -1,3 +1,6 @@+0.8.0.1+* New typeclass to allow transaction rollback through ExceptT+ 0.8 * Support for GHC 8 * Bumped MySQL dependencies
groundhog-mysql.cabal view
@@ -1,5 +1,5 @@ name:            groundhog-mysql-version:         0.8+version:         0.8.0.1 license:         BSD3 license-file:    LICENSE author:          Boris Lykah <lykahb@gmail.com>@@ -20,7 +20,7 @@                    , mysql                    >= 0.1.1.3   && < 0.2                    , bytestring               >= 0.9                    , transformers             >= 0.2.1     && < 0.6-                   , groundhog                >= 0.8       && < 0.9+                   , groundhog                >= 0.8.0.1   && < 0.9                    , monad-control            >= 0.3       && < 1.1                    , monad-logger             >= 0.3       && < 0.4                    , containers               >= 0.2