Add support for Testcontainer Redis
Add support for the official `com.redis:testcontainers-redis` container. See gh-41450
This commit is contained in:
committed by
Phillip Webb
parent
926b0ec1c8
commit
e7faca3bbb
@@ -107,8 +107,8 @@ This works as long as Spring Boot is able to get the instance of the `Container`
|
||||
|
||||
If you're using a `@Bean` method, Spring Boot won't call the bean method to get the Docker image name, because this would cause eager initialization issues.
|
||||
Instead, the return type of the bean method is used to find out which connection detail should be used.
|
||||
This works as long as you're using typed containers, e.g. `Neo4jContainer` or `RabbitMQContainer`.
|
||||
This stops working if you're using `GenericContainer`, e.g. with Redis, as shown in the following example:
|
||||
This works as long as you're using typed containers such as `Neo4jContainer` or `RabbitMQContainer`.
|
||||
This stops working if you're using `GenericContainer`, for example with Redis as shown in the following example:
|
||||
|
||||
include-code::MyRedisConfiguration[]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user