JedisConnectionException: Failed connecting to host localhost:6379报错解决办法

 JedisConnectionException: Failed connecting to host localhost:6379报错解决办法

JedisConnectionException: Failed connecting to host localhost:6379

报错原因:没有启动服务,打开服务即可

redis.clients.jedis.exceptions.JedisConnectionException:
a835311d8206bc3bd5afb4c42023cb67.png

Exception in thread "main" redis.clients.jedis.exceptions.JedisConnectionException: Failed connecting to host localhost:6379
    at redis.clients.jedis.Connection.connect(Connection.java:204)
    at redis.clients.jedis.BinaryClient.connect(BinaryClient.java:100)
    at redis.clients.jedis.Connection.sendCommand(Connection.java:125)
    at redis.clients.jedis.Connection.sendCommand(Connection.java:120)
    at redis.clients.jedis.BinaryClient.ping(BinaryClient.java:113)
    at redis.clients.jedis.BinaryJedis.ping(BinaryJedis.java:186)
    at com.wbg.mr.test.Main.main(Main.java:11)
Caused by: java.net.ConnectException: Connection refused: connect
    at java.net.DualStackPlainSocketImpl.waitForConnect(Native Method)
    at java.net.DualStackPlainSocketImpl.socketConnect(DualStackPlainSocketImpl.java:85)
    at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:345)
    at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
    at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
    at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172)
    at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
    at java.net.Socket.connect(Socket.java:589)
    at redis.clients.jedis.Connection.connect(Connection.java:181)
    ... 6 more


本站所有资源都是由网友投搞发布,或转载各大下载站,请自行检测软件的完整性!本站所有资源仅供学习与参考,请勿用于商业用途,否则产生的一切后果将由您自己承担!如有侵权请联系我们删除下架,联系方式:273171821@qq.com
0
分享到: