finds.dev← search

// the find

PlaytikaOSS/testcontainers-spring-boot

★ 877 · Java · MIT · updated Jun 2026

Container auto-configurations for Spring Boot based integration tests

A Spring Boot auto-configuration library that spins up 35+ stateful services (Kafka, Redis, PostgreSQL, Cassandra, Keycloak, etc.) via Testcontainers during the bootstrap phase, exposing connection properties so your app wires up without any extra code. It's aimed at Spring Boot teams who want real integration tests without managing containers manually. Maintained by Playtika and actively tracking Spring Boot 4.0.

The breadth of supported services is genuinely useful — covering everything from mainstream (Kafka, Redis, MongoDB) to niche (VoltDB, MemSQL, SpiceDB, Vertica) means you don't write glue code for most stacks. Container lifecycle is handled during Spring's bootstrap phase, so connection properties are available before any beans initialize — this avoids the ordering bugs you get when trying to do this yourself. The global `embedded.containers.enabled=false` flag lets CI environments skip Docker entirely without changing test code. Active maintenance with Spring Boot 4.0 support as of 2026 and Renovate + Dependabot keeping images current.

The mandatory Spring Cloud bootstrap dependency is a real cost if you're not already using Spring Cloud — you're pulling in a non-trivial chunk of infrastructure just to get test containers to wire up before your context loads. The Spring Boot built-in `@ServiceConnection` / `@Container` approach (available since Boot 3.1) has made much of this library redundant for mainstream services; if you're on a modern Boot version, you might not need this at all. Container reuse (`reuseContainer=true`) is disabled by default and the feature itself is known to have issues in CI environments with multiple test suites running in parallel. The 877-star count relative to the scope suggests this is fairly niche — if something breaks for an obscure service like Vertica or SpiceDB, you're probably the one filing the issue.

View on GitHub → Homepage ↗

// want more like this?

We dig through GitHub every week and send a few repos picked for what you actually care about — each with an honest take like this one.

Get finds in your inbox → Search again →