packages feed

aws-kinesis-client 0.4.0.0 → 0.4.0.1

raw patch · 5 files changed

+23/−10 lines, 5 filesdep ~aws-kinesis-client

Dependency ranges changed: aws-kinesis-client

Files

CHANGELOG.md view
@@ -1,3 +1,9 @@+### v0.4.0.1++This release fixes a bug in the Consumer where a saved state could get+clobbered in case no further records were found at the restored point on a+shard.+ ### v0.4.0.0  This release contains breaking changes.
aws-kinesis-client.cabal view
@@ -1,10 +1,10 @@ name:                aws-kinesis-client-version:             0.4.0.0+version:             0.4.0.1 synopsis:            A producer & consumer client library for AWS Kinesis description:     This package provides a Producer client for bulk-writing messages to a     Kinesis stream through a bounded queue, and a Consumer client for reading-    messages round-robin from all shards of a Kiensis stream.  Additionally, a+    messages round-robin from all shards of a Kinesis stream.  Additionally, a     rudimentary CLI interface to the Consumer is provided.  license:             Apache-2.0@@ -40,7 +40,7 @@                        Aws.Kinesis.Client.Internal.Queue.Chunk   -- other-modules:   -- other-extensions:-  build-depends:       base >=4.7 && <4.9,+  build-depends:       base >=4.7 && <5.0,                        base-unicode-symbols,                        aeson >=0.8,                        aws >=0.10.5,@@ -78,13 +78,13 @@     hs-source-dirs: cli     main-is: CLI.hs     other-modules:     CLI.Options-    build-depends:     base >=4.7 && <4.8,+    build-depends:     base >=4.7 && <5.0,                        base-unicode-symbols,                        aeson >=0.8,                        aws >=0.10.5,                        aws-general >=0.2.1,                        aws-kinesis >=0.1.4,-                       aws-kinesis-client >=0.4.0.0,+                       aws-kinesis-client >=0.4.0.1,                        conduit >=1.2.3.1,                        http-conduit >=2.1.5,                        kan-extensions >=4.2,
cli/CLI.hs view
@@ -171,15 +171,22 @@       return $ maybe True (n ≥) _clioLimit  +  --  If a timeout is set, then we will race the timeout against the consumer.   result ← lift $     case _clioTimeout of       Just seconds → race (threadDelay $ seconds * 1000000) runConsumer       Nothing → Right <$> runConsumer    let-    successful = case result of-      Left () → isn't _Just _clioLimit-      Right b → b+    successful =+      case result of+        -- if we timed out: if there a requested limit, then we failed to get+        -- it (and this is a failure); if there was no requested limit, then we+        -- consider this a success.+        Left () → isn't _Just _clioLimit++        -- if we did not timeout, then it is a success+        Right b → b    lift ∘ when successful ∘ void ∘ for _clioStateOut $ \outPath → do     state ← consumerStreamState consumer
cli/CLI/Options.hs view
@@ -216,5 +216,5 @@   info (helper ⊛ optionsParser) $     fullDesc     ⊕ progDesc "Fetch a given number of records from a Kinesis stream; unlike the standard command line utilities, this interface is suitable for use with a sharded stream. If you both specify a saved stream state to be restored and an iterator type, the latter will be used on any shards which are not contained in the saved state. Minimally, you must specify your AWS credentials, a stream name, and an optional limit & timeout."-    ⊕ header "The Kinesis Consumer CLI v0.2.0.3"+    ⊕ header "The Kinesis Consumer CLI v0.4.0.1" 
src/Aws/Kinesis/Client/Consumer/Internal.hs view
@@ -113,7 +113,7 @@      liftIO ∘ atomically $ do       iteratorVar ← newTVar $ Just it-      sequenceNumberVar ← newTVar Nothing+      sequenceNumberVar ← newTVar startingSequenceNumber       return $ makeShardState shardShardId iteratorVar sequenceNumberVar    return ∘ CR.nub $ CR.append shardStates state