packages feed

aws-kinesis-client 0.1.0.0 → 0.1.0.1

raw patch · 4 files changed

+29/−9 lines, 4 filesdep +lens-actiondep ~lensPVP ok

version bump matches the API change (PVP)

Dependencies added: lens-action

Dependency ranges changed: lens

API changes (from Hackage documentation)

Files

+ CHANGELOG.md view
@@ -0,0 +1,9 @@+### v0.1.0.1++- Add some throttling to the consumer loop to avoid rate limiting+- Relax the lower-bound on `monad-control`+- Upgrade to `lens-4.7`, add `lens-action` dependency++### v0.1.0.0++Initial release
aws-kinesis-client.cabal view
@@ -1,5 +1,5 @@ name:                aws-kinesis-client-version:             0.1.0.0+version:             0.1.0.1 synopsis:            A producer & consumer client library for AWS Kinesis -- description: license:             Apache-2.0@@ -10,7 +10,12 @@ category:            Cloud build-type:          Simple cabal-version:       >=1.10+extra-source-files:  CHANGELOG.md +source-repository head+  type:     git+  location: https://github.com/alephcloud/hs-aws-kinesis-client.git+ library   exposed-modules:     Aws.Kinesis.Client.Common,                        Aws.Kinesis.Client.Consumer@@ -27,10 +32,11 @@                        errors >=1.4.7,                        http-conduit >=2.1.5,                        kan-extensions >=4.2,-                       lens >=4.6 && < 4.7,+                       lens >=4.7,+                       lens-action >=0.1.0.1,                        lifted-async >=0.3.0,                        lifted-base >=0.2.3.3,-                       monad-control >=1.0,+                       monad-control >=0.3.3.0,                        mtl >=2.2.1,                        random >=1.1,                        resourcet >=1.1.3.3,@@ -47,7 +53,7 @@     default-language: Haskell2010     hs-source-dirs: cli     main-is: CLI.hs-    other-modules:     CLI.Options, +    other-modules:     CLI.Options,                        CLI.Record     build-depends:     base >=4.7 && <4.8,                        base-unicode-symbols,@@ -61,10 +67,11 @@                        http-conduit >=2.1.5,                        kan-extensions >=4.2,                        hourglass >=0.2.6,-                       lens >=4.6 && < 4.7,+                       lens >=4.7,+                       lens-action >=0.1.0.1,                        lifted-async >=0.3.0,                        lifted-base >=0.2.3.3,-                       monad-control >=1.0,+                       monad-control >=0.3.3.0,                        mtl >=2.2.1,                        random >=1.1,                        resourcet >=1.1.3.3,
cli/CLI.hs view
@@ -57,6 +57,7 @@ import Control.Monad.Error.Class  import Data.Aeson+import qualified Data.ByteString.Char8 as B8 import qualified Data.ByteString.Lazy as BL import Data.Conduit import Data.Monoid@@ -130,7 +131,7 @@           =$ CL.mapM_ (liftIO ∘ print)       True →         limitConduit-        =$ CL.mapM_ (liftIO ∘ print ∘ recordData)+        =$ CL.mapM_ (liftIO ∘ B8.putStrLn ∘ recordData)   return ()  main ∷ IO ()
src/Aws/Kinesis/Client/Consumer.hs view
@@ -62,6 +62,7 @@ import Control.Concurrent.STM.Queue import Control.Exception import Control.Lens+import Control.Lens.Action import Control.Monad.Codensity import Control.Monad.Error.Class import Control.Monad.Reader@@ -197,8 +198,10 @@         producerLoop = forever $           handleError (\_ → liftIO $ threadDelay 2000000) $ do             recordsCount ← replenishMessages messageQueue state-            when (recordsCount ≡ 0) $-              liftIO $ threadDelay 5000000+            liftIO . threadDelay $+              case recordsCount of+                0 → 5000000+                _ → 70000       withAsync reshardingLoop $ \reshardingHandle → do