Skip to content

test(spring-boot): [Sample Tests 12] Move the Boot 4 Kafka test into the module - #6298

Draft
runningcode wants to merge 2 commits into
no/boot4-integration-testfrom
no/boot4-kafka-test
Draft

runningcode wants to merge 2 commits into
no/boot4-integration-testfrom
no/boot4-kafka-test

Conversation

@runningcode

@runningcode runningcode commented Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

PR Stack (Sample Tests)


📜 Description

Ports the Boot 4 sample's KafkaQueueSystemTest to the integrationTest suite in sentry-spring-boot-4, the same way as for Boot 3 in #6296. That was the sample's last system test, so this PR also takes the Boot 4 sample off the system-test runner and CI.

  • Embedded broker: @EmbeddedKafka on the shared base class provides an in-JVM KRaft broker, so no Docker is needed.
  • Tests: the sample's five tests become two that keep every assertion, as for Boot 3.
  • Boot 4 differences:
    • Spring Boot 4 moved Kafka auto-configuration into its Kafka starter, so the suite depends on spring-boot-starter-kafka.
    • spring-kafka-test comes from the Boot BOM, like spring-kafka 4.
  • Retirement: the sample's system-test wiring is removed, along with its runner entries, its backend-workflow row, and its Spring Boot 4 matrix build and test steps.

One thing to know: when the test JVM exits, the embedded Kafka 4 broker logs a KafkaStorageException from its own shutdown. Its scheduler threads still write checkpoints while it deletes its temporary directory. This happens after the tests have finished and doesn't affect results. Boot 3's Kafka 3.9 broker doesn't do it.

💡 Motivation and Context

With this, the Boot 4 sample's system tests all run in-module, as the jakarta sample's do after #6296. The Boot 4 suite runs 25 tests.

💚 How did you test it?

  • All 25 suite tests pass on Spring Boot 4.1.0.
  • They also pass with the catalog set to 4.0.0, the matrix's oldest version.
  • The slimmed sample still builds.
  • :sentry-spring-boot-4:check passes.

📝 Checklist

  • I added GH Issue ID & Linear ID
  • I added tests to verify the changes.
  • No new PII added or SDK only sends newly added PII if sendDefaultPII is enabled.
  • I updated the docs if needed.
  • I updated the wizard if needed.
  • Review from the native team if needed.
  • No breaking change or entry added to the changelog.
  • No breaking change for hybrid SDKs or communicated to hybrid SDKs.
  • Public API changes reviewed by another Mobile SDK team member or implemented according to the develop docs spec.

🔮 Next steps

Do the same for Boot 2 (sentry-spring-boot).

#skip-changelog

Ports the Boot 4 sample's KafkaQueueSystemTest to the integrationTest
suite with @embeddedkafka, as for Boot 3. Spring Boot 4 needs its Kafka
starter for the auto-configuration, and spring-kafka-test comes from the
Boot BOM like spring-kafka.

The Boot 4 sample has no system tests left, so it comes off the
system-test runner, the backend workflow and the Spring Boot 4 matrix.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@sentry

sentry Bot commented Oct 20, 2026

Copy link
Copy Markdown

📲 Install Builds

Android

🔗 App Name App ID Version Configuration
SDK Size io.sentry.tests.size 8.61.0 (1) release

⚙️ sentry-android Build Distribution Settings

This was referenced Oct 20, 2026
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

# Conflicts:
#	sentry-spring-boot-4/src/integrationTest/kotlin/io/sentry/spring/boot4/integrationtest/IntegrationTest.kt

This branch has not been deployed

No deployments
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.

1 participant