[SERVER-1038] mongos count fails Created: 21/Apr/10 Updated: 12/Jul/16 Resolved: 28/Apr/10 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Sharding |
| Affects Version/s: | None |
| Fix Version/s: | 1.5.1 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Kristina Chodorow (Inactive) | Assignee: | Eliot Horowitz (Inactive) |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
./mongos --configdb localhost:20000,localhost:20001,localhost:20002 |
||
| Participants: |
| Description |
|
> db.y.save( {"regex" : /foo/i}) ) ) > db.runCommand( {count : "y"}) db log: |
| Comments |
| Comment by auto [ 28/Apr/10 ] |
|
Author: {'login': 'erh', 'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}Message: fix count with no filter |
| Comment by Eliot Horowitz (Inactive) [ 28/Apr/10 ] |
|
was able to reproduce the last part |
| Comment by bvnx [ 28/Apr/10 ] |
|
sorry, I didn't 'watch' the issue after commenting, I'll reproduce in a clean session now – this assumes all fresh setup for both shards and config it seems it might just be due to missing 'query' property of the object sent to runCommand – I noticed that the PHP driver executes count like that? this is based off nightly: mongodb-win32-x86_64-2010-04-28 start.bat file: rem config processes rem shard processes rem router and client MongoDB shell version: 1.5.1-pre- ); { "added" : "localhost:27020", "ok" : 1 }> db.runCommand( { addshard: 'localhost:27030', allowLocal: true }); { "added" : "localhost:27030", "ok" : 1 }> db.runCommand( { enablesharding: 'shardtest' }); { "ok" : 1 }> db.runCommand({ shardcollection: 'shardtest.shardable', key: { name: 1 }}); { "collectionsharded" : "shardtest.shardable", "ok" : 1 }> db.runCommand( { listshards: 1 }); , { "_id" : "shard1", "host" : "localhost:27030" } ], ); > shardtest.shardable.save( { name: 'test' }); ); mongos console only says, apart from all other normal info: Wed Apr 28 20:12:49 Assertion failure isABSONObj() c:\work\buildslaves\windows_64bit_nightly\mongo\db\../bson/bsoninlines.h 31 hope that is helpful |
| Comment by Eliot Horowitz (Inactive) [ 25/Apr/10 ] |
|
what's shardtest? |
| Comment by Eliot Horowitz (Inactive) [ 25/Apr/10 ] |
|
can you send data, what command, etc... |
| Comment by bvnx [ 25/Apr/10 ] |
|
mongo ); mongos , unique: false } } } ntoreturn: -1 Under Windows, without a build environment, I'm unsure how to provide more in-depth info, such as a stacktrace. Notably though, a .count() on the DBCollection object works OK. |
| Comment by Eliot Horowitz (Inactive) [ 21/Apr/10 ] |
|
can't reproduce this, and did exactly what you have. |
| Comment by auto [ 21/Apr/10 ] |
|
Author: {'login': 'erh', 'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}Message: count test for |