-
Notifications
You must be signed in to change notification settings - Fork 332
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Thread Pooling as a Threading Policy #100
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
added missing configuration. Updated version of the java component to 0.12.4-SNAPSHOT
Moved the setting of flags for compilation after the code that computes the flags.
Added the configuration for the thread pool settings.
Finalized the naming for the thread pool configuration, and changed default to to POOLED, with 64 threads.
Finalized the naming of the thread pool configuration, and handle the when threadPoolSize == 0.
With the default change from PER_REQUEST to POOLED, need to handle the case where PER_REQUEST is selected.
pfifer
changed the title
Change Thread Policy From Per Request to Pooled
Add Thread Pooling as a Threading Policy
May 15, 2017
pfifer
added a commit
to pfifer/amazon-kinesis-producer
that referenced
this pull request
May 15, 2017
pfifer
added a commit
that referenced
this pull request
May 17, 2017
=== 0.12.4 ==== Java * Upgraded dependency on aws-java-sdk-core to 1.11.128, and removed version range. * [PR #84](#84) * [PR #106](#106) * Use an explicit lock file to manage access to the native KPL binaries. * [Issue #91](#91) * [PR #92](#92) * Log reader threads should be shut down when the native process exits. * [Issue #93](#93) * [PR #94](#94) ==== C++ Core * Add support for using a thread pool, instead of a thread per request. The thread pool model guarantees a fixed number of threads, but have issue catching up if the KPL is overloaded. * [PR #100](#100) * Add log messages, and statistics about sending data to Kinesis. * Added flush statistics that record the count of events that trigger flushes of data destined for Kinesis * Added a log message that indicates the average time it takes for a PutRecords request to be completed. This time is recorded from the when the request is enqueued to when it is completed. * Log a warning if the average request time rises above five times the configured flush interval. If you see this warning normally it indicates that the KPL is having issues keeping up. The most likely cause is to many requests being generated, and you should investigate the flush triggers to determine why flushes are being triggered. * [PR #102](#102)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This allows changing the threading model from a per request model to a pooled model.
Threading Policies
Pooled
This uses a queue, and thread pool to execute requests to Kinesis. This limits the number of threads that the native process may use. Under extremely heavy load this can increase latency significantly more than the per request model.
Per Request
This is the current default for 0.12.x versions of the KPL, and creates a thread for each request to Kinesis. Under heavy load this can create a very large number of threads, which may cause resource exhaustion.
Updated compiler for Linux from GCC 4.9 to GCC 6.3.