<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 06:23:03 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-72879] Recreation of same database with different cases could lead to database unavailability</title>
                <link>https://jira.mongodb.org/browse/SERVER-72879</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;If two databases with same name but different cases (e.g.: DB1, db1) are dropped and created concurrently some shards could end up with inconsistent in-memory metadata causing database unavailability until the affected node is restarted.&lt;/p&gt;</description>
                <environment></environment>
        <key id="2234219">SERVER-72879</key>
            <summary>Recreation of same database with different cases could lead to database unavailability</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="13203">Gone away</resolution>
                                        <assignee username="backlog-server-sharding-emea">[DO NOT USE] Backlog - Sharding EMEA</assignee>
                                    <reporter username="tommaso.tocci@mongodb.com">Tommaso Tocci</reporter>
                        <labels>
                    </labels>
                <created>Mon, 16 Jan 2023 19:15:57 +0000</created>
                <updated>Fri, 27 Oct 2023 20:45:00 +0000</updated>
                            <resolved>Wed, 25 Jan 2023 18:24:37 +0000</resolved>
                                                                                        <votes>0</votes>
                                    <watches>2</watches>
                                                                                                                <comments>
                            <comment id="5140518" author="tommaso.tocci" created="Wed, 25 Jan 2023 18:24:37 +0000"  >&lt;p&gt;Fixed by &#160; &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-72869&quot; title=&quot;Push the database metadata from the Storage Catalog back to the Database Sharding State&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-72869&quot;&gt;&lt;del&gt;SERVER-72869&lt;/del&gt;&lt;/a&gt;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                            <outwardlinks description="depends on">
                                        <issuelink>
            <issuekey id="2234055">SERVER-72869</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is depended on by">
                                        <issuelink>
            <issuekey id="2186250">SERVER-71368</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10520">
                    <name>Problem/Incident</name>
                                                                <inwardlinks description="is caused by">
                                        <issuelink>
            <issuekey id="1994653">SERVER-64209</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>1.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                <customfield id="customfield_12751" key="com.atlassian.jira.plugin.system.customfieldtypes:multiselect">
                        <customfieldname>Assigned Teams</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="25133"><![CDATA[Sharding EMEA]]></customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        1 year, 2 weeks 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/SERVER-72869'>SERVER-72869</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_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, 2 weeks 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-emea</customfieldvalue>
            <customfieldvalue>tommaso.tocci@mongodb.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|i1qsnr:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|i19bg0:</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_10750" key="com.atlassian.jira.plugin.system.customfieldtypes:textarea">
                        <customfieldname>Steps To Reproduce</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>&lt;ol&gt;
	&lt;li&gt;Create a database with lower case &quot;mydb&quot;&lt;/li&gt;
	&lt;li&gt;Start a dropDatabase(&quot;mydb&quot;)&lt;/li&gt;
	&lt;li&gt;The primary shard &lt;a href=&quot;https://github.com/mongodb/mongo/blob/3335554ec9d348fcd1e0f20c44e7313a855e6f20/src/mongo/db/s/drop_database_coordinator.cpp#L356-L374&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;will forward the dropDatabaseParticipantCmd to all shards&lt;/a&gt;.&lt;/li&gt;
	&lt;li&gt;Each participant shard will drop the database locally.&lt;/li&gt;
	&lt;li&gt;Before the drop database coordinator have removed the database entry from the config server, one of the participant shard manage to refresh the database, thus it will &lt;a href=&quot;https://github.com/mongodb/mongo/blob/3335554ec9d348fcd1e0f20c44e7313a855e6f20/src/mongo/db/s/shard_filtering_metadata_refresh.cpp#L160-L161&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;re-create the database entry for &quot;mydb&quot; in the local catalog&lt;/a&gt;.&lt;/li&gt;
	&lt;li&gt;The drop&#160; database coordinator &lt;a href=&quot;https://github.com/mongodb/mongo/blob/3335554ec9d348fcd1e0f20c44e7313a855e6f20/src/mongo/db/s/drop_database_coordinator.cpp#L381&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;deletes &quot;mydb&quot; entry from the config server and will call&lt;/a&gt;&lt;/li&gt;
	&lt;li&gt;The drop database coordinator &lt;a href=&quot;https://github.com/mongodb/mongo/blob/3335554ec9d348fcd1e0f20c44e7313a855e6f20/src/mongo/db/s/drop_database_coordinator.cpp#L389-L408&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;forwards the flushDatabaseCacheUpdates command to all the participants&lt;/a&gt; .&lt;/li&gt;
	&lt;li&gt;The participant call &lt;a href=&quot;https://github.com/mongodb/mongo/blob/3335554ec9d348fcd1e0f20c44e7313a855e6f20/src/mongo/db/s/shard_filtering_metadata_refresh.cpp#L164&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;DatabaseHolder::clearDbInfo(&quot;mydb&quot;)&lt;/a&gt;, that will &lt;a href=&quot;https://github.com/mongodb/mongo/blob/26340534c332cb534292369d35c7fb5d1910cfad/src/mongo/db/catalog/database_holder_impl.cpp#L326-L327&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;clear the sharding metadata associated to the database&lt;/a&gt; but will leave the database registered in the sharding catalog.&lt;/li&gt;
	&lt;li&gt;A new database &quot;MYDB&quot; is created on the config sever.&lt;/li&gt;
	&lt;li&gt;Next time the participant shard will perform a refresh for this new database &quot;MYDB&quot;, it will &lt;a href=&quot;https://github.com/mongodb/mongo/blob/3335554ec9d348fcd1e0f20c44e7313a855e6f20/src/mongo/db/s/shard_filtering_metadata_refresh.cpp#L160&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;try to create a new entry in the local catalog&lt;/a&gt; and &lt;a href=&quot;https://github.com/mongodb/mongo/blob/26340534c332cb534292369d35c7fb5d1910cfad/src/mongo/db/catalog/database_holder_impl.cpp#L133-L139&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;it will fail with DatabaseDifferCase error&lt;/a&gt; because in the local catalog there is still registered the database &quot;mydb&quot; created at step 5&lt;/li&gt;
&lt;/ol&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|i1qet3:</customfieldvalue>

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