WebSocketListener
WebSocketListener copied to clipboard
on open client socket procedure
on open client socket( from javascript) connection procedure
what is the procedure name in socket server project, so I would like to add a log on each client connected to Socket Server ?
I don't know if I understood your question. If you want to log when a client connects to the server, probably doing it after AcceptWebSocketAsync
returns a new connected client is the right place.
AcceptWebSocketAsync yes, it fires once on client connect if I want to take some properties on this connection like: remote address the connect comes from or some user info, and more, is there any doc about ?
You can find that information in the properties:
- WebSocket.LocalEndpoint
- WebSocket.RemoteEndpoint
- WebSocket.HttpRequest
Cheers.
how to get socket ID ? so I can define it in some List with a uniqe value something like : WebSocket.SocketID