Closed Sivasundareswaran closed 2 years ago
What do you mean by reusing Redis object out of scope? If an object, no matter it’s Redis or other c++ object, is out of scope, you can not use it. What do you really want to do?
Regards
What do you mean by reusing Redis object out of scope? If an object, no matter it’s Redis or other c++ object, is out of scope, you can not use it. What do you really want to do?
Regards
Hi Thanks for the replay, Like I am creating redis object using connection options but I can't able to store that into to structure, that is the reason I raised, But now after went through multiple website, I came to konw how to create and store, now I can able to store.
Hi Team , can you tell me how to reuse and keep Redis object in c++ applications .
Code : sw::redis::ConnectionOptions connection_options; connection_options.host = "10.xx.xx.xx"; connection_options.port = 6379; connection_options.password = "#######"; connection_options.socket_timeout = std::chrono::milliseconds(200); sw::redis::Redis redis(connection_options);
I am able to create and publish but not able to reuse the redis object out of the scope ,also not able to keep ,
Thanks in advance!!