ioredis: after upgraded ioredis from 4.10.0 to 4.11.1 Error: connect ETIMEDOUT
error:
Jul 02 21:23:28 server boot[8665]: [2019/07/02 21:23:28.994] [MASTER] [PID: 008665] [ERROR] [CORE] [SERVICE] [REDIS] error
Jul 02 21:23:28 server boot[8665]: [2019/07/02 21:23:28.996] [MASTER] [PID: 008665] [ERROR] 7/2/2019, 9:23:28 PM unhandledRejection Error: connect ETIMEDOUT
Jul 02 21:23:28 server boot[8665]: at Socket.<anonymous> (/var/p3x/server.patrikx3.com/node_modules/ioredis/built/redis/index.js:270:31)
Jul 02 21:23:28 server boot[8665]: at Object.onceWrapper (events.js:288:20)
Jul 02 21:23:28 server boot[8665]: at Socket.emit (events.js:200:13)
Jul 02 21:23:28 server boot[8665]: at Socket._onTimeout (net.js:434:8)
Jul 02 21:23:28 server boot[8665]: at listOnTimeout (internal/timers.js:531:17)
Jul 02 21:23:28 server boot[8665]: at processTimers (internal/timers.js:475:7) {
Jul 02 21:23:28 server boot[8665]: errorno: 'ETIMEDOUT',
Jul 02 21:23:28 server boot[8665]: code: 'ETIMEDOUT',
Jul 02 21:23:28 server boot[8665]: syscall: 'connect'
Jul 02 21:23:28 server boot[8665]: } Promise {
Jul 02 21:23:28 server boot[8665]: <rejected> Error: connect ETIMEDOUT
Jul 02 21:23:28 server boot[8665]: at Socket.<anonymous> (/var/p3x/server.patrikx3.com/node_modules/ioredis/built/redis/index.js:270:31)
Jul 02 21:23:28 server boot[8665]: at Object.onceWrapper (events.js:288:20)
Jul 02 21:23:28 server boot[8665]: at Socket.emit (events.js:200:13)
Jul 02 21:23:28 server boot[8665]: at Socket._onTimeout (net.js:434:8)
Jul 02 21:23:28 server boot[8665]: at listOnTimeout (internal/timers.js:531:17)
Jul 02 21:23:28 server boot[8665]: at processTimers (internal/timers.js:475:7) {
Jul 02 21:23:28 server boot[8665]: errorno: 'ETIMEDOUT',
Jul 02 21:23:28 server boot[8665]: code: 'ETIMEDOUT',
Jul 02 21:23:28 server boot[8665]: syscall: 'connect'
Jul 02 21:23:28 server boot[8665]: }
Jul 02 21:23:28 server boot[8665]: }
With 4.10.0 it works.
How I connect:
const settings = {
"url2": "redis://:password@127.0.0.1:6379/0",
"url": "redis+unix://:password@/var/run/redis/redis-server.sock?db=0"
}
return new Redis(settings.url);
with 4.10.0 i can connect either url, with 4.11.0 i get timeout.
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 46 (1 by maintainers)
Commits related to this issue
- fix: ETIMEDOUT error with Bluebird when connecting. There's a race condition when making connections in 4.11.x, which will happen easier with Bluebird & Unix socks. Thank you to @jeremytm & @p3x-r... — committed to redis/ioredis by luin 5 years ago
- fix: ETIMEDOUT error with Bluebird when connecting. (#925) There's a race condition when making connections in 4.11.x, which will happen easier with Bluebird & Unix socks. Thank you to @jeremyt... — committed to redis/ioredis by luin 5 years ago
- chore(release): 4.11.2 [skip ci] ## [4.11.2](https://github.com/luin/ioredis/compare/v4.11.1...v4.11.2) (2019-07-13) ### Bug Fixes * ETIMEDOUT error with Bluebird when connecting. ([#925](https://g... — committed to redis/ioredis by semantic-release-bot 5 years ago
- chore(release): 4.11.2 [skip ci] ## [4.11.2](https://github.com/luin/ioredis/compare/v4.11.1...v4.11.2) (2019-07-13) ### Bug Fixes * ETIMEDOUT error with Bluebird when connecting. ([#925](https://g... — committed to janus-dev87/ioredis-work by janus-dev87 5 years ago
Debug info can be enabled by setting the env variable
DEBUGtoioredis:*:🎉 This issue has been resolved in version 4.11.2 🎉
The release is available on:
Your semantic-release bot 📦🚀