Operational Defect Database

BugZero found this defect 79 days ago.

MongoDB | 2595109

[v7.0] [SBE] Aggregate command hits tripwire assertion in SortStage::SortImpl::runLimitCode()

Last update date:

3/15/2024

Affected products:

MongoDB Server

Affected releases:

7.0.6

Fixed releases:

7.0.7

Description:

Info

Issue Status as of Mar 8, 2024 On version 7.0.6, MongoDB aggregation pipelines containing all of the following: $sort $skip $limit either $lookup or $group after sort-limit-skip will fail with the following error: {code: 8349205 codeName: Location8349205 errmsg: Limit code returned unexpected value} This was an issue in the Slot Based Execution (SBE) query engine that affected $sort operations with a set limit. By default we only execute $lookup and $group in SBE, so the issue only affects aggregations containing these stages. As an immediate solution, users can do either of the following: Downgrade to version 7.0.5 Disable SBE by setting the internalQueryFrameworkControl parameter to “forceClassicEngine”. This option may come with performance regressions. db.adminCommand({setParameter: 1, internalQueryFrameworkControl: "forceClassicEngine"}) MongoDB versions 5.0, 6.0 and Rapid Release 7.2 are unaffected. This issue will be fixed in MongoDB 7.0.7.

Top User Comments

xgen-internal-githook commented on Fri, 8 Mar 2024 16:59:41 +0000: Author: {'name': 'Ivan Fefer', 'email': 'ivan.fefer@mongodb.com', 'username': 'Fefer-Ivan'} Message: SERVER-87313 Fix type mask type in buildLimitSkipSumExpression (#19584) GitOrigin-RevId: d7970d0040931cbc1377b2e27f3173fb9b1bc1b9 Branch: v7.0 https://github.com/mongodb/mongo/commit/48f2fb176ef07743f6097b4b9bbdf64aeb14ae26

Steps to Reproduce


Additional Resources / Links

Share:

BugZero® Risk Score

What's this?

Coming soon

Status

Closed

Learn More

Search:

...