<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 05:56:53 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-63099] Constant folding should not assume arithmetic is associative or commutative in the general case</title>
                <link>https://jira.mongodb.org/browse/SERVER-63099</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;Currently, arithmetic aggregation expressions like &lt;a href=&quot;https://github.com/10gen/mongo/blob/f27135ef2b94b67806614cea3e72216187897e7e/src/mongo/db/pipeline/expression.h?plain=1#L2115&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;$multiply are marked as associative and commutative&lt;/a&gt; which allows the &lt;a href=&quot;https://github.com/10gen/mongo/blob/f27135ef2b94b67806614cea3e72216187897e7e/src/mongo/db/pipeline/expression.cpp?plain=1#L3645&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;constant folding optimization&lt;/a&gt; to rearrange constants to combine as many of them as possible during optimization.&lt;/p&gt;

&lt;p&gt;There are three reasons this is not a valid optimization in general:&lt;/p&gt;

&lt;p&gt;1. For integers, this is not a safe optimization due to overflow. For example, &lt;tt&gt;1073741824*-1*2 == -2147483648&lt;/tt&gt;, but &lt;tt&gt;1073741824*2*-1&lt;/tt&gt; overflows.&lt;/p&gt;

&lt;p&gt;2. Floating point arithmetic is not generally associative. See &lt;a href=&quot;https://docs.oracle.com/cd/E19957-01/806-3568/ncg_goldberg.html&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;this paper&lt;/a&gt;, specifically:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;Due to roundoff errors, the associative laws of algebra do not necessarily hold for floating-point numbers. For example, the expression (x+y)&lt;ins&gt;z has a totally different answer than x&lt;/ins&gt;(y+z) when x = 1030, y = -1030 and z = 1 (it is 1 in the former case, 0 in the latter). The importance of preserving parentheses cannot be overemphasized.&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;3. Type coercions occur when performing an operation on multiple types. For example, &lt;tt&gt;1 + 0.5 + 2&lt;/tt&gt; will convert 1 from an integer to a float before adding it to 0.5. These type coercions are dependent on the order of operations and could change the result. See the &quot;steps to reproduce&quot; section for an example with `NumberDecimal`.&lt;/p&gt;

&lt;p&gt;Because we can&apos;t know if a fieldpath will resolve to a specific number type or a value within a specific range, we cannot rule out any kind of overflow or type coercion.&lt;/p&gt;

&lt;p&gt;After investigation, this only applies to ExpressionAdd and ExpressionMultiply.&lt;/p&gt;

&lt;p&gt;As part of the fix for this ticket, we&apos;ll implement a left-to-right constant folding optimization that respects the order of operations during query execution while folding as many constants as is safe. For example, &lt;tt&gt;&lt;span class=&quot;error&quot;&gt;&amp;#91;c1, c2, c3, &amp;quot;$v&amp;quot;, c5, c6&amp;#93;&lt;/span&gt;&lt;/tt&gt; will be folded to &lt;tt&gt;&lt;span class=&quot;error&quot;&gt;&amp;#91;c&amp;#39;, &amp;quot;$v&amp;quot;, c5, c6&amp;#93;&lt;/span&gt;&lt;/tt&gt;.&lt;/p&gt;</description>
                <environment></environment>
        <key id="1973256">SERVER-63099</key>
            <summary>Constant folding should not assume arithmetic is associative or commutative in the general case</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="davis.haupt@mongodb.com">Davis Haupt</assignee>
                                    <reporter username="davis.haupt@mongodb.com">Davis Haupt</reporter>
                        <labels>
                            <label>query-director-triage</label>
                    </labels>
                <created>Fri, 28 Jan 2022 17:25:34 +0000</created>
                <updated>Sun, 29 Oct 2023 21:43:26 +0000</updated>
                            <resolved>Mon, 11 Jul 2022 14:19:51 +0000</resolved>
                                                    <fixVersion>6.1.0-rc0</fixVersion>
                                                        <votes>0</votes>
                                    <watches>16</watches>
                                                                                                                <comments>
                            <comment id="4704778" author="JIRAUSER1259769" created="Tue, 26 Jul 2022 10:11:20 +0000"  >&lt;p&gt;Requesting Backport as the issue reproduced in &lt;a href=&quot;https://buildbaron.corp.mongodb.com/ui/#/bfg/BFG-1274926&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;BFG-1274926&lt;/a&gt; on v6.0.&lt;/p&gt;</comment>
                            <comment id="4670498" author="xgen-internal-githook" created="Mon, 11 Jul 2022 14:17:53 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Davis Haupt&apos;, &apos;email&apos;: &apos;davis.haupt@mongodb.com&apos;, &apos;username&apos;: &apos;davish&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-63099&quot; title=&quot;Constant folding should not assume arithmetic is associative or commutative in the general case&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-63099&quot;&gt;&lt;del&gt;SERVER-63099&lt;/del&gt;&lt;/a&gt; Add left-associative constant folding optimization for $add and $multiply&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/b06f115c9575f51013c77c76b12d986c3373cd1f&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/b06f115c9575f51013c77c76b12d986c3373cd1f&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="4636771" author="xgen-internal-githook" created="Thu, 23 Jun 2022 21:17:15 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Davis Haupt&apos;, &apos;email&apos;: &apos;davis.haupt@mongodb.com&apos;, &apos;username&apos;: &apos;davish&apos;}
&lt;p&gt;Message: Merge remote-tracking branch &apos;origin/master&apos; into davish/&lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-63099&quot; title=&quot;Constant folding should not assume arithmetic is associative or commutative in the general case&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-63099&quot;&gt;&lt;del&gt;SERVER-63099&lt;/del&gt;&lt;/a&gt;&lt;br/&gt;
Branch: davish/&lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-63099&quot; title=&quot;Constant folding should not assume arithmetic is associative or commutative in the general case&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-63099&quot;&gt;&lt;del&gt;SERVER-63099&lt;/del&gt;&lt;/a&gt;&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/a119091c8ea63adc1126f92247457c02781e1797&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/a119091c8ea63adc1126f92247457c02781e1797&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="4636769" author="xgen-internal-githook" created="Thu, 23 Jun 2022 21:17:11 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Davis Haupt&apos;, &apos;email&apos;: &apos;davis.haupt@mongodb.com&apos;, &apos;username&apos;: &apos;davish&apos;}
&lt;p&gt;Message: Merge remote-tracking branch &apos;origin/master&apos; into davish/&lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-63099&quot; title=&quot;Constant folding should not assume arithmetic is associative or commutative in the general case&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-63099&quot;&gt;&lt;del&gt;SERVER-63099&lt;/del&gt;&lt;/a&gt;&lt;br/&gt;
Branch: davish/&lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-63099&quot; title=&quot;Constant folding should not assume arithmetic is associative or commutative in the general case&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-63099&quot;&gt;&lt;del&gt;SERVER-63099&lt;/del&gt;&lt;/a&gt;&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/0d2029091f28a5e7e6c5fc225937dabf197cdd8b&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/0d2029091f28a5e7e6c5fc225937dabf197cdd8b&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="4538143" author="davis.haupt" created="Tue, 10 May 2022 14:04:47 +0000"  >&lt;p&gt;Satisfactory integration tests for this PR are blocked on &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-65735&quot; title=&quot;$add operator should not use DoubleDoubleSummation in the classic engine&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-65735&quot;&gt;&lt;del&gt;SERVER-65735&lt;/del&gt;&lt;/a&gt;.&lt;/p&gt;</comment>
                            <comment id="4389366" author="davis.haupt" created="Thu, 3 Mar 2022 15:38:20 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=david.percy&quot; class=&quot;user-hover&quot; rel=&quot;david.percy&quot;&gt;david.percy&lt;/a&gt; I agree that that&apos;s a valid way to interpret it, but to give the other interpretation, the distinction that &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=geert.bosch&quot; class=&quot;user-hover&quot; rel=&quot;geert.bosch&quot;&gt;geert.bosch&lt;/a&gt; and &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=anna.wawrzyniak&quot; class=&quot;user-hover&quot; rel=&quot;anna.wawrzyniak&quot;&gt;anna.wawrzyniak&lt;/a&gt; made in the type promotion discussion last month was that users provide arguments to expressions like $add and $multiply in an explicit ordering. Accumulators like $sum, on the other hand, operate over a stream of documents that the user isn&apos;t explicitly providing in any order, and so it&apos;s much less unexpected that the optimizer could choose the ordering of the stream of documents based on an index, for example.&lt;/p&gt;</comment>
                            <comment id="4358096" author="JIRAUSER1258247" created="Wed, 16 Feb 2022 09:00:30 +0000"  >&lt;p&gt;The above benchmark clearly shows that in some cases (that can be quite common) there will be a ~20% performance regression. This is very substantial, and I believe we cannot push such a change.&lt;br/&gt;
There could be other solutions to this problem. For instance, if the arguments of all affected functions are normalized (ordered in some deterministic way) in advance, then both constant folding and direct execution should produce the same result. This normalization could be based on some heuristic that minimizes the possibility of overflow and other edge cases.&lt;/p&gt;</comment>
                            <comment id="4351704" author="davis.haupt" created="Fri, 11 Feb 2022 22:16:29 +0000"  >&lt;p&gt;The new Genny workload in PERF-2796 seems to 1) measure the impact of constant folding well and 2) show that adding a left-associative constant folding optimization can bring performance back up to the level seen on master currently if users manually re-arrange their operands to put all fieldpaths at the end of the operand list.&lt;/p&gt;

&lt;p&gt;&#160;&lt;br/&gt;
 The new workload measures three optimization levels:&lt;/p&gt;
&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;Full associativity and commutativity (master): All constants in an operand list are folded together into a single constant placed at the end of the operand list. &lt;tt&gt;&lt;span class=&quot;error&quot;&gt;&amp;#91;c1, c2, &amp;quot;$v&amp;quot;, c3, c4&amp;#93;&lt;/span&gt; =&amp;gt; &lt;span class=&quot;error&quot;&gt;&amp;#91;&amp;quot;$v&amp;quot;, c&amp;#39;&amp;#93;&lt;/span&gt;&lt;/tt&gt;.&lt;br/&gt;
 &#160;&lt;/li&gt;
	&lt;li&gt;No associativity: If there is any fieldpath in the operand list, then no constants are folded together. &lt;tt&gt;&lt;span class=&quot;error&quot;&gt;&amp;#91;c1, c2, &amp;quot;$v&amp;quot;, c3, c4&amp;#93;&lt;/span&gt; =&amp;gt; &lt;span class=&quot;error&quot;&gt;&amp;#91;c1, c2, &amp;quot;$v&amp;quot;, c3, c4&amp;#93;&lt;/span&gt;&lt;/tt&gt;, but &lt;tt&gt;&lt;span class=&quot;error&quot;&gt;&amp;#91;c1, c2, c3, c4&amp;#93;&lt;/span&gt; =&amp;gt; c&apos;&lt;/tt&gt;.&lt;/li&gt;
&lt;/ul&gt;


&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;Left associativity: All constants before the first fieldpath are folded together. &lt;tt&gt;&lt;span class=&quot;error&quot;&gt;&amp;#91;c1, c2, &amp;quot;$v&amp;quot;, c3, c4&amp;#93;&lt;/span&gt; =&amp;gt; &lt;span class=&quot;error&quot;&gt;&amp;#91;c&amp;#39;&amp;#39;, &amp;quot;$v&amp;quot;, c3, c4&amp;#93;&lt;/span&gt;&lt;/tt&gt;.&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;Note that the following results are from a single run of each configuration and so some variance is expected, but the orders of magnitude are what is significant. All numbers are in nanoseconds.&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;
&lt;div class=&apos;table-wrap&apos;&gt;
&lt;table class=&apos;confluenceTable&apos;&gt;&lt;tbody&gt;
&lt;tr&gt;
&lt;th class=&apos;confluenceTh&apos;&gt;Test&lt;/th&gt;
&lt;th class=&apos;confluenceTh&apos;&gt;&lt;a href=&quot;https://spruce.mongodb.com/task/sys_perf_linux_3_node_replSet_constant_fold_arithmetic_patch_0950fe1549223a5b6f59e04757c121194c970986_62057f02d1fe072024889470_22_02_10_21_10_57/trend-charts?execution=0&amp;amp;sortBy=STATUS&amp;amp;sortDir=ASC&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;full associativity (master)&lt;/a&gt;&lt;/th&gt;
&lt;th class=&apos;confluenceTh&apos;&gt;&lt;a href=&quot;https://spruce.mongodb.com/task/sys_perf_linux_3_node_replSet_constant_fold_arithmetic_patch_65bbf4f4ff29f29825aae0ac71b6ea5bb06c75ce_6206c6087742ae56981878ab_22_02_11_20_24_59/trend-charts?execution=0&amp;amp;sortBy=STATUS&amp;amp;sortDir=ASC&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;no associativity&lt;/a&gt;&lt;/th&gt;
&lt;th class=&apos;confluenceTh&apos;&gt;&lt;a href=&quot;https://spruce.mongodb.com/task/sys_perf_linux_3_node_replSet_constant_fold_arithmetic_patch_65bbf4f4ff29f29825aae0ac71b6ea5bb06c75ce_6206c5761e2d177ba1013930_22_02_11_20_23_25/trend-charts?execution=0&amp;amp;sortBy=STATUS&amp;amp;sortDir=ASC&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;left-associative folding&lt;/a&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;All Constants&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;7,644,713&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;8,708,571.2 (-14%)&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;8,606,583.6 (-13%)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Fieldpath at start&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;9,068,763.1&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;1,970,502,869.6 (-21,600%)&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;1,988,735,127.5 (-21,800%)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Fieldpath in middle&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;9,105,555.1&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;1,921,775,986.3 (-21,000%)&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;563,282,252.6 (-6,000%)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Fieldpath at end&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;9,032,214.8&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;1,958,538,232.6 (-21,500%)&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;8,572,041.8 (+5.09%)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;
&lt;/div&gt;
</comment>
                            <comment id="4348002" author="davis.haupt" created="Thu, 10 Feb 2022 16:03:07 +0000"  >&lt;p&gt;Opened PERF-2796 (with a PR here: &lt;a href=&quot;https://github.com/mongodb/genny/pull/617&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/genny/pull/617&lt;/a&gt;) to create a new workload to measure constant folding speedups and get some baseline metrics on performance before fixing correctness. I&apos;m also planning on adding a new DSI configuration variant with optimization disabled to compare metrics with the additional left-associative constant folding logic that&apos;s to be added.&lt;/p&gt;</comment>
                            <comment id="4321642" author="davis.haupt" created="Fri, 28 Jan 2022 17:57:16 +0000"  >&lt;p&gt;The simplest fix would be to change isAssociative() and isCommutative() for multiplication and addition. But there should be some discussion on whether there&apos;s a way to enable these optimizations in special cases where it&apos;s known to not cause overflow or trigger a type conversion.&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10420">
                    <name>Backports</name>
                                            <outwardlinks description="backported by">
                                                        </outwardlinks>
                                                        </issuelinktype>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                            <outwardlinks description="depends on">
                                        <issuelink>
            <issuekey id="2027223">SERVER-65735</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is depended on by">
                                                        </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10320">
                    <name>Documented</name>
                                                                <inwardlinks description="is documented by">
                                        <issuelink>
            <issuekey id="2024768">DOCS-15241</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10010">
                    <name>Duplicate</name>
                                                                <inwardlinks description="is duplicated by">
                                        <issuelink>
            <issuekey id="2060764">SERVER-66969</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10520">
                    <name>Problem/Incident</name>
                                            <outwardlinks description="causes">
                                        <issuelink>
            <issuekey id="2061574">SERVER-67011</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="1971619">SERVER-63018</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is related to">
                                        <issuelink>
            <issuekey id="2027223">SERVER-65735</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                <customfield id="customfield_10050" key="com.atlassian.jira.toolkit:comments">
                        <customfieldname># Replies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>10.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="23470"><![CDATA[v6.0]]></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_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Thu, 3 Feb 2022 02:31:04 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        1 year, 28 weeks, 1 day ago
    
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_18254" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Dependencies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue><![CDATA[<s><a href='https://jira.mongodb.org/browse/PERF-2796'>PERF-2796</a></s>, <s><a href='https://jira.mongodb.org/browse/SERVER-65735'>SERVER-65735</a></s>]]></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>Users with queries that multiply or add many constants together along with some fieldpaths in an aggregation pipeline using the $add and $multiply expressions may find that their queries become slower after &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-63099&quot; title=&quot;Constant folding should not assume arithmetic is associative or commutative in the general case&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-63099&quot;&gt;&lt;strike&gt;SERVER-63099&lt;/strike&gt;&lt;/a&gt; if their fieldpaths are at the beginning of the argument list. See JIRA comments on this ticket for examples. &lt;br/&gt;
&lt;br/&gt;
After &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-63099&quot; title=&quot;Constant folding should not assume arithmetic is associative or commutative in the general case&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-63099&quot;&gt;&lt;strike&gt;SERVER-63099&lt;/strike&gt;&lt;/a&gt; is merged, users will be able to speed up their queries back to pre-fix performance by moving any fieldpath references to the end of the list of arguments. For example, $multiply: [1, &amp;quot;$v&amp;quot;, 2, &amp;quot;$w&amp;quot;, 3, 4] can be rewritten to $multiply: [1, 2, 3, 4, &amp;quot;$v&amp;quot;, &amp;quot;$w&amp;quot;] to speed the query up again. &lt;br/&gt;
&lt;br/&gt;
The fact that addition and multiplication with these expressions is now defined to be left-to-right associative should be reflected in the documentation for $add and $multiply.</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>
                            1 year, 28 weeks, 1 day ago
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_16465" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Linked BF Score</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>149.0</customfieldvalue>

                        </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>davis.haupt@mongodb.com</customfieldvalue>
            <customfieldvalue>xgen-internal-githook</customfieldvalue>
            <customfieldvalue>liubov.molchanova@mongodb.com</customfieldvalue>
            <customfieldvalue>timour.katchaounov@mongodb.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|i0igfb:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|i01jrz:</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_22250" key="com.atlassian.jira.plugin.system.customfieldtypes:radiobuttons">
                        <customfieldname>Special Downgrade Instructions Required</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="23343"><![CDATA[Not Needed]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10557" key="com.pyxis.greenhopper.jira:gh-sprint">
                        <customfieldname>Sprint</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue id="5284">QO 2022-02-07</customfieldvalue>
    <customfieldvalue id="5286">QO 2022-02-21</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                        <customfield id="customfield_10750" key="com.atlassian.jira.plugin.system.customfieldtypes:textarea">
                        <customfieldname>Steps To Reproduce</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;db.coll.drop()&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;db.coll.insert({_id: 0, v: NumberDecimal(&quot;917.6875119062092&quot;)})&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;db.coll.insert({_id: 1, v: NumberDecimal(&quot;927.3345924210555&quot;)})&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;const pipeline = [&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{$project: {product: {$multiply: [&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	-3.14159265859,&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	&quot;$v&quot;,&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	-314159255&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;]}}}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;]&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;db.coll.aggregate(pipeline)&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;db.adminCommand({&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	configureFailPoint: &apos;disablePipelineOptimization&apos;,&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	mode: &apos;alwaysOn&apos;,&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;})&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;db.coll.aggregate(pipeline)&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;db.adminCommand({&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	configureFailPoint: &apos;disablePipelineOptimization&apos;,&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	mode: &apos;off&apos;,&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;})&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                            <customfield id="customfield_17051" key="com.atlassian.jira.plugin.system.customfieldtypes:multicheckboxes">
                        <customfieldname>Teams Impacted</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="16943"><![CDATA[Cloud]]></customfieldvalue>
    <customfieldvalue key="16944"><![CDATA[Docs]]></customfieldvalue>
    <customfieldvalue key="16945"><![CDATA[Drivers]]></customfieldvalue>
    <customfieldvalue key="20960"><![CDATA[DBX: DevTools (Compass, Shell, VS Code Ext)]]></customfieldvalue>
    <customfieldvalue key="20958"><![CDATA[Atlas Data Federation and Data Lake]]></customfieldvalue>
    <customfieldvalue key="20959"><![CDATA[Charts]]></customfieldvalue>
    <customfieldvalue key="20961"><![CDATA[SQL Engines (Atlas SQL + BIC)]]></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|i0i2kn:</customfieldvalue>

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