#redis catch connection error

9 messages · Page 1 of 1 (latest)

opaque field
#

Are you talking your Nest's CacheModule, or are you connecting to redis manually?

hallow magnet
opaque field
#

So where do you call the code that actually connects to redis? In the post you only showed how you instantiate the objects, but that's all synchronous calls that don't initiate any connection.

#

Are you passing those to somewhere?

hallow magnet
#

if redis has valid connection settings everything works

opaque field
#

Is that the express session middleware? In that case, you're going to have to look for an Express-related answer. There's no NestJS involved there.

hallow magnet
#

ok this is new just reran the code
and now i get

[ioredis] Unhandled error event: Error: connect ECONNREFUSED 127.0.0.1:6379
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1634:16)