[JAVA-861] query being routed to recovering node when read_preference is secondary Created: 27/Jun/13 Updated: 02/Jul/13 Resolved: 02/Jul/13 |
|
| Status: | Closed |
| Project: | Java Driver |
| Component/s: | Connection Management |
| Affects Version/s: | 2.9.1 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Dominique Guinard | Assignee: | Unassigned |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||
| Description |
|
When adding two mongo instances (2.4.2) to a replicate set containing two existing mongo instances (2.2.2) the following exception happened when adding to new instances to the replicate set: Uncaught exception.com.mongodb.CommandResult$CommandFailure: command failed [count]: { "serverUsed" : "production4/172.16.25.200:27017" , "note" : "from execCommand" , "ok" : 0.0 , "errmsg" : "node is recovering"}at com.mongodb.CommandResult.getException(CommandResult.java:88) ~[mongo-java-driver-2.9.1.jar:na] This seems to be the same issue as reported for the python driver here: https://jira.mongodb.org/browse/SERVER-7977 After this failure we first upgraded all the nodes to 2.4.2 and added the members to the replSet after the upgrade. This did work successfully. The bug https://jira.mongodb.org/browse/SERVER-7977 was reported to be actually a python driver bug but the fact that an upgrade to 2.4.2 solved the bug makes me wonder... |
| Comments |
| Comment by Jeffrey Yemin [ 02/Jul/13 ] |
|
Please try with 2.11.x and re-open if you still see it with that version. |
| Comment by Jeffrey Yemin [ 02/Jul/13 ] |
|
This was fixed in 2.11.0: |
| Comment by Jeffrey Yemin [ 28/Jun/13 ] |
|
Also, have you tried this with a newer version of the driver? 2.9.1 is rather old, and has a serious bug so you should at minimum upgrade to 2.9.3. |
| Comment by Jeffrey Yemin [ 28/Jun/13 ] |
|
Can you post the full stack trace please? |