hedis 0.9.9 → 0.9.10
raw patch · 3 files changed
+21/−1 lines, 3 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- CHANGELOG +4/−0
- hedis.cabal +1/−1
- src/Database/Redis/ProtocolPipelining.hs +16/−0
CHANGELOG view
@@ -1,5 +1,9 @@ # Changelog for Hedis +## 0.9.10++* PR #93, Issue #92. Connection to Unix sockets is broken+ ## 0.9.9 * PR #90. set SO_KEEPALIVE option on underlying connection socket
hedis.cabal view
@@ -1,5 +1,5 @@ name: hedis-version: 0.9.9+version: 0.9.10 synopsis: Client library for the Redis datastore: supports full command set, pipelining.
src/Database/Redis/ProtocolPipelining.hs view
@@ -73,6 +73,22 @@ NS.connect sock $ NS.SockAddrInet port (BSD.hostAddress host) NS.socketToHandle sock ReadWriteMode mkSocket = NS.socket NS.AF_INET NS.Stream 0+connect _hostName (UnixSocket fsplace) =+ bracketOnError hConnect hClose $ \connHandle -> do+ hSetBinaryMode connHandle True+ connReplies <- newIORef []+ connPending <- newIORef []+ connPendingCnt <- newIORef 0+ let conn = Conn{..}+ rs <- connGetReplies conn+ writeIORef connReplies rs+ writeIORef connPending rs+ return conn+ where hConnect =+ bracketOnError mkSocket NS.close $ \sock -> do+ NS.connect sock $ NS.SockAddrUnix fsplace+ NS.socketToHandle sock ReadWriteMode+ mkSocket = NS.socket NS.AF_UNIX NS.Stream 0 connect hostName portID = error $ "Connection to " ++ hostName ++ ":" ++ show portID ++ " not supported"