Support chunking for fetchBaseJoin in chaining streaming path#1090
Open
Support chunking for fetchBaseJoin in chaining streaming path#1090
Conversation
pengyu-hou
reviewed
Feb 19, 2026
| // this might be potentially slower, but spark doesn't work when the internal derivation functionality triggers | ||
| // its own spark session, or when it passes around objects | ||
| val responses = Await.result(responsesFuture, 5.second) | ||
| val responses = if (fetchChunkSize > 0 && requests.length > fetchChunkSize) { |
Collaborator
There was a problem hiding this comment.
let's try to use the joinFetchParallelChunkSize from https://github.com/airbnb/chronon/blob/main/online/src/main/scala/ai/chronon/online/Fetcher.scala#L101C15-L101C41 so you don't have to implement the chunking here again.
Collaborator
Author
There was a problem hiding this comment.
Hi @pengyu-hou using joinFetchParallelChunkSize would require some changes in the Api.buildFetcher since currently the joinFetchParallelChunkSize is not passed in this function. Also the chaining is using fetchBaseJoin instead of fetchJoin.
The duplicate chunking is just 3 lines of code so I guess it might be fine to have some duplication here and avoid changing too many code? Lemme know what you think
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
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.
Summary
fetchBaseJoincalls inJoinSourceRunner.enrichBaseJointo prevent KV store overload or timeouts when micro-batches are largespark.chronon.stream.chain.fetch_chunk_sizeis set to a positive integer, requests are split into chunks and fetched in parallel as separate Futures0(no chunking), preserving current behaviorWhy / Goal
Test Plan
Checklist
Reviewers
@hzding621 @pengyu-hou @Shiyinghaha