When creating a simple server to listen on a UNIX domain socket…
var server = require("net").createServer();
server.listen("/tmp/whatever.sock"); // Listen at UNIX domain socket
server.on("connection", function(stream) {
// What now?
});
…what uniquely identifies that stream
when it hits the "connection"
-callback?
When working with WebSockets, I'm used to creating a var clients = {}
and storing streams in it by the IP-and-port the connection originated from.
What's the equivalent "IP-and-port" unique identifier for a UNIX-domain socket and how can I see it from Node?