(cobra) add IXCobraConfig struct to pass cobra config around

This commit is contained in:
Benjamin Sergeant
2020-03-11 10:48:27 -07:00
parent cb9f0cb968
commit 0a11132b07
13 changed files with 93 additions and 113 deletions

View File

@ -15,10 +15,7 @@
namespace ix
{
int ws_cobra_metrics_publish_main(const std::string& appkey,
const std::string& endpoint,
const std::string& rolename,
const std::string& rolesecret,
int ws_cobra_metrics_publish_main(const ix::CobraConfig& config,
const std::string& channel,
const std::string& path,
bool stress,
@ -37,7 +34,7 @@ namespace ix
bool enablePerMessageDeflate = true;
cobraMetricsPublisher.configure(
appkey, endpoint, channel, rolename, rolesecret, enablePerMessageDeflate, tlsOptions);
config.appkey, config.endpoint, channel, config.rolename, config.rolesecret, enablePerMessageDeflate, tlsOptions);
while (!cobraMetricsPublisher.isAuthenticated())
;