Skip to content
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

fix: reuse batch response max timestamp immediately #905

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

hzding621
Copy link
Collaborator

Summary

This change will immediately use the batch response's max timestamp in the lambda aggregation to exclude streaming rows that are before the timestamp, without waiting for groupBy serving info to get refreshed.

Only the uncached flow is updated for now, because the (cached) batchIr objects currently don't include the timestamp, and change to this is left out of scope.

Why / Goal

When batch response's latest timestamp is later than GroupByServingInfo's end ts (which indicates staleness of GroupByServingInfo's staleness), the TTL cache is updated asynchronously, and occasionally can fail. In the meantime, the initial request will keep using stale end ts, causing the aggregation results to be wrong as extra streaming rows that should've been excluded is included.

Test Plan

  • Added Unit Tests
  • Covered by existing CI
  • Integration tested

wip

Checklist

  • Documentation update

Reviewers

@pengyu-hou @yuli-han

Copy link
Collaborator

@pengyu-hou pengyu-hou left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

Co-authored-by: Pengyu Hou <[email protected]>
Signed-off-by: hzding621 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants