-
Notifications
You must be signed in to change notification settings - Fork 543
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
ingest: manually create Kafka topic instead of configuring num.partitions #10101
Merged
dimitarvdimitrov
merged 10 commits into
main
from
dimitar/ingest/replay-speed/enable-in-end-to-end-tests
Dec 6, 2024
Merged
ingest: manually create Kafka topic instead of configuring num.partitions #10101
dimitarvdimitrov
merged 10 commits into
main
from
dimitar/ingest/replay-speed/enable-in-end-to-end-tests
Dec 6, 2024
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
This PR does three things: 1. handles unknown topic/partition errors when seeking to the right offset when starting concurrentFetchers. 2. handles unknown topic/partition errors when getting the topic ID when starting concurrentFetchers 3. enables concurrent fetching and ingestion in e2e tests Signed-off-by: Dimitar Dimitrov <dimitar.dimitrov@grafana.com>
pracucci
reviewed
Dec 4, 2024
Signed-off-by: Dimitar Dimitrov <dimitar.dimitrov@grafana.com>
Signed-off-by: Dimitar Dimitrov <dimitar.dimitrov@grafana.com>
dimitarvdimitrov
changed the title
ingest: don't fail on missing topics, run in e2e tests
ingest: manually create Kafka topic
Dec 4, 2024
Signed-off-by: Dimitar Dimitrov <dimitar.dimitrov@grafana.com>
Signed-off-by: Dimitar Dimitrov <dimitar.dimitrov@grafana.com>
dimitarvdimitrov
changed the title
ingest: manually create Kafka topic
ingest: manually create Kafka topic instead of configuring num.partitions
Dec 4, 2024
pracucci
reviewed
Dec 4, 2024
dimitarvdimitrov
requested review from
wilfriedroset,
vaxvms and
bubu11e
as code owners
December 4, 2024 14:06
pracucci
approved these changes
Dec 4, 2024
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.
LGTM! Thanks for your patience 🙏
Signed-off-by: Dimitar Dimitrov <dimitar.dimitrov@grafana.com>
Signed-off-by: Dimitar Dimitrov <dimitar.dimitrov@grafana.com>
dimitarvdimitrov
deleted the
dimitar/ingest/replay-speed/enable-in-end-to-end-tests
branch
December 6, 2024 09:10
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.
What this PR does
This PR does two things:
1. Manually creates the Kafka topic instead of relying on kgo autocreation
Here’s why kgo autocreation doesn’t work for us.
kgo.Client.ForceMetadataRefresh()
andkadm.Client.Metadata()
). There is a field on the request calledAllowAutoTopicCreation
AllowAutoTopicCreation
in the request only when doingkgo.Client.ForceMetadataRefresh
, but not when doingkadm.Client.Metadata
kgo.Client
has seen them before - either by consuming from them or producing to themIn other words, for the topic to be created we need the distributor to push records or the ingester to consume records. With concurrent fetching we can't consume until we have a topic. The distributor waits for the ingester to become ready (and register itself in the rings) before producing. This created a cycling dependency between the ingester and distributor.
Because of this we now issue an explicit
CreateTopics
request.As a result we no longer configure num.partitions in the Kafka cluster
2. Enables ingestion and fetching concurrency by default in e2e tests
This is one of the last steps before making these the defaults in Mimir.
Checklist
CHANGELOG.md
updated - the order of entries should be[CHANGE]
,[FEATURE]
,[ENHANCEMENT]
,[BUGFIX]
.about-versioning.md
updated with experimental features.