socketio / socket.io-admin-ui

Admin UI for Socket.IO

Home Page:https://admin.socket.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Multiple namespaces

heynikhil opened this issue · comments

We have an option like give namespace,

instrument(global.io, {
    auth: false,
    namespaceName: '/',
});

What if we have dynamic namespaces?

Arf, that's a good remark.

Dynamic namespaces are currently not supported, since we register event listeners only once when calling instrument():

io._nsps.forEach((nsp) => registerListeners(adminNamespace, nsp));

Two possible solutions:

  • have a list of registered namespaces, and periodically check if there are new namespaces
  • make the server emit an event when a namespace is created

This should be fixed by 74f1c20, included in version 0.1.2.