When I try to run my Spring Boot app using IntelliJ IDE, everything builds properly and no warning and errors are show. Once the app starts running the following runtime exception occurs:
Can't start redis server. Check logs for details. Redis process log:
This is the line where the exception is thrown:
The funny thing is that outputStringBuffer.toString()
returns empty string.
Now, I am running Redis via the Docker. Now to be sure that the Redis is indeed up and running and that there is no issue with the Docker, I added Redis as a database in IntelliJ IDE and when I execute the following command: SET 'foo' 'bar'
the appropriate key/value data was added successfully.
I even tried to install and run Redis locally but nothing changed, I still received the same error as above.
I double checked that every possible configuration is OK and indeed it is. I can connect to Redis via IntelliJ and DBeaver but I cannot connect it from my Spring Boot appplication.
2
Answers
Did you configure the application.yml file to load your redis server’s host, port and password?
For example:
This seems to be a common problem: