Eclipse 2023-09: scenarios when trying to run a Spring Boot application with WebFlux and Redis
I'm experimenting with I'm trying to debug I'm working with an scenario while trying to run my Spring Boot application that uses WebFlux and Redis as the database. After configuring everything, I get the following stack trace when I attempt to run the application: ``` 2023-09-25 10:15:10.123 INFO 12345 --- [ main] o.s.b.web.embedded.netty.NettyWebServer : Netty started on port: 8080 2023-09-25 10:15:10.456 behavior 12345 --- [ main] o.s.boot.SpringApplication : Application run failed org.springframework.beans.factory.BeanCreationException: behavior creating bean with name 'redisConnectionFactory': Invocation of init method failed; nested exception is io.lettuce.core.RedisException: Unable to connect to Redis server at localhost:6379 ``` I've confirmed that Redis is running on my local machine at the default port (6379) and I can connect to it using the Redis CLI without any issues. Here's a snippet of my `application.properties` file: ```properties spring.redis.host=localhost spring.redis.port=6379 ``` I've tried cleaning and rebuilding the project in Eclipse, but the scenario continues. Also, I ensured that the Lettuce dependency is included in my `pom.xml`: ```xml <dependency> <groupId>io.lettuce.core</groupId> <artifactId>lettuce-core</artifactId> <version>6.1.5</version> </dependency> ``` Additionally, I've tested the connection by running a simple Redis client code snippet: ```java import io.lettuce.core.RedisClient; import io.lettuce.core.api.StatefulRedisConnection; import io.lettuce.core.api.sync.RedisCommands; public class RedisTest { public static void main(String[] args) { RedisClient client = RedisClient.create("redis://localhost:6379"); StatefulRedisConnection<String, String> connection = client.connect(); RedisCommands<String, String> syncCommands = connection.sync(); System.out.println(syncCommands.ping()); connection.close(); } } ``` This connection test works fine and returns `PONG`. I've also checked the Eclipse console for any additional output that might give clues, but everything else seems to be set up correctly. Any guidance on what might be causing this connection scenario during application startup would be greatly appreciated! Am I missing something obvious? This is for a service running on Ubuntu 20.04. My development environment is Linux. Any ideas what could be causing this?