Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stress test #3820

Merged
merged 19 commits into from
Jul 13, 2022
Original file line number Diff line number Diff line change
@@ -22,5 +22,5 @@ find_program(DOCKER_EXECUTABLE docker)
#if docker is found try to build the docker image in the defined docker_build stage which should be run after build
if(DOCKER_EXECUTABLE)
add_custom_target(docker_build
COMMAND ${DOCKER_EXECUTABLE} build --build-arg targetTest=azure-core-libcurl-stress-test --build-arg build=on --tag=gearama/curlstress -f Dockerfile .)
COMMAND ${DOCKER_EXECUTABLE} build --build-arg targetTest=azure-core-libcurl-stress-test --build-arg build=on --tag=azuresdkcpp/curlstress -f Dockerfile .)
endif()
Original file line number Diff line number Diff line change
@@ -54,15 +54,13 @@ void SendRequest(std::string target)
}
}

void Operation(int const& repetitions)
void Operation(int repetitions)
{
char buffer[12];
std::string base = "https://";
std::string base = "https://xyz.";
for (int i = 0; i < repetitions; i++)
{
std::cout << i << std::endl;
snprintf(buffer, sizeof(buffer), "%d", i);
SendRequest(base + buffer + ".com" + '\0');
SendRequest(base + std::to_string(i) + ".abc" + '\0');
gearama marked this conversation as resolved.
Show resolved Hide resolved
}
}