Skip to content

Commit

Permalink
[CPP] Add warnings to all SDK example apps that would check if proppe…
Browse files Browse the repository at this point in the history
…r credentials have been set or it still has the defaults. (#132)

* feat: warn for default

* Update example_integration.cpp

* Update example_integration.cpp

---------

Co-authored-by: Artūrs Kadiķis <[email protected]>
  • Loading branch information
arifBurakDemiray and ArtursKadikis authored Jan 29, 2024
1 parent 6537dad commit 74ae31c
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion examples/example_integration.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,14 @@ int main() {
ct.SetMetrics("Windows 10", "10.22", "Mac", "800x600", "Carrier", "1.0");

// start the SDK (initialize the SDK)
ct.start("YOUR_APP_KEY", "https://try.count.ly", 443, true);
string _appKey = "YOUR_APP_KEY";
string _serverUrl = "https://your.server.ly";

if(_appKey.compare("YOUR_APP_KEY") == 0 || _serverUrl.compare("https://your.server.ly") == 0) {
cerr << "Please do not use default set of app key and server url" << endl;
}

ct.start(_appKey, _serverUrl, 443, true);

ct.setAutomaticSessionUpdateInterval(5);// The value is set so low just for internal validation.
ct.setMaxRQProcessingBatchSize(2); // in most cases not needed to be set. The value is set so low just for internal validation
Expand Down

0 comments on commit 74ae31c

Please sign in to comment.