MCPcopy Create free account
hub / github.com/Super-long/ChubbyGo / RedisTest

Function RedisTest

RedisTest/redis.cpp:23–33  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

21const int ThreadNumber = 100;
22
23void RedisTest(Redis* r, int clientID){
24
25 for (int i = 0; i < 5; i++){
26 std::string ClientString = std::move(std::to_string(clientID));
27
28 std::string temp = "x " + ClientString + " " + std::to_string(i) + " y";
29 r->set(ClientString.c_str(), temp.c_str());
30
31 std::cout << r->get(ClientString.c_str()) << std::endl;
32 }
33}
34
35int main(){
36 std::vector<std::thread> Threads(ThreadNumber);

Callers

nothing calls this directly

Calls 2

setMethod · 0.80
getMethod · 0.80

Tested by

no test coverage detected