<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 06:09:25 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-67926] Delete non-existing garbage collectable tenant migration data should not cause a ConflictingInProgress error</title>
                <link>https://jira.mongodb.org/browse/SERVER-67926</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;In general, a tenant migration statement data will be marked as garbage collectable after donorForgetMigration. Then, it will be automatically deleted by TTLMonitor once expired or it will be deleted by the next tenant migration request on the same tenant.&lt;/p&gt;

&lt;p&gt;But, there is a corner case that TTLMonitor thread and TenantMigrationRecipientService thread may try to delete the same tenant migration data concurrently. For example,&#160;&lt;br/&gt;
Time 1:&#160;&lt;span class=&quot;error&quot;&gt;&amp;#91;TenantMigrationRecipientService thread&amp;#93;&lt;/span&gt;&#160;check and get the existing mtab of the migration.&lt;br/&gt;
Time 2:&#160;&lt;span class=&quot;error&quot;&gt;&amp;#91;TTLMonitor thread&amp;#93;&lt;/span&gt; delete the mtab due to time expired.&lt;br/&gt;
Time 3:&#160;&lt;span class=&quot;error&quot;&gt;&amp;#91;TenantMigrationRecipientService thread&amp;#93;&lt;/span&gt; delete the mtab. Today, a ConflictingOperationInProgress error is return.&#160; This is not expected. Here is the &lt;a href=&quot;https://github.com/mongodb/mongo/blob/72d9520b6bdf63e66daf71ab62d8f5d1ebc241e9/src/mongo/db/repl/tenant_migration_recipient_service.cpp#L2704-L2712&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;Code to be investigated&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;When checking if there is another ongoing we try to &lt;a href=&quot;https://github.com/10gen/mongo/blob/c937ba75219db4729af97d390b6606c8a50c03ef/src/mongo/db/repl/tenant_migration_recipient_entry_helpers.cpp#L116&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;delete&lt;/a&gt; the existing state document only if it was marked for garbage collection so the new migration can keep on going. However the code logic handles the following situation :&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;If the state document doesn&apos;t have the &quot;expireAt&quot; field, we return false since nDeleted will be 0.&lt;/li&gt;
	&lt;li&gt;If the state document is deleted while we try to delete the state document, nDeleted will return 0 as well. This is wrong, if the state document is being deleted at the same time as we try to delete it, we should process with the migration as it is the same behavior as if we deleted it ourselves.&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;We do not have a way to differentiate the second case from the first one and therefor we throw &quot;ConflictingOperationInProgress&quot;. This ticket is to improve the code to handle that potential race condition.&lt;/p&gt;</description>
                <environment></environment>
        <key id="2086153">SERVER-67926</key>
            <summary>Delete non-existing garbage collectable tenant migration data should not cause a ConflictingInProgress error</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="mathis.bessa@mongodb.com">Mathis Bessa</assignee>
                                    <reporter username="sophia.tan@mongodb.com">Sophia Tan</reporter>
                        <labels>
                    </labels>
                <created>Fri, 8 Jul 2022 22:42:06 +0000</created>
                <updated>Sun, 29 Oct 2023 21:35:47 +0000</updated>
                            <resolved>Thu, 20 Oct 2022 15:34:29 +0000</resolved>
                                                    <fixVersion>6.1.1</fixVersion>
                    <fixVersion>6.2.0-rc0</fixVersion>
                                                        <votes>0</votes>
                                    <watches>4</watches>
                                                                                                                <comments>
                            <comment id="4944355" author="xgen-internal-githook" created="Tue, 1 Nov 2022 14:34:53 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;mathisbessamdb&apos;, &apos;email&apos;: &apos;mathis.bessa@mongodb.com&apos;, &apos;username&apos;: &apos;mathisbessamdb&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-67926&quot; title=&quot;Delete non-existing garbage collectable tenant migration data should not cause a ConflictingInProgress error&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-67926&quot;&gt;&lt;del&gt;SERVER-67926&lt;/del&gt;&lt;/a&gt; Delete non-existing garbage collectable tenant migration data should not cause a ConflictingInProgress error&lt;br/&gt;
Branch: v6.1&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/21c50cca8176fa618aa45878eca007e6fb50b31f&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/21c50cca8176fa618aa45878eca007e6fb50b31f&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="4937495" author="JIRAUSER1259769" created="Sat, 29 Oct 2022 05:02:37 +0000"  >&lt;p&gt;Requesting a backport for v6.1 as the issue reproduced in &lt;a href=&quot;https://buildbaron.corp.mongodb.com/ui/#/bfg/BFG-1569471&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;BFG-1569471&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="4916023" author="xgen-internal-githook" created="Thu, 20 Oct 2022 15:32:26 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;mathisbessamdb&apos;, &apos;email&apos;: &apos;mathis.bessa@mongodb.com&apos;, &apos;username&apos;: &apos;mathisbessamdb&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-67926&quot; title=&quot;Delete non-existing garbage collectable tenant migration data should not cause a ConflictingInProgress error&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-67926&quot;&gt;&lt;del&gt;SERVER-67926&lt;/del&gt;&lt;/a&gt; Delete non-existing garbage collectable tenant migration data should not cause a ConflictingInProgress error&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/8f524446f17abc2c042aa6ef5f81b70ba6513438&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/8f524446f17abc2c042aa6ef5f81b70ba6513438&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">
                                                        </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="2164283">SERVER-70773</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>3.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="24444"><![CDATA[v6.1]]></customfieldvalue>
    <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>Fri, 7 Oct 2022 21:49:44 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        1 year, 14 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, 14 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>6.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>xgen-internal-githook</customfieldvalue>
            <customfieldvalue>liubov.molchanova@mongodb.com</customfieldvalue>
            <customfieldvalue>mathis.bessa@mongodb.com</customfieldvalue>
            <customfieldvalue>sophia.tan@mongodb.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|i11lqv:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|i0kfqg:</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="6597">Server Serverless 2022-10-17</customfieldvalue>
    <customfieldvalue id="6598">Server Serverless 2022-10-31</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|i117w7:</customfieldvalue>

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