<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 04:29:14 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-32116] Retryable writes not safely retryable across collection drops in sharded clusters</title>
                <link>https://jira.mongodb.org/browse/SERVER-32116</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;Scenario:&lt;br/&gt;
0. shardB is the primary shard of &quot;test&quot; database.&lt;br/&gt;
1. test.foo is a sharded collection and has chunks in shardA [-inf, 0) &amp;amp; shardB [0, inf).&lt;br/&gt;
2. User sends batch insert [{-1}, {1}] to mongos, the insert will split up to shardA {-1} &amp;amp; shardB {1}.&lt;br/&gt;
3. test.foo gets dropped.&lt;br/&gt;
4. If user tries to send the same retryable write in step #2 to mongos, mongos will target the full batch [{-1}, {1}] to shardB. And this will result in the shardB applying the write {-1} and not {1}.&lt;/p&gt;</description>
                <environment></environment>
        <key id="465489">SERVER-32116</key>
            <summary>Retryable writes not safely retryable across collection drops in sharded clusters</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="2">Won&apos;t Fix</resolution>
                                        <assignee username="backlog-server-sharding">[DO NOT USE] Backlog - Sharding Team</assignee>
                                    <reporter username="randolph@mongodb.com">Randolph Tan</reporter>
                        <labels>
                            <label>RF36</label>
                    </labels>
                <created>Wed, 29 Nov 2017 19:24:48 +0000</created>
                <updated>Tue, 6 Dec 2022 03:45:43 +0000</updated>
                            <resolved>Tue, 19 Dec 2017 16:56:48 +0000</resolved>
                                    <version>3.6.0-rc7</version>
                                                    <component>Sharding</component>
                                        <votes>0</votes>
                                    <watches>8</watches>
                                                                                                                <comments>
                            <comment id="1755808" author="renctan" created="Tue, 19 Dec 2017 16:56:22 +0000"  >&lt;p&gt;After thinking a bit more, making unsharded collection versioned is not sufficient, retryable write requests will also need to send the UUID of the collection and the retry logic should check that it matches with the write history. Closing this as won&apos;t fix.&lt;/p&gt;</comment>
                            <comment id="1754525" author="renctan" created="Mon, 18 Dec 2017 16:10:55 +0000"  >&lt;p&gt;This issue should go away once we start versioning unsharded collections as the retry will now throw a version error.&lt;/p&gt;</comment>
                            <comment id="1746983" author="schwerin" created="Fri, 8 Dec 2017 16:50:44 +0000"  >&lt;p&gt;There&apos;s no retry support required across fcv downgrade and re-upgrade.&lt;/p&gt;</comment>
                            <comment id="1742968" author="renctan" created="Tue, 5 Dec 2017 15:55:01 +0000"  >&lt;blockquote&gt;
&lt;p&gt;Retryable writes require sessions, which are only available in FCV 3.6, so downgrade should not be a problem.&lt;/p&gt;&lt;/blockquote&gt;

&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=kaloian.manassiev&quot; class=&quot;user-hover&quot; rel=&quot;kaloian.manassiev&quot;&gt;kaloian.manassiev&lt;/a&gt; What I meant to say is that when user downgrades to v3.4, all UUID information is stripped, and if the user decides to upgrade back to fcv v3.6, the collections will be assigned a new UUID. In other words, the same collection can be assigned different UUID across it&apos;s lifetime if downgrade -&amp;gt; upgrade happens in it&apos;s lifetime. So, the plan to use UUID stored in oplog to detect if collection is the same as the current won&apos;t work in all cases.&lt;/p&gt;</comment>
                            <comment id="1739498" author="kaloian.manassiev" created="Fri, 1 Dec 2017 15:40:19 +0000"  >&lt;p&gt;Retryable writes require sessions, which are only available in FCV 3.6, so downgrade should not be a problem.&lt;/p&gt;

&lt;p&gt;Also for the optimization in &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-31328&quot; title=&quot;Don&amp;#39;t fetch oplog entries for retries of executed inserts or deletes&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-31328&quot;&gt;&lt;del&gt;SERVER-31328&lt;/del&gt;&lt;/a&gt;, we could start storing the UUID in the &lt;a href=&quot;https://github.com/mongodb/mongo/blob/26279e86956158edf69e8ed4e82cc211bf90ede4/src/mongo/db/session.h#L219&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;committed statements map&lt;/a&gt;. The UUID for all statements in a txn must be the same so that can even be consolidated if memory is concern, but I don&apos;t think adding UUID would be a problem.&lt;/p&gt;</comment>
                            <comment id="1737857" author="renctan" created="Wed, 29 Nov 2017 21:20:48 +0000"  >&lt;p&gt;Hm... realized that the fix above is not perfect for v3.6 as collections can lose their UUID information when a shard downgrades their featureCompatibilityVersion from v3.6 to v3.4.&lt;/p&gt;</comment>
                            <comment id="1737721" author="renctan" created="Wed, 29 Nov 2017 19:38:45 +0000"  >&lt;p&gt;One way to handle this is to have mongos include the UUID of the collection in the write request and the shard should return an error if it detects UUID mismatch in the write history (this also means that the we have to undo the optimization by &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-31328&quot; title=&quot;Don&amp;#39;t fetch oplog entries for retries of executed inserts or deletes&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-31328&quot;&gt;&lt;del&gt;SERVER-31328&lt;/del&gt;&lt;/a&gt;).&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>7.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="25141"><![CDATA[Sharding]]></customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Fri, 1 Dec 2017 15:40:19 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        6 years, 8 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_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>alexander.golin@mongodb.com</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_11151" key="com.atlassian.jira.toolkit:LastCommentDate">
                        <customfieldname>Last public comment date</customfieldname>
                        <customfieldvalues>
                            6 years, 8 weeks, 1 day 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>backlog-server-sharding</customfieldvalue>
            <customfieldvalue>schwerin@mongodb.com</customfieldvalue>
            <customfieldvalue>kaloian.manassiev@mongodb.com</customfieldvalue>
            <customfieldvalue>randolph@mongodb.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|htl4vb:</customfieldvalue>

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

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

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_10557" key="com.pyxis.greenhopper.jira:gh-sprint">
                        <customfieldname>Sprint</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue id="2051">Sharding 2018-01-01</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|htkqz3:</customfieldvalue>

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