<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 06:41:11 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-79520] QE fails with sharded upsert on non-shard key</title>
                <link>https://jira.mongodb.org/browse/SERVER-79520</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;QE sharded upsert on a non-shard key goes though a different code path. As part of this code path, it does not set `encryptionInformation.setCrudProcessed` and so the upsert gets blocked.&lt;/p&gt;</description>
                <environment></environment>
        <key id="2405475">SERVER-79520</key>
            <summary>QE fails with sharded upsert on non-shard key</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="erwin.pe@mongodb.com">Erwin Pe</assignee>
                                    <reporter username="mark.benvenuto@mongodb.com">Mark Benvenuto</reporter>
                        <labels>
                    </labels>
                <created>Mon, 31 Jul 2023 19:19:12 +0000</created>
                <updated>Sun, 29 Oct 2023 21:18:12 +0000</updated>
                            <resolved>Fri, 18 Aug 2023 21:54:02 +0000</resolved>
                                                    <fixVersion>7.1.0-rc0</fixVersion>
                                    <component>Queryable Encryption</component>
                                        <votes>0</votes>
                                    <watches>3</watches>
                                                                                                                <comments>
                            <comment id="5644336" author="xgen-internal-githook" created="Fri, 18 Aug 2023 20:57:47 +0000"  >&lt;p&gt;Author: &lt;/p&gt;
{&apos;name&apos;: &apos;Erwin Pe&apos;, &apos;email&apos;: &apos;erwin.pe@mongodb.com&apos;, &apos;username&apos;: &apos;erwee&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-79520&quot; title=&quot;QE fails with sharded upsert on non-shard key&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-79520&quot;&gt;&lt;del&gt;SERVER-79520&lt;/del&gt;&lt;/a&gt; Fix QE sharded upsert on non-shard key&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/14b93cc215af024871f2b530a313706574a684b8&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/14b93cc215af024871f2b530a313706574a684b8&lt;/a&gt;&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">
                                        <issuelink>
            <issuekey id="2413627">SERVER-79889</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10010">
                    <name>Duplicate</name>
                                            <outwardlinks description="duplicates">
                                        <issuelink>
            <issuekey id="2413627">SERVER-79889</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                <customfield id="customfield_10050" key="com.atlassian.jira.toolkit:comments">
                        <customfieldname># Replies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_18555" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname># of Sprints</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1.0</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                    <customfield id="customfield_12751" key="com.atlassian.jira.plugin.system.customfieldtypes:multiselect">
                        <customfieldname>Assigned Teams</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="25129"><![CDATA[Server Security]]></customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12450" key="com.atlassian.jira.plugin.system.customfieldtypes:multicheckboxes">
                        <customfieldname>Backport Requested</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="25578"><![CDATA[v7.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>Fri, 18 Aug 2023 00:13:45 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        24 weeks, 5 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_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>
                            24 weeks, 5 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>erwin.pe@mongodb.com</customfieldvalue>
            <customfieldvalue>xgen-internal-githook</customfieldvalue>
            <customfieldvalue>mark.benvenuto@mongodb.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|i2k92v:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|i22cko:</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_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="7404">Security 2023-08-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;import {EncryptedClient} from &quot;jstests/fle2/libs/encrypted_client_util.js&quot;;&lt;/p&gt;

&lt;p&gt;function runTest(conn) {&lt;/p&gt;

&lt;p&gt;&#160; &#160; let dbName = &apos;basic_update&apos;;&lt;/p&gt;

&lt;p&gt;&#160; &#160; let client = new EncryptedClient(conn, dbName);&lt;br/&gt;
&#160; &#160; let edb = client.getDB();&lt;/p&gt;

&lt;p&gt;&#160; &#160; assert.commandWorked(client.createEncryptionCollection(&quot;basic&quot;, {&lt;br/&gt;
&#160; &#160; &#160; &#160; encryptedFields:&lt;br/&gt;
&#160; &#160; &#160; &#160; &#160; &#160; {&quot;fields&quot;: &lt;span class=&quot;error&quot;&gt;&amp;#91;{&amp;quot;path&amp;quot;: &amp;quot;first&amp;quot;, &amp;quot;bsonType&amp;quot;: &amp;quot;string&amp;quot;, &amp;quot;queries&amp;quot;: {&amp;quot;queryType&amp;quot;: &amp;quot;equality&amp;quot;}}&amp;#93;&lt;/span&gt;}&lt;br/&gt;
&#160; &#160; }));&lt;/p&gt;


&lt;p&gt;&#160; &#160; let resShard = edb.adminCommand({enableSharding: edb.getName()});&lt;/p&gt;

&lt;p&gt;&#160; &#160; // enableSharding may only be called once for a database.&lt;br/&gt;
&#160; &#160; if (resShard.code !== ErrorCodes.AlreadyInitialized) &lt;/p&gt;
{
&#160; &#160; &#160; &#160; assert.commandWorked(
&#160; &#160; &#160; &#160; &#160; &#160; resShard, &quot;enabling sharding on the &apos;&quot; + edb.getName() + &quot;&apos; db failed&quot;);
&#160; &#160; }

&lt;p&gt;&#160; &#160; let shardCollCmd = &lt;/p&gt;
{
&#160; &#160; &#160; &#160; shardCollection: edb.getName() + &quot;.basic&quot;,
&#160; &#160; &#160; &#160; key: \{_id: &quot;hashed&quot;}
&lt;p&gt;,&lt;br/&gt;
&#160; &#160; &#160; &#160; collation: {locale: &quot;simple&quot;}&lt;br/&gt;
&#160; &#160; };&lt;/p&gt;

&lt;p&gt;&#160; &#160; resShard = edb.adminCommand(shardCollCmd);&lt;/p&gt;

&lt;p&gt;&#160; &#160; jsTestLog(&quot;Sharding: &quot; + tojson(shardCollCmd));&lt;/p&gt;


&lt;p&gt;&#160; &#160; assert.commandWorked(edb.basic.insert({&quot;_id&quot;: 1, &quot;first&quot;: &quot;mark&quot;, &quot;last&quot;: &quot;marco&quot;}));&lt;br/&gt;
&#160; &#160; assert.commandWorked(edb.basic.insert({&quot;_id&quot;: 2, &quot;first&quot;: &quot;Mark&quot;, &quot;last&quot;: &quot;Marcus&quot;}));&lt;/p&gt;

&lt;p&gt;&#160; &#160; // Add a document via upsert&lt;br/&gt;
&#160; &#160; res = assert.commandWorked(edb.basic.runCommand({&lt;br/&gt;
&#160; &#160; &#160; &#160; update: edb.basic.getName(),&lt;br/&gt;
&#160; &#160; &#160; &#160; updates: [{q: &lt;/p&gt;
{&quot;last&quot;: &quot;Marco&quot;}
&lt;p&gt;, u: {&quot;last&quot;: &quot;Marco&quot;, &quot;first&quot;: &quot;Luke&quot;}, upsert: true}]&lt;br/&gt;
&#160; &#160; }));&lt;br/&gt;
}&lt;/p&gt;

&lt;p&gt;jsTestLog(&quot;Sharding: Testing fle2 contention on update&quot;);&lt;/p&gt;
{
&#160; &#160; const st = new ShardingTest(\{shards: 2, mongos: 1, config: 1}
&lt;p&gt;);&lt;/p&gt;

&lt;p&gt;&#160; &#160; runTest(st.s, st.shard0);&lt;/p&gt;

&lt;p&gt;&#160; &#160; st.stop();&lt;br/&gt;
}&lt;/p&gt;</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|i2jv87:</customfieldvalue>

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