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

feat(remote_wal): append a noop record after kafka topic initialization #3040

Merged
merged 3 commits into from
Dec 29, 2023

Conversation

WenyXu
Copy link
Member

@WenyXu WenyXu commented Dec 28, 2023

I hereby agree to the terms of the GreptimeDB CLA

What's changed and what's your intention?

Append a noop record after kafka topic initialization.

If the EntryId starts from 0, then the first entry in the mito engine will be dropped after restart. The mito always replays the memtable from the flushed id + 1(i.e., 0+1=1). Therefore, The EntryId must start from 1.

Checklist

  • I have written the necessary rustdoc comments.
  • I have added the necessary unit tests and integration tests.
  • This PR does not require documentation updates.

Refer to a related PR or issue link (optional)

close #3039

@github-actions github-actions bot added docs-not-required This change does not impact docs. Size: S labels Dec 28, 2023
Copy link

codecov bot commented Dec 28, 2023

Codecov Report

Attention: 3 lines in your changes are missing coverage. Please review.

Comparison is base (7152407) 85.50% compared to head (e0397c8) 85.04%.
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3040      +/-   ##
==========================================
- Coverage   85.50%   85.04%   -0.46%     
==========================================
  Files         793      793              
  Lines      128447   128481      +34     
==========================================
- Hits       109825   109264     -561     
- Misses      18622    19217     +595     

@WenyXu WenyXu self-assigned this Dec 28, 2023
@niebayes niebayes changed the title feat: append a noop record after kafka topic initialization feat(remote_wal): append a noop record after kafka topic initialization Dec 28, 2023
@niebayes niebayes self-requested a review December 29, 2023 03:06
@niebayes
Copy link
Contributor

non-blocking: We might need to get the LEO before producing a no-op record. Or there will be one no-op record each time the metasrv starts.

For LEO, refer to this

@niebayes niebayes mentioned this pull request Dec 29, 2023
14 tasks
Copy link
Collaborator

@fengjiachun fengjiachun left a comment

Choose a reason for hiding this comment

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

LGTM

@niebayes niebayes added this pull request to the merge queue Dec 29, 2023
Merged via the queue into GreptimeTeam:main with commit 301ffc1 Dec 29, 2023
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs-not-required This change does not impact docs.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

fill the gap between local wal and Kafka wal
4 participants