<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 05:07:06 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>MongoDB Jira</title>
    <link>https://jira.mongodb.org</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>9.7.1</version>
        <build-number>970001</build-number>
        <build-date>13-04-2023</build-date>
    </build-info>


<item>
            <title>[SERVER-44828] Correct logic to re-compute dependencies after absorbing a $sort into query layer</title>
                <link>https://jira.mongodb.org/browse/SERVER-44828</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-39109&quot; title=&quot;mongod crash: Invariant failure !_exec src/mongo/db/pipeline/document_source_cursor.cpp 295&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-39109&quot;&gt;&lt;del&gt;SERVER-39109&lt;/del&gt;&lt;/a&gt; inadvertently thwarted an optimization to re-compute the set of fields needed for the aggregation. Instead of re-computing the dependencies in such a scenario, it will get confused because the $cursor stage has already been added and mistakenly report that all fields are needed for the aggregation. We should restore the optimization.&lt;/p&gt;</description>
                <environment></environment>
        <key id="1025094">SERVER-44828</key>
            <summary>Correct logic to re-compute dependencies after absorbing a $sort into query layer</summary>
                <type id="1" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14703&amp;avatarType=issuetype">Bug</type>
                                            <priority id="3" iconUrl="https://jira.mongodb.org/images/icons/priorities/major.svg">Major - P3</priority>
                        <status id="6" iconUrl="https://jira.mongodb.org/images/icons/statuses/closed.png" description="The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.">Closed</status>
                    <statusCategory id="3" key="done" colorName="success"/>
                                    <resolution id="13201">Fixed</resolution>
                                        <assignee username="charlie.swanson@mongodb.com">Charlie Swanson</assignee>
                                    <reporter username="charlie.swanson@mongodb.com">Charlie Swanson</reporter>
                        <labels>
                            <label>qopt-team</label>
                    </labels>
                <created>Mon, 25 Nov 2019 20:18:49 +0000</created>
                <updated>Sun, 29 Oct 2023 22:14:36 +0000</updated>
                            <resolved>Mon, 9 Dec 2019 20:45:59 +0000</resolved>
                                                    <fixVersion>3.6.17</fixVersion>
                    <fixVersion>4.2.3</fixVersion>
                    <fixVersion>4.0.15</fixVersion>
                                    <component>Aggregation Framework</component>
                    <component>Performance</component>
                    <component>Querying</component>
                                        <votes>0</votes>
                                    <watches>13</watches>
                                                                                                                <comments>
                            <comment id="2653652" author="xgen-internal-githook" created="Thu, 19 Dec 2019 22:16:07 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Charlie Swanson&apos;, &apos;email&apos;: &apos;charlie.swanson@mongodb.com&apos;, &apos;username&apos;: &apos;cswanson310&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-44828&quot; title=&quot;Correct logic to re-compute dependencies after absorbing a $sort into query layer&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-44828&quot;&gt;&lt;del&gt;SERVER-44828&lt;/del&gt;&lt;/a&gt; Correct logic to re-compute dependencies&lt;/p&gt;

&lt;p&gt;We do this after absorbing a $sort into query layer, but this&lt;br/&gt;
optimization was accidentally thwarted by a recent bug fix. This patch&lt;br/&gt;
restores this optimization.&lt;/p&gt;

&lt;p&gt;(cherry picked from commit 68d9027d26d469ab003bf81be95df6395d4dad19)&lt;br/&gt;
Branch: v4.0&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/17c49aae7be6a855322e6488fe605e17698fdd43&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/17c49aae7be6a855322e6488fe605e17698fdd43&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="2653634" author="xgen-internal-githook" created="Thu, 19 Dec 2019 22:07:42 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Charlie Swanson&apos;, &apos;email&apos;: &apos;charlie.swanson@mongodb.com&apos;, &apos;username&apos;: &apos;cswanson310&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-44828&quot; title=&quot;Correct logic to re-compute dependencies after absorbing a $sort into query layer&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-44828&quot;&gt;&lt;del&gt;SERVER-44828&lt;/del&gt;&lt;/a&gt; Correct logic to re-compute dependencies&lt;/p&gt;

&lt;p&gt;We do this after absorbing a $sort into query layer, but this&lt;br/&gt;
optimization was accidentally thwarted by a recent bug fix. This patch&lt;br/&gt;
restores this optimization.&lt;/p&gt;

&lt;p&gt;(cherry picked from commit 68d9027d26d469ab003bf81be95df6395d4dad19)&lt;br/&gt;
(cherry picked from commit 8170a1a318e3c12f31fcfd6094b970b0e27b9211)&lt;br/&gt;
Branch: v3.6&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/62c9e0b7393e6c636724ab3abc5ab400583cb668&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/62c9e0b7393e6c636724ab3abc5ab400583cb668&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="2594715" author="xgen-internal-githook" created="Mon, 9 Dec 2019 20:27:54 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;email&apos;: &apos;charlie.swanson@mongodb.com&apos;, &apos;name&apos;: &apos;Charlie Swanson&apos;, &apos;username&apos;: &apos;cswanson310&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-44828&quot; title=&quot;Correct logic to re-compute dependencies after absorbing a $sort into query layer&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-44828&quot;&gt;&lt;del&gt;SERVER-44828&lt;/del&gt;&lt;/a&gt; Correct logic to re-compute dependencies&lt;/p&gt;

&lt;p&gt;We do this after absorbing a $sort into query layer, but this&lt;br/&gt;
optimization was accidentally thwarted by a recent bug fix. This patch&lt;br/&gt;
restores this optimization.&lt;br/&gt;
Branch: v4.2&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/68d9027d26d469ab003bf81be95df6395d4dad19&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/68d9027d26d469ab003bf81be95df6395d4dad19&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="2580220" author="xgen-internal-githook" created="Tue, 3 Dec 2019 17:08:47 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;email&apos;: &apos;charlie.swanson@mongodb.com&apos;, &apos;name&apos;: &apos;Charlie Swanson&apos;, &apos;username&apos;: &apos;cswanson310&apos;}
&lt;p&gt;Message: PERF-1938 Performance workloads for &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-44828&quot; title=&quot;Correct logic to re-compute dependencies after absorbing a $sort into query layer&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-44828&quot;&gt;&lt;del&gt;SERVER-44828&lt;/del&gt;&lt;/a&gt;&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-perf/commit/d8108e29c1b2e3c5ac97eb65b71990be6dcd24af&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-perf/commit/d8108e29c1b2e3c5ac97eb65b71990be6dcd24af&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="2565307" author="charlie.swanson" created="Mon, 25 Nov 2019 20:20:40 +0000"  >&lt;p&gt;This fix will be authored for the 4.2 branch. The code in question has diverged sufficiently in master that this no longer appears to be a problem. I&apos;m requesting backport to the 4.0 and 3.6 branches.&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10420">
                    <name>Backports</name>
                                            <outwardlinks description="backported by">
                                                        </outwardlinks>
                                                        </issuelinktype>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                                                <inwardlinks description="is depended on by">
                                                        </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                                        </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                <customfield id="customfield_10050" key="com.atlassian.jira.toolkit:comments">
                        <customfieldname># Replies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>5.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_18555" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname># of Sprints</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2.0</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_12450" key="com.atlassian.jira.plugin.system.customfieldtypes:multicheckboxes">
                        <customfieldname>Backport Requested</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="15640"><![CDATA[v4.0]]></customfieldvalue>
    <customfieldvalue key="15141"><![CDATA[v3.6]]></customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10011" key="com.atlassian.jira.plugin.system.customfieldtypes:radiobuttons">
                        <customfieldname>Backwards Compatibility</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10038"><![CDATA[Fully Compatible]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                    <customfield id="customfield_13552" key="com.go2group.jira.plugin.crm:crm_generic_field">
                        <customfieldname>Case</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue><![CDATA[[5002K00000hwMcfQAE, 5002K00000hRbdVQAS, 5002K00000iO4Z1QAK]]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                            <customfield id="customfield_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Tue, 3 Dec 2019 17:08:47 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        4 years, 7 weeks, 6 days ago
    
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_18254" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Dependencies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue><![CDATA[]]></customfieldvalue>


                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_15850" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_17052" key="com.atlassian.jira.plugin.system.customfieldtypes:textarea">
                        <customfieldname>Downstream Changes Summary</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>MongoDB versions that include &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-39109&quot; title=&quot;mongod crash: Invariant failure !_exec src/mongo/db/pipeline/document_source_cursor.cpp 295&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-39109&quot;&gt;&lt;strike&gt;SERVER-39109&lt;/strike&gt;&lt;/a&gt;, namely &amp;gt;= 3.6.11, &amp;gt;= 4.0.6 and &amp;gt;=4.1.8, show a severe performance regression in some aggregation queries. This issue has been seen in the field, and details can be found via HELP-12236. This ticket addresses this issue.</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_17050" key="com.atlassian.jira.plugin.system.customfieldtypes:radiobuttons">
                        <customfieldname>Downstream Team Attention</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="16942"><![CDATA[Needed]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_10057" key="com.atlassian.jira.toolkit:lastusercommented">
                        <customfieldname>Last comment by Customer</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>true</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_10056" key="com.atlassian.jira.toolkit:lastupdaterorcommenter">
                        <customfieldname>Last commenter</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>luke.bonanomi@mongodb.com</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_11151" key="com.atlassian.jira.toolkit:LastCommentDate">
                        <customfieldname>Last public comment date</customfieldname>
                        <customfieldvalues>
                            4 years, 7 weeks, 6 days ago
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                    <customfield id="customfield_10032" key="com.atlassian.jira.plugin.system.customfieldtypes:select">
                        <customfieldname>Operating System</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10026"><![CDATA[ALL]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>charlie.swanson@mongodb.com</customfieldvalue>
            <customfieldvalue>xgen-internal-githook</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hw663b:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|huwc5z:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10558" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>9223372036854775807</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_23361" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Requested By</customfieldname>
                        <customfieldvalues>
                                

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_10557" key="com.pyxis.greenhopper.jira:gh-sprint">
                        <customfieldname>Sprint</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue id="3286">Query 2019-12-02</customfieldvalue>
    <customfieldvalue id="3287">Query 2019-12-16</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                <customfield id="customfield_17051" key="com.atlassian.jira.plugin.system.customfieldtypes:multicheckboxes">
                        <customfieldname>Teams Impacted</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="16946"><![CDATA[Triage and Release]]></customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_10053" key="com.atlassian.jira.ext.charting:timeinstatus">
                        <customfieldname>Time In Status</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_22870" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Triagers</customfieldname>
                        <customfieldvalues>
                                

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_14350" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>serverRank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hw5scn:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                    </customfields>
    </item>
</channel>
</rss>