java.net.SocketTimeoutException: Read timed out
at java.net.SocketInputStream.socketRead0(Native Method) ~[na:1.8.0_144]
at java.net.SocketInputStream.socketRead(SocketInputStream.java:116) ~[na:1.8.0_144]
at java.net.SocketInputStream.read(SocketInputStream.java:171) ~[na:1.8.0_144]
at java.net.SocketInputStream.read(SocketInputStream.java:141) ~[na:1.8.0_144]
at java.net.SocketInputStream.read(SocketInputStream.java:127) ~[na:1.8.0_144]
at redis.clients.util.RedisInputStream.ensureFill(RedisInputStream.java:196) ~[jedis-2.9.0.jar:na]
at redis.clients.util.RedisInputStream.readByte(RedisInputStream.java:40) ~[jedis-2.9.0.jar:na]
at redis.clients.jedis.Protocol.process(Protocol.java:151) ~[jedis-2.9.0.jar:na]
at redis.clients.jedis.Protocol.read(Protocol.java:215) ~[jedis-2.9.0.jar:na]
at redis.clients.jedis.Connection.readProtocolWithCheckingBroken(Connection.java:340) ~[jedis-2.9.0.jar:na]
一般都是redis连接超时的问题,只需修改配置文件中redis连接超时时间就可以了
spring.redis.host=#
spring.redis.port=6379
spring.cache.type=redis
连接超时时间(毫秒)
spring.cache.redis.time-to-live=600000