* Add proxy support
Read proxy info from application.properties file first,
then java system settings, and finally from ENV vars.
* Formatted code according to AWS scheme.
Import specific classes, not *.
* Add proxy config unit tests
* Changed per @sahilpalvia comments
* Fix failing test
* Changed per @sahilpalvia comments
* Fixing missed http_proxy string
* Changed per @sahilpalvia comments
* Added cache updating behavior for GetShard
Customer are occasionally seeing messages about being unable to
retrieve shard information, which is logged as a warning. This change
will allow the shard map to be updated even when there is no re-shard
operation.
This now triggers a shard list update if there is 1000 cache misses,
or a cache miss occurs when the cache is more than 30 seconds old.
For Kinesis the updates will use ListShards, and for DynamoDB Streams
it will continue to use DescribeStream.
* Adjust some logging, and the zeroing of cache misses a bit
Only log about cache refresh if it's the thread doing the cache
refresh. If after synchronizing the shard is present, accept that
someone else loaded the shard map, and move on.
If the cache was reloaded, and the shard was found the current thread
will reset the cache misses.
The warnings for the cache miss was using a modulo of 1000 which is
the maximum value for cache misses, so wasn't to useful.
* Release 1.9.1 of the Amazon Kinesis Client Library for Java
Updated versions, and added release notes.
* Added note about the update of the AWS Java SDK
* Reformatting the constructors to be together in the Worker class.
* Using lombok annotations to replace setters in the Worker.Builder.
* Deprecating all the public constructors for the Worker class. Recommending to use the Worker.Builder to create the Worker object.
* Including annotation usage for leaseManager in the Worker.Builder
* Adding capability to support Immutable clients by the Worker and Worker.Builder
* Adding annotation support for WorkerStateChangeListener.
* Add a warning about ListShards and IAM Polices
* Corrected some spelling errors
* Add the same warning to the changelog
Added the warning from the README.md to the CHANGELOG.md.
* Added support for ListShards API. This API is used in place of DescribeStream API to provide more throughput during ShardSyncTask.
* ListShards supoorts higher call rate, which should reduce instances of throttling when attempting to synchronize the shard list.
* Updated the version of AWS Java SDK to 1.11.272.
* Version 1.11.272 is now the minimum support versiojn of the SDK.
* Deprecated the following methods, and classes. These methods, and classes will be removed in a future release.
* Deprecated IKinesisProxy#getStreamInfo.
* Deprecated IKinesisProxyFactory.
* Deprecated KinesisProxyFactory.
* Deprecated certain KinesisProxy constructors.
* Allow providing a custom IKinesisProxy implementation.
* PR #274
* Checkpointing on a different thread should no longer emit a warning about NullMetricsScope.
* PR #284
* Issue #48
* Upgraded the AWS Java SDK to version 1.11.271
* PR #287
Fixes#48
* Fixing issue with NullMetrics warning messages when trying to checkpoint on a separate thread.
* Adding testing to validate the MetricsScope setting during checkpoiniting.
* Added IKinesisProxy injector in Worker.Builder to allow injecting custom proxy implementations
* Added unit tests for IKinesisProxy injection in Worker Builder
* Revert "Added unit tests for IKinesisProxy injection in Worker Builder"
This reverts commit aa944c1706.
Reverting to undo changes to import ordering.
* Added unit tests for IKinesisProxy injection in Worker Builder
Re-added unit tests after reverting changes to import ordering.
* Revert "Added unit tests for IKinesisProxy injection in Worker Builder"
This reverts commit 91e445774b.
Reverting to refactor unit tests.
* Added unit tests for Worker Builder IKinesisProxy injection validation
Refactored unit tests as per comments in the pull request.
* Added debug logs in KinesisLocalFileDataCreator
* Revert "Added debug logs in KinesisLocalFileDataCreator"
This reverts commit 1ff00d0b01.
* Edited JavaDoc for Worker Builder kinesisProxy
* Allow disabling check for the case where a child shard has an open parent shard.
There is a race condition where it's possible for the a parent shard
to appear open, while having child shards. This check can now be
disabled by setting ignoreUnexpectedChildShards in the
KinesisClientLibConfiguration to true.
* PR #240
* Issue #210
* Upgraded the AWS SDK for Java to 1.11.261
* PR #281
Allow unexpected child shards to be ignored
now instead of always throwing an assertion if a child shard has an
open parent, consider worker configuration before doing so. if
configured to ignore such shards, do not create leases for them during
shard sync. this is intended to mitigate failing worker init when
processing dynamodb streams with many thousands of shards (which can
happen for tables with thousands of partitions).
this new behavior can be enabled by adding the following to a
configuration/properties file:
```
ignoreUnexpectedChildShards = true
```
Release 1.8.8
* Fixed issues with leases losses due to `ExpiredIteratorException` in `PrefetchGetRecordsCache` and `AsynchronousFetchingStrategy`.
PrefetchGetRecordsCache will request for a new iterator and start fetching data again.
* PR#263
* Added warning message for long running tasks.
* PR#259
* Handling spurious lease renewal failures gracefully.
Added better handling of DynamoDB failures when updating leases. These failures would occur when a request to DynamoDB appeared to fail, but was actually successful.
* PR#247
* ShutdownTask gets retried if the previous attempt on the ShutdownTask fails.
* PR#267
* Fix for using maxRecords from `KinesisClientLibConfiguration` in `GetRecordsCache` for fetching records.
* PR#264
* Shutdown that throws an exception will be retried.
Without this change a transient error on shutdown with reason terminate prevents
child shards from starting.
* Fixing the tests for the Shutdown fix.
Fixes#262
Changing the signture of SingleRecordsFetcherFactory to no longer take maxRecords as the parameter to the constructor. Changed the createRecordsFetcher signature to take maxRecords as a parameter. (#264)
* Handle spurious lease renewal failures gracefully.
If the request to conditionally update a lease counter in DynamoDB fails, it's
considered a failure to renew the lease. This is a good thing, except if the
request failure was just because of connectivity problems. In this case the
counter *did* update in DynamoDB, but the Dynamo client retries the request
which then fails the update condition (since the lease counter no longer
matches expected value).
To handle this gracefully we opt to get the lease record from Dynamo and
examine the lease owner and counter. If it matches what we were expecting,
then we consider renewal a success.
Block the fetching thread when the queue is considered to be full.
This ensures that the thread won't spin the CPU when it can't retrieve
more records or bytes.