node-redis icon indicating copy to clipboard operation
node-redis copied to clipboard

Support for edge functions (Cloudflare's new connect() API)

Open haris-codes opened this issue 2 years ago • 1 comments

Motivation

Presently node-redis doesn't work with edge functions. I keep getting an error when trying to use it on Cloudflare Workers.

In response to another issue, @leibale had written -

Redis works over TCP, and "edge functions" do not support that.

One workaround is to make Redis work with HTTP, using one of these options:

Open an issue in the redis repository and hope it'll be implemented as a core feature.
Create/use a redis module to do it.
Create/use a proxy around redis to do it.

Another option is to wait for socket workers..

Recently, Cloudflare announced their new feature - connect() - that makes it possible to connect directly to any TCP-based service from Workers.

Could you please integrate this with node-redis so we can use it on Workers?

Thank, Haris

Basic Code Example

No response

haris-codes avatar Aug 23 '23 19:08 haris-codes

yes , was looking for the same thing

upstash has an http client but wanted something similar from redis-node would be great

arcinston avatar Sep 21 '23 18:09 arcinston