com.mongodb.MongoException: could not initialize cursor across all shards because : combinatorial limit of $in partitioning of result set exceeded @ offerStoreDE4/ s115:27018,s132:27018,s125:27018

JIRA | kay.agahd | 5 years ago
  1. 0

    weird arithmetic

    Google Groups | 5 years ago | Shi Shei
    com.mongodb.MongoException: could not initialize cursor across all shards because : combinatorial limit of $in partitioning of result set exceeded @ offerStoreDE4/ s115:27018,s132:27018,s125:27018
  2. 0

    I'm using the Java driver v2.7.2 to query a sharded system consisting of 4 shards, each 3 replicas, running linux-mongodb-v2.0.1, v2.0.2 and v2.0.4. All mongos are running v2.0.1. The query I'm executing is of this type: {_id:{$in:[1,2,3,4]}} When the inlist becomes too big (more than 265,000 id's in my case), I get the following exception, where max BSON size is greater than 2.6 times of the DBObject size: Exception in thread "main" com.mongodb.MongoInternalException: DBObject of size 6442515 is over Max BSON size 16777216 at com.mongodb.OutMessage.putObject(OutMessage.java:147) at com.mongodb.OutMessage._appendQuery(OutMessage.java:85) at com.mongodb.OutMessage.query(OutMessage.java:44) at com.mongodb.OutMessage.query(OutMessage.java:38) at com.mongodb.DBApiLayer$MyCollection.__find(DBApiLayer.java:303) at com.mongodb.DBCursor._check(DBCursor.java:369) at com.mongodb.DBCursor._hasNext(DBCursor.java:498) at com.mongodb.DBCursor.hasNext(DBCursor.java:523) When I reuse the mongo object, I don't get the exception. Moreover, I can put up to 995,000 id's into the list without any problem. Exceeding the inlist size results in an appropriate exception: Exception in thread "main" com.mongodb.MongoException: could not initialize cursor across all shards because : combinatorial limit of $in partitioning of result set exceeded @ offerStoreDE4/ s115:27018,s132:27018,s125:27018 at com.mongodb.MongoException.parse(MongoException.java:82) at com.mongodb.DBApiLayer$MyCollection.__find(DBApiLayer.java:312) at com.mongodb.DBCursor._check(DBCursor.java:369) at com.mongodb.DBCursor._hasNext(DBCursor.java:498) at com.mongodb.DBCursor.hasNext(DBCursor.java:523) However, when it's the first usage of the Mongo object then it's not yet reused and will fail as described above. For more details, please see: http://groups.google.com/group/mongodb-user/browse_thread/thread/3b96668396f0f9d4

    JIRA | 5 years ago | kay.agahd
    com.mongodb.MongoException: could not initialize cursor across all shards because : combinatorial limit of $in partitioning of result set exceeded @ offerStoreDE4/ s115:27018,s132:27018,s125:27018
  3. 0

    unauthorized db lock type:-1

    Stack Overflow | 5 years ago | Alex
    com.mongodb.MongoException: unauthorized db:mongodb-logger lock type:-1 client:192.168.23.159
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    socket exception when a shard is down

    Google Groups | 4 years ago | algol
    com.mongodb.MongoException: socket exception [CONNECT_ERROR] for shard1/algol-cloudacc:27017
  6. 0

    Lots of index failures throws error in Web UI

    GitHub | 3 years ago | jaxxstorm
    com.mongodb.MongoException: too much data for sort() with no index. add an index or specify a smaller limit

  1. sriharshakiran 2 times, last 7 months ago
5 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. com.mongodb.MongoException

    could not initialize cursor across all shards because : combinatorial limit of $in partitioning of result set exceeded @ offerStoreDE4/ s115:27018,s132:27018,s125:27018

    at com.mongodb.MongoException.parse()
  2. MongoDB Java Driver
    DBCursor.hasNext
    1. com.mongodb.MongoException.parse(MongoException.java:82)
    2. com.mongodb.DBApiLayer$MyCollection.__find(DBApiLayer.java:312)
    3. com.mongodb.DBCursor._check(DBCursor.java:369)
    4. com.mongodb.DBCursor._hasNext(DBCursor.java:498)
    5. com.mongodb.DBCursor.hasNext(DBCursor.java:523)
    5 frames