Add client support for websocket subprotocol. Look for the new addSubProtocol method for details

This commit is contained in:
Benjamin Sergeant
2019-10-13 13:37:34 -07:00
parent 128545cc2b
commit c3a619f114
17 changed files with 231 additions and 40 deletions

View File

@ -71,6 +71,7 @@ int main(int argc, char** argv)
std::string redisHosts("127.0.0.1");
std::string redisPassword;
std::string appsConfigPath("appsConfig.json");
std::string subprotocol;
ix::SocketTLSOptions tlsOptions;
std::string ciphers;
std::string redirectUrl;
@ -149,6 +150,7 @@ int main(int argc, char** argv)
connectApp->add_option("--max_wait",
maxWaitBetweenReconnectionRetries,
"Max Wait Time between reconnection retries");
connectApp->add_option("--subprotocol", subprotocol, "Subprotocol");
addTLSOptions(connectApp);
CLI::App* chatApp = app.add_subcommand("chat", "Group chat");
@ -329,7 +331,8 @@ int main(int argc, char** argv)
disablePerMessageDeflate,
binaryMode,
maxWaitBetweenReconnectionRetries,
tlsOptions);
tlsOptions,
subprotocol);
}
else if (app.got_subcommand("chat"))
{