Class WebsocketServer¶
Defined in File websocket_server.hpp
Inheritance Relationships¶
Base Type¶
public drogon::WebSocketController< WebsocketServer, false >
Class Documentation¶
-
class WebsocketServer : public drogon::WebSocketController<WebsocketServer, false>¶
The Websocket server handles incoming websocket requests. Currently, this is primarily used to make inferences to video streaming workers.
Public Functions
-
WebsocketServer()¶
constructor
-
void handleNewMessage(const drogon::WebSocketConnectionPtr &conn, std::string &&message, const drogon::WebSocketMessageType &type) override¶
When a client sends a new message, this handler is invoked to parse the request.
- Parameters
conn – the websocket connection the client is using
message – the message
type – the type of message
-
void handleConnectionClosed(const drogon::WebSocketConnectionPtr &conn) override¶
When a client closes the connection, this handler is invoked.
- Parameters
conn –
-
void handleNewConnection(const drogon::HttpRequestPtr &req, const drogon::WebSocketConnectionPtr &conn) override¶
When a client opens a connection, this handler is invoked.
- Parameters
req –
conn –
- WS_PATH_LIST_BEGIN WS_PATH_ADD ("/models/infer", drogon::Get)
-
WebsocketServer()¶