[CXX-564] getLastError() fail randomly Created: 19/Mar/15 Updated: 23/Mar/15 Resolved: 23/Mar/15 |
|
| Status: | Closed |
| Project: | C++ Driver |
| Component/s: | API |
| Affects Version/s: | legacy-1.0.0 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Judy Han [X] | Assignee: | Adam Midvidy |
| Resolution: | Done | Votes: | 0 |
| Labels: | legacy-cxx | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
I have an application - a threadpool with each worker thread maintaining it's own connection, after insert (bulk) the subsequent getLastError() call randomly fail. Here is the relavant code snippet for each worker thread: void event_loader::handleInput() { catch (const MtxUtil::Exception& exc) { std::cout << "Caught an exception during getLastError.\n" << "Exception's what()=" << exc.what() << std::endl; }catch (...) { std::cout << "Caught an unknown exception during getLastError." << std::endl; }Without calling getLastError(), the program seems works fine. After adding getLastError() logic, the program works sometimes, but fails some other time, once it fails it continues to fail. Following is the output for failed case: |
| Comments |
| Comment by Adam Midvidy [ 23/Mar/15 ] |
|
Hi Judy, Sure. I will close the ticket as "Gone Away". Feel free to reopen if you are able to reproduce this again. Best, |
| Comment by Judy Han [X] [ 23/Mar/15 ] |
|
Hi Adam, Thanks. Since the problem was sporadic, it is not so easy to say it is completely fixed. Thanks! |
| Comment by Adam Midvidy [ 23/Mar/15 ] |
|
Hey Judy, Would you mind rerunning your test now that you have the driver compiling with C++11 mode? There is a possibility that this issue was caused by linking ABI incompatible libstdc++ versions, which can cause strange crashes/bugs. Adam |
| Comment by Judy Han [X] [ 19/Mar/15 ] |
|
Hi Adam, |
| Comment by Adam Midvidy [ 19/Mar/15 ] |
|
Hi Judy, Thanks for the report. I will try to reproduce this issue today. Can I have the exact SCons invocation used to compile the driver, as well as the compiler flags used to build your application? If they are the same as in Adam |
| Comment by Judy Han [X] [ 19/Mar/15 ] |
|
fixing some typo, add line number for easier reference for the code snippet: 5 15 } 18 |