Skip to content

Instantly share code, notes, and snippets.

@asapelkin
Created December 13, 2017 18:59
Show Gist options
  • Save asapelkin/9de7007e55f41234641e396198a634bc to your computer and use it in GitHub Desktop.
Save asapelkin/9de7007e55f41234641e396198a634bc to your computer and use it in GitHub Desktop.
string appSid = "CLIENT_SID";
string appServerSid = "89.108.120.<xx>/APP_SERVER";
com::interproc::Node* node = new com::interproc::Node(appSid, *glb_ioservice);
glb_appServerNodeAddr = NodeAddress(appServerSid);
glb_dbManager = new DatabaseManager("GCDDB",
std::unique_ptr<DatabaseAccess>(static_cast<DatabaseAccess*>(new DatabaseRemoteAccess("GCDDB", node, glb_appServerNodeAddr))),
"<xx>",
"<xx>",
*glb_ioservice);
string request = "select * from sys.users limit 1;";
com::sys::DatabaseManager::OnTableReceivedClb func = [](std::shared_ptr< com::sql::SqlTable >){cout<<"hello world"<<endl;};
glb_dbManager->executeSqlRequest(request, func, "GCDDB");
glb_ioservice->run();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment