[JAVA-2408] java-mongodb-driver test case failure Created: 14/Dec/16 Updated: 18/Sep/17 Resolved: 18/Sep/17 |
|
| Status: | Closed |
| Project: | Java Driver |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | ravi_ss | Assignee: | Ross Lawley |
| Resolution: | Cannot Reproduce | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Attachments: |
|
||||
| Issue Links: |
|
||||
| Description |
|
I try to run testcases for java-mongodb-driver, before making any changes to the source code. $ ./gradlew check -Dorg.mongodb.test.uri=mongodb://<ip>:27017/ :driver-core:test com.mongodb.MongoCommandException: Command failed with error -1: 'ns not found' on server <ip>:27017. The full response is { "ok" : 0.0, "errmsg" : "ns not found" } at com.mongodb.connection.ProtocolHelper.getCommandFailureException(ProtocolHelper.java:115) com.mongodb.MongoCommandException: Command failed with error -1: 'ns not found' on server <ip>:27017. The full response is { "ok" : 0.0, "errmsg" : "ns not found" } at com.mongodb.connection.ProtocolHelper.getCommandFailureException(ProtocolHelper.java:115) ii) Following 6 testcases failed with error as shown io.netty.util.internal.OutOfDirectMemoryError: failed to allocate 16777216 byte(s) of direct memory (used: 50367344, max: 67108864) java.lang.ClassCastException: io.netty.util.internal.OutOfDirectMemoryError incompatible with java.lang.RuntimeException Initially I used to get test search not found error, solved after mongodb server started with text search enabled. Regards, Hadi |
| Comments |
| Comment by Ross Lawley [ 18/Sep/17 ] |
|
Hi ravi_ss, We have been unable to reproduce the errors and as such we're closing this ticket as "Cannot Reproduce". We've been unable to identify a probable cause, so at this time have no way of taking this ticket forward. If you are able to provide any new information or insight we'll happily reopen this ticket and investigate further. Ross |
| Comment by Ross Lawley [ 09/Jan/17 ] |
|
Hi ravi_ss, I've not been able to reproduce the issue locally or via our test machines. At the moment I'm blocked on this issue until I can either reproduce locally or on a test machine. Ross |
| Comment by ravi_ss [ 21/Dec/16 ] |
|
Hi Ross, Ravi_SS |
| Comment by ravi_ss [ 16/Dec/16 ] |
|
Hi, Thanks & regards, |
| Comment by Ross Lawley [ 16/Dec/16 ] |
|
Hi ravi_ss, Many thanks for all your help with trying to debug this issue, unfortunately, I'm still no closer to identifying the cause as I'm not able to replicate the failures locally, on travis or on our own CI servers. Could you run the tests with extra netty leak detection on by passing the command line flag: -Dio.netty.leakDetection.level=advanced and attach the logs to the ticket. Could you also provide the MongoD logs for the duration of the test. Perhaps that will help shed more light on the cause for the failures. Ross |
| Comment by ravi_ss [ 16/Dec/16 ] |
|
Hi Ross, I am using netty 4.1.5.Final, Also I have tried with 4.1.6.Final facing the same issue. Thanks & regards, |
| Comment by Ross Lawley [ 15/Dec/16 ] |
|
Hi, My apologies, I misread the clirr baseline version to be the driver version. Could you confirm the version of netty you are using? Travis is running against 4.1.5.Final without any memory leaks. The 'ns not found' errors in the WriteProtocolCommandEventSpecification looks to be a race condition in the test when calling the cleanup. Ross |
| Comment by ravi_ss [ 15/Dec/16 ] |
|
Hi,
the mongodb server is
I can see the similar log in https://travis-ci.org/mongodb/mongo-java-driver/jobs/183972445 Thanks & regards, |
| Comment by Ross Lawley [ 15/Dec/16 ] |
|
Hi, Could it be running against the driver version 3.2.0? I'm seeing the following in the logs:
There have been over 50 bugfixes since version 3.2.0. Including Ross |
| Comment by ravi_ss [ 15/Dec/16 ] |
|
Hi Ross, sorry for that, Regards, |
| Comment by Ross Lawley [ 15/Dec/16 ] |
|
Hi ravi_ss, Can you confirm the version of the driver is r3.0.4 ? The test logs show a test in the WriteProtocolCommandEventSpecification is failing but that test case wasn't present in version 3.0.4 of the driver. Ross |
| Comment by ravi_ss [ 15/Dec/16 ] |
|
Hi Ross, Attached the logs of first and second run, Thanks & regards, |
| Comment by Ross Lawley [ 15/Dec/16 ] |
|
Thanks for that @ravi_ss, Can you provide the other information to help shed more light on the cause:
Ross |
| Comment by ravi_ss [ 15/Dec/16 ] |
|
Attached the logs of first and second run, |
| Comment by Ross Lawley [ 14/Dec/16 ] |
|
Hi ravi_ss, Thanks for the ticket - you are correct the text search must be enabled for the test suite. Errors aren't expected when running the tests, we have a comprehensive continuous integration suite that runs the tests over various configurations. As such I have a few questions to help diagnose the cause:
Can you attach logs from the whole test suite? I would like to see where Spock errors when reporting the 'ns not found' issues. The out of memory issues indicate you may need to increase the memory available to your JDK - you can pass the -XX:MaxDirectMemorySize= flag in the command line. Ross |