-
-
Notifications
You must be signed in to change notification settings - Fork 341
fix(Kafka): Bump image version to prevent container crash on startup #1604
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
Conversation
✅ Deploy Preview for testcontainers-dotnet ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
WalkthroughKafka component versions are upgraded across the codebase to resolve test timeout issues in GitHub Actions. The default KafkaBuilder image is updated from 7.5.9 to 7.5.12, test Docker images are bumped to newer versions, and corresponding test configurations are updated to reference the new image tags. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes
Poem
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
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.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
src/Testcontainers.Kafka/KafkaBuilder.cs(2 hunks)tests/Testcontainers.Kafka.Tests/Dockerfile(1 hunks)tests/Testcontainers.Kafka.Tests/KafkaContainerTest.cs(2 hunks)
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: diegosasw
Repo: testcontainers/testcontainers-dotnet PR: 1583
File: src/Testcontainers.KurrentDb/Testcontainers.KurrentDb.csproj:7-7
Timestamp: 2025-11-17T17:58:43.958Z
Learning: In the testcontainers-dotnet repository, JetBrains.Annotations should use version 2023.3.0 to maintain consistency with the main Testcontainers csproj, rather than always using the latest available version.
📚 Learning: 2025-11-17T17:58:43.958Z
Learnt from: diegosasw
Repo: testcontainers/testcontainers-dotnet PR: 1583
File: src/Testcontainers.KurrentDb/Testcontainers.KurrentDb.csproj:7-7
Timestamp: 2025-11-17T17:58:43.958Z
Learning: In the testcontainers-dotnet repository, JetBrains.Annotations should use version 2023.3.0 to maintain consistency with the main Testcontainers csproj, rather than always using the latest available version.
Applied to files:
tests/Testcontainers.Kafka.Tests/KafkaContainerTest.cstests/Testcontainers.Kafka.Tests/Dockerfilesrc/Testcontainers.Kafka/KafkaBuilder.cs
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
- GitHub Check: ci (Testcontainers.Kafka, ubuntu-24.04)
- GitHub Check: ci (Testcontainers, ubuntu-24.04)
- GitHub Check: analyze (csharp)
🔇 Additional comments (3)
tests/Testcontainers.Kafka.Tests/KafkaContainerTest.cs (1)
102-102: LGTM! Stage names correctly updated.The stage parameter updates align perfectly with the Dockerfile aliases. Both
ApacheKafkaConfigurationandApacheKafkaNativeConfigurationnow reference the new Kafka 4.1.1 images, maintaining consistency across the test suite.Also applies to: 112-112
src/Testcontainers.Kafka/KafkaBuilder.cs (1)
8-8: LGTM! Default image version updated consistently.The patch version bump from 7.5.9 to 7.5.12 addresses the container crash issue mentioned in the PR objectives. Both the constant and its documentation example are updated consistently, ensuring users see the correct version reference.
Also applies to: 42-42
tests/Testcontainers.Kafka.Tests/Dockerfile (1)
1-1: Confirm the Dockerfile and KafkaBuilder.cs are aligned on the Kafka version.Both the Dockerfile and KafkaBuilder.cs specify version 7.5.12 of the cp-kafka image, maintaining consistency across the codebase.
What does this PR do?
This PR updates the Kafka versions. The Kafka module is now using the latest patch of the default image.
I'm not entirely sure what caused it, but the previous versions sometimes crashed on container startup. While testing in GH Codespaces, the old versions would fail after a few runs with various errors, usually pointing to a container crash at startup.
With the updated versions, I haven't seen any issues. I ran Codespaces for several hours without failures, whereas the old versions would fail quickly.
Why is it important?
Remove flakiness.
Related issues
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.