[JAVA-701] Got Error "unknown m/r field for sharding: $readPreference" when querying a sharded cluster Created: 27/Nov/12 Updated: 10/Mar/13 Resolved: 10/Mar/13 |
|
| Status: | Closed |
| Project: | Java Driver |
| Component/s: | None |
| Affects Version/s: | 2.10.0 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Chris Choi | Assignee: | Unassigned |
| Resolution: | Incomplete | Votes: | 0 |
| Labels: | query | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Scientific Linux 6.2 (Carbon) |
||
| Description |
|
I have recently setup a sharded cluster, but the shards are actually single nodes. The problem I'm having is that when I query the `mongos` instance, reusing some code I know works against a single node I get: Exception in thread "main" com.mongodb.CommandResult$CommandFailure: command failed [mapreduce]: { "serverUsed" : "project11.cs.st-andrews.ac.uk/138.251.214.135:27017" , "ok" : 0.0 , "errmsg" : "unknown m/r field for sharding: $readPreference"}Note: I was performing an aggregate using the new aggregate framework. |
| Comments |
| Comment by Jeffrey Yemin [ 10/Mar/13 ] |
|
Please re-open if you are still experiencing this. |
| Comment by Jeffrey Yemin [ 15/Dec/12 ] |
|
Sorry for not responding to this earlier. I think it's a duplicate of Thanks. |