Connection refused: connect错误处理

时间:2025-02-13 08:12:36

我的maven项目 install 就会给我报如下错误总是 BUILD FAILURE 各种排查 发现这是缺少redis端口导致  因为我的项目用到了redis ,所以把我的redis 服务开启就OK了 

Running bos_fore.JedisTest

Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 1.093 sec <<< FAILURE!
testJedis(bos_fore.JedisTest)  Time elapsed: 1.057 sec  <<< ERROR!
: : Connection refused: connect
at (:148)
at (:75)
at (:77)
at (:183)
at (:98)
at (:365)
at bos_fore.(:12)
at .invoke0(Native Method)
at (:57)
at (:43)
at (:606)
at $(:47)
at (:12)
at (:44)
at (:17)
at (:271)
at .(:70)
at .(:50)
at $(:238)
at $(:63)
at (:236)
at $000(:53)
at $(:229)
at (:309)
at .junit4.(:252)
at .junit4.(:141)
at .junit4.(:112)
at .invoke0(Native Method)
at (:57)
at (:43)
at (:606)
at (:189)
at $(:165)
at (:85)
at (:115)
at (:75)
Caused by: : Connection refused: connect
at (Native Method)
at (:85)
at (:339)
at (:200)
at (:182)
at (:172)
at (:392)
at (:579)
at (:142)
... 35 more