<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 05:58:50 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-63851] Use originating command for some expression context flags instead.</title>
                <link>https://jira.mongodb.org/browse/SERVER-63851</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;There are some expression context flags like &lt;a href=&quot;https://github.com/10gen/mongo/blob/7f30babba00b8bea2df2f1d62d3b29f3bf1f14fa/src/mongo/db/pipeline/expression_context.h#L377&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;allowDiskUse, fromMongos, needsMerge, bypassDocumentValidation, and hasWhere&lt;/a&gt; flags that are set based on things that are in the original command. Instead of storing these extra flags we could just have a reference to the original command and code could check that, or we could turn the flags into getters like fromMongos(). We already store the original command in cursors to begin with and even have an &lt;a href=&quot;https://github.com/10gen/mongo/blob/7f30babba00b8bea2df2f1d62d3b29f3bf1f14fa/src/mongo/db/pipeline/expression_context.h#L452&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;originalCommand&lt;/a&gt; field on the expression context. it&apos;s just not set a lot of the time. A downside to this approach is during testing the originalCommand would have to be updated instead of just setting a bool to true.&lt;/p&gt;</description>
                <environment></environment>
        <key id="1986687">SERVER-63851</key>
            <summary>Use originating command for some expression context flags instead.</summary>
                <type id="3" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14718&amp;avatarType=issuetype">Task</type>
                                            <priority id="4" iconUrl="https://jira.mongodb.org/images/icons/priorities/minor.svg">Minor - P4</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="alberto.massari@mongodb.com">Alberto Massari</assignee>
                                    <reporter username="mickey.winters@mongodb.com">Mickey Winters</reporter>
                        <labels>
                            <label>quick-tech-debt</label>
                    </labels>
                <created>Fri, 18 Feb 2022 21:23:50 +0000</created>
                <updated>Sun, 29 Oct 2023 21:42:11 +0000</updated>
                            <resolved>Tue, 13 Sep 2022 10:08:28 +0000</resolved>
                                                    <fixVersion>6.2.0-rc0</fixVersion>
                                                        <votes>1</votes>
                                    <watches>6</watches>
                                                                                                                <comments>
                            <comment id="4821576" author="xgen-internal-githook" created="Tue, 13 Sep 2022 09:36:11 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Alberto Massari&apos;, &apos;email&apos;: &apos;alberto.massari@mongodb.com&apos;, &apos;username&apos;: &apos;albymassari&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-63851&quot; title=&quot;Use originating command for some expression context flags instead.&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-63851&quot;&gt;&lt;del&gt;SERVER-63851&lt;/del&gt;&lt;/a&gt; Derive ExecutionContext flags from OperationContext&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/c70bc17083cc73c2b2d32b4fc693fe22c58a863d&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/c70bc17083cc73c2b2d32b4fc693fe22c58a863d&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="4811576" author="mickey.winters" created="Thu, 8 Sep 2022 13:49:02 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=alberto.massari%40mongodb.com&quot; class=&quot;user-hover&quot; rel=&quot;alberto.massari@mongodb.com&quot;&gt;alberto.massari@mongodb.com&lt;/a&gt; that sounds like it could work. I&apos;m not sure if there are any flags that change dynamically during query execution, so this may not work for all flags. Any flags that are essential determined by the originating command definitely could be set in the constructor. Especially ones like fromMongos which is set if the originating command has the flag fromMongos: true&lt;/p&gt;</comment>
                            <comment id="4811098" author="JIRAUSER1269757" created="Thu, 8 Sep 2022 10:48:01 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=mickey.winters%40mongodb.com&quot; class=&quot;user-hover&quot; rel=&quot;mickey.winters@mongodb.com&quot;&gt;mickey.winters@mongodb.com&lt;/a&gt; is there a set of flags whose value can change dynamically? Because we could change the three constructors to use the provided opCtx to fill the local flag using the source command, and leave to the caller the responsibility of manually setting the ones that cannot be inferred from opCtx&lt;/p&gt;</comment>
                            <comment id="4396240" author="mickey.winters" created="Mon, 7 Mar 2022 20:18:27 +0000"  >&lt;p&gt;Having flags like this can be bug prone, as shown in &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-61769&quot; class=&quot;external-link&quot; rel=&quot;nofollow&quot;&gt;https://jira.mongodb.org/browse/SERVER-61769&lt;/a&gt; a engineer could easily forget to appropriately set a flag leading to an error. in the ticket I linked instead of setting a flag in the expCtx it checks the source (the opCtx instead of the originating command in this case).&lt;br/&gt;
The other argument for this is there may be one off cases where we need to know something about the originating request but only have access to the expCtx. &lt;a href=&quot;https://github.com/mongodb/mongo/commit/586663fec7c3a7d4a8b0185ff24825bd15e80dff#diff-0a3241aeb8d7e35009c452bba1f2eb26906d66a8096baed2939e055b9978a73dR453&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;here&lt;/a&gt; I had to look at the originating command and set the flag just to have that information to be used in 1 other place: &lt;a href=&quot;https://github.com/mongodb/mongo/commit/586663fec7c3a7d4a8b0185ff24825bd15e80dff#diff-05922e9e4080ad3f7985503de5558d95adf076a474058b178d3067c4b9741df4R82&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;here&lt;/a&gt;. if the expression context had a reference to the originating command we wouldn&apos;t have to add new flags for one off cases like this.&lt;/p&gt;</comment>
                            <comment id="4384087" author="kyle.suarez" created="Tue, 1 Mar 2022 17:47:57 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=mickey.winters&quot; class=&quot;user-hover&quot; rel=&quot;mickey.winters&quot;&gt;mickey.winters&lt;/a&gt;, we discussed this at the triage meeting, but it wasn&apos;t immediately obvious that we should schedule this. Can you give us the quick &quot;elevator pitch&quot; for this refactor?&lt;/p&gt;

&lt;p&gt;Also, &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=david.storch&quot; class=&quot;user-hover&quot; rel=&quot;david.storch&quot;&gt;david.storch&lt;/a&gt; raised a concern that this ticket should be careful to not e.g. parse the originating command twice.&lt;/p&gt;</comment>
                    </comments>
                    <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>5.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>Tue, 1 Mar 2022 17:47:57 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        1 year, 21 weeks, 1 day 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_17050" key="com.atlassian.jira.plugin.system.customfieldtypes:radiobuttons">
                        <customfieldname>Downstream Team Attention</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="16941"><![CDATA[Not 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, 21 weeks, 1 day ago
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                    <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>alberto.massari@mongodb.com</customfieldvalue>
            <customfieldvalue>xgen-internal-githook</customfieldvalue>
            <customfieldvalue>kyle.suarez@mongodb.com</customfieldvalue>
            <customfieldvalue>mickey.winters@mongodb.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|i0kqtr:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|i03t5r:</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="5894">QE 2022-05-30</customfieldvalue>
    <customfieldvalue id="5896">QE 2022-06-13</customfieldvalue>
    <customfieldvalue id="5898">QE 2022-06-27</customfieldvalue>
    <customfieldvalue id="5900">QE 2022-07-11</customfieldvalue>
    <customfieldvalue id="5910">QE 2022-09-19</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|i0kcz3:</customfieldvalue>

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