-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-17813][SQL][KAFKA] Maximum data per trigger #15527
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
Closed
Closed
Changes from 1 commit
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
c45ded7
[SPARK-17812][SQL][KAFKA] parse json for topicpartitions and offsets
koeninger 12d3988
Merge branch 'master' into SPARK-17812
koeninger 3120fd8
[SPARK-17812][SQL][KAFKA] implement specified offsets and assign
koeninger 35bb8c3
[SPARK-17812][SQL][KAFKA] doc and test updates
koeninger 2e53e5a
[SPARK-17812][SQL][KAFKA] style fixes
koeninger 5e4511f
[SPARK-17812][SQL][KAFKA] additional paranoia on reset of starting of…
koeninger cae967c
Merge branch 'SPARK-17812' into SPARK-17813
koeninger 6c8d459
[SPARK-17813][SQL][KAFKA] maxOffsetsPerTrigger proportional implement…
koeninger 76ecafc
Merge branch 'master' into SPARK-17813
koeninger fde4e33
[SPARK-17813][SQL][KAFKA] fix test for upstream changes to StreamManu…
koeninger 64fca67
Merge branch 'master' into SPARK-17813
koeninger 6a7ff24
[SPARK-17813][SQL][KAFKA] set current offsets on recovery
koeninger 5e4b468
[SPARK-17813][SQL][KAFKA] spacing
koeninger File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev
Previous commit
[SPARK-17813][SQL][KAFKA] spacing
- Loading branch information
commit 5e4b468111ec20f11fc352de4075637f12e3a499
There are no files selected for viewing
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -154,7 +154,8 @@ private[kafka010] case class KafkaSource( | |
| from: Map[TopicPartition, Long], | ||
| until: Map[TopicPartition, Long]): Map[TopicPartition, Long] = { | ||
| val fromNew = fetchNewPartitionEarliestOffsets(until.keySet.diff(from.keySet).toSeq) | ||
| val sizes = until.flatMap { case (tp, end) => | ||
| val sizes = until.flatMap { | ||
| case (tp, end) => | ||
| // If begin isn't defined, something's wrong, but let alert logic in getBatch handle it | ||
| from.get(tp).orElse(fromNew.get(tp)).flatMap { begin => | ||
| val size = end - begin | ||
|
|
@@ -166,7 +167,8 @@ private[kafka010] case class KafkaSource( | |
| if (total < 1) { | ||
| until | ||
| } else { | ||
| until.map { case (tp, end) => | ||
| until.map { | ||
| case (tp, end) => | ||
| tp -> sizes.get(tp).map { size => | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. nit: use 2 spaces |
||
| val begin = from.get(tp).getOrElse(fromNew(tp)) | ||
| val prorate = limit * (size / total) | ||
|
|
||
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: use 2 spaces