Hello, nginx team.
 
I'm using nginx as reverse proxy .
I'm trying to make nginx plugin module(I'm noob of this) for some purpose .
I have back-server opening websocket behind nginx .
client <-> nginx(reverse proxy) <-> back-server(websocket)
back-server is listening 3 numbers of websocket.
- websocket(A)
- websocket(B) 
- websocket(C) 
I'd like to watch websocket(only A) connection status(connection 
fail/opened/closed) in nginx plugin module for some purpose.
i can catch the request websocket 'A' connection in nginx plugin module by 
registering NGX_HTTP_ACCESS_PHASE handler(parse header and compare 
subprotocol(A) of http request).
Query :
Now, how can i get the websocket connection status(connection 
fail/opened/closed) event with the same http request context getting from 
NGX_HTTP_ACCESS_PHASE handler ?
scenario : 
 1. get websocket(A) connection request in nginx plugin module .
 2. catch event in nginx plugin moudle when the request failed / opened and 
closed .
 3. when the connection is opened or closed,i do some work .
More query :
Is the context from NGX_HTTP_ACCESS_PHASE handler valid until websocket 
connection closed?  (ngx_http_foo_handler(ngx_http_request_t *r) <- context r )
If not , is there another context valid from http-requested to websocket 
connection closed?  
 
API & simple sample code will be very helpful .
 
Thank you for your support
_______________________________________________
nginx mailing list -- nginx@nginx.org
To unsubscribe send an email to nginx-le...@nginx.org

Reply via email to