Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cluster Adapter Type is not compatible with io adapter #12

Open
SlmnFz opened this issue Apr 18, 2024 · 0 comments
Open

Cluster Adapter Type is not compatible with io adapter #12

SlmnFz opened this issue Apr 18, 2024 · 0 comments

Comments

@SlmnFz
Copy link

SlmnFz commented Apr 18, 2024

Im using Express.js and socket.io/pm2 + typescript.

const clusterAdapter = createAdapter()(nsp);
io.adapter(clusterAdapter);
setupWorker(io);

io.adapter accepts AdapterConstructor
the error:

Argument of type 'ClusterAdapter' is not assignable to parameter of type 'AdapterConstructor'.
Type 'ClusterAdapter' is missing the following properties from type 'typeof Adapter': prototype, getEventListeners, addAbortListener, errorMonitor, and 5 more

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant