<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 05:05:27 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-44252] Delete implicit collection creation loop through the config server in sharding</title>
                <link>https://jira.mongodb.org/browse/SERVER-44252</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;PM-1168 will allow implicitly creating collections inside transactions, which would fail in sharding today because of &lt;a href=&quot;https://github.com/mongodb/mongo/blob/4003ef1b40e4404fc42d8a13db7e3a12946e0832/src/mongo/db/catalog/database_impl.cpp#L589-L593&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;this uassert&lt;/a&gt; in DatabaseImpl::createCollection. (Hitting the uassert would abort the transaction on the shard.)&lt;/p&gt;

&lt;p&gt;Since the implicit collection creation loop through the config server is not currently used for adding new collections immediately into the sharding catalog, we will just delete this loop and revisit implicit collection creation as part of other catalog work in the future.&lt;/p&gt;
&lt;h3&gt;&lt;a name=&quot;Background&quot;&gt;&lt;/a&gt;Background&lt;/h3&gt;

&lt;p&gt;In sharding, shards never implicitly create collections on themselves. Instead, if they receive a request that would implicitly create a collection, they throw &lt;a href=&quot;https://github.com/mongodb/mongo/blob/4003ef1b40e4404fc42d8a13db7e3a12946e0832/src/mongo/db/catalog/database_impl.cpp#L589-L593&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;here&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The exception &lt;a href=&quot;https://github.com/mongodb/mongo/blob/4003ef1b40e4404fc42d8a13db7e3a12946e0832/src/mongo/db/service_entry_point_common.cpp#L1011&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;is caught&lt;/a&gt; &lt;a href=&quot;https://github.com/mongodb/mongo/blob/4003ef1b40e4404fc42d8a13db7e3a12946e0832/src/mongo/db/service_entry_point_mongod.cpp#L197-L202&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;in the&lt;/a&gt; service entry point on the shard, and a &lt;a href=&quot;https://github.com/mongodb/mongo/blob/4003ef1b40e4404fc42d8a13db7e3a12946e0832/src/mongo/db/s/implicit_create_collection.cpp#L108-L117&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;handler&lt;/a&gt; that sends _configsvrCreateCollection to the config server is invoked.&lt;/p&gt;

&lt;p&gt;The _configsvrCreateCollection command &lt;a href=&quot;https://github.com/mongodb/mongo/blob/4003ef1b40e4404fc42d8a13db7e3a12946e0832/src/mongo/db/s/config/configsvr_create_collection_command.cpp#L95&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;then&lt;/a&gt; &lt;a href=&quot;https://github.com/mongodb/mongo/blob/4003ef1b40e4404fc42d8a13db7e3a12946e0832/src/mongo/db/s/config/sharding_catalog_manager_collection_operations.cpp#L648-L667&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;creates&lt;/a&gt; the collection on the primary shard.&lt;/p&gt;</description>
                <environment></environment>
        <key id="979447">SERVER-44252</key>
            <summary>Delete implicit collection creation loop through the config server in sharding</summary>
                <type id="3" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14718&amp;avatarType=issuetype">Task</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="mihai.andrei@mongodb.com">Mihai Andrei</assignee>
                                    <reporter username="esha.maharishi@mongodb.com">Esha Maharishi</reporter>
                        <labels>
                    </labels>
                <created>Fri, 25 Oct 2019 19:24:09 +0000</created>
                <updated>Sun, 29 Oct 2023 22:15:42 +0000</updated>
                            <resolved>Thu, 9 Jan 2020 18:28:10 +0000</resolved>
                                                    <fixVersion>4.3.3</fixVersion>
                                    <component>Sharding</component>
                                        <votes>0</votes>
                                    <watches>4</watches>
                                                                                                                <comments>
                            <comment id="2714749" author="xgen-internal-githook" created="Thu, 9 Jan 2020 18:08:51 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Mihai Andrei&apos;, &apos;email&apos;: &apos;mihai.andrei@mongodb.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-44252&quot; title=&quot;Delete implicit collection creation loop through the config server in sharding&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-44252&quot;&gt;&lt;del&gt;SERVER-44252&lt;/del&gt;&lt;/a&gt; Delete implicit collection creation loop through the config server in sharding&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/944e382e9b1cc6b873efaaa5aaf4c01a992f130f&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/944e382e9b1cc6b873efaaa5aaf4c01a992f130f&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="2597869" author="esha.maharishi@10gen.com" created="Tue, 10 Dec 2019 22:51:43 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=jack.mulrow&quot; class=&quot;user-hover&quot; rel=&quot;jack.mulrow&quot;&gt;jack.mulrow&lt;/a&gt;, Ok, I&apos;m tempted to not try to work around &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-32198&quot; title=&quot;Missing collection metadata on the shard implies both UNSHARDED and &amp;quot;metadata not loaded yet&amp;quot;&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-32198&quot;&gt;&lt;del&gt;SERVER-32198&lt;/del&gt;&lt;/a&gt; and just pretend it doesn&apos;t exist - the Barcelona team is planning to fix &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-32198&quot; title=&quot;Missing collection metadata on the shard implies both UNSHARDED and &amp;quot;metadata not loaded yet&amp;quot;&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-32198&quot;&gt;&lt;del&gt;SERVER-32198&lt;/del&gt;&lt;/a&gt; for 4.4 anyway.&lt;/p&gt;

&lt;p&gt;I think the result will be that the stale mongos that attached shardVersion UNSHARDED and a database version will either have targeted the correct primary shard or will get a StaleDbVersion error and retry against the correct primary shard.&lt;/p&gt;</comment>
                            <comment id="2597644" author="jack.mulrow" created="Tue, 10 Dec 2019 21:30:46 +0000"  >&lt;p&gt;Yeah it still checks databaseVersion&#160;&lt;a href=&quot;https://github.com/mongodb/mongo/blob/f515d2ad54/src/mongo/db/commands/create_indexes.cpp#L790-L791&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;here&lt;/a&gt;.&lt;/p&gt;</comment>
                            <comment id="2594793" author="esha.maharishi@10gen.com" created="Mon, 9 Dec 2019 20:58:11 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=jack.mulrow&quot; class=&quot;user-hover&quot; rel=&quot;jack.mulrow&quot;&gt;jack.mulrow&lt;/a&gt;, will createIndexes still check databaseVersion in that case? (It should currently, see the &lt;a href=&quot;https://github.com/mongodb/mongo/blob/64a9f0dcc098a8d6e0c3a381d56acee9909c3e58/jstests/sharding/database_versioning_all_commands.js#L340&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;test case for createIndexes&lt;/a&gt; in database_versioning_all_commands.js.)&lt;/p&gt;</comment>
                            <comment id="2593837" author="jack.mulrow" created="Mon, 9 Dec 2019 15:44:52 +0000"  >&lt;p&gt;Note that as of&#160;&lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-44405&quot; title=&quot;Use MODE_IX lock for implicit collection creation with createIndexes&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-44405&quot;&gt;&lt;del&gt;SERVER-44405&lt;/del&gt;&lt;/a&gt;, createIndexes will not check shard version when creating an index implicitly creates a collection. If we start allowing createIndexes to implicitly create an unsharded collection, we&apos;ll have to be careful to ensure that this can&apos;t lead to inconsistent indexes across shards if a stale router targets a stale shard (e.g. through the problem from &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-32198&quot; title=&quot;Missing collection metadata on the shard implies both UNSHARDED and &amp;quot;metadata not loaded yet&amp;quot;&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-32198&quot;&gt;&lt;del&gt;SERVER-32198&lt;/del&gt;&lt;/a&gt;).&lt;/p&gt;</comment>
                            <comment id="2525764" author="charlie.swanson" created="Fri, 8 Nov 2019 19:09:14 +0000"  >&lt;p&gt;As mentioned in &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-43851&quot; title=&quot;Work around zombie writes in $merge tests&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-43851&quot;&gt;&lt;del&gt;SERVER-43851&lt;/del&gt;&lt;/a&gt;, the query team would like to use the &apos;allowImplcitCollectionCreation&apos; flag and uassert once it&apos;s no longer being used as a kick-back to the config server. When doing this work, please hold off on deleting those parts. &lt;/p&gt;</comment>
                            <comment id="2505107" author="esha.maharishi@10gen.com" created="Mon, 28 Oct 2019 16:31:36 +0000"  >&lt;p&gt;Marked as related to PM-1361, since if we remove the CannotImplicitlyCreateCollection uassert, the current implementation of createIndexes on mongos (to broadcast to all shards) would cause the collection to get implicitly created on shards that do not own chunks for the collection, probably with the wrong UUID.&lt;/p&gt;

&lt;p&gt;CC &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=jack.mulrow&quot; class=&quot;user-hover&quot; rel=&quot;jack.mulrow&quot;&gt;jack.mulrow&lt;/a&gt;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                                                <inwardlinks description="is depended on by">
                                        <issuelink>
            <issuekey id="918697">SERVER-43198</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="960278">SERVER-43851</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                                        </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <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>6.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, 8 Nov 2019 19:09:14 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        4 years, 4 weeks, 6 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_10857" key="com.pyxis.greenhopper.jira:gh-epic-link">
                        <customfieldname>Epic Link</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>PM-1361</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>
                            4 years, 4 weeks, 6 days ago
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                    <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>charlie.swanson@mongodb.com</customfieldvalue>
            <customfieldvalue>esha.maharishi@mongodb.com</customfieldvalue>
            <customfieldvalue>xgen-internal-githook</customfieldvalue>
            <customfieldvalue>jack.mulrow@mongodb.com</customfieldvalue>
            <customfieldvalue>mihai.andrei@mongodb.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hvyzdb:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hvndwf:</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="3307">Sharding 2019-11-04</customfieldvalue>
    <customfieldvalue id="3308">Sharding 2019-11-18</customfieldvalue>
    <customfieldvalue id="3472">Sharding 2019-12-02</customfieldvalue>
    <customfieldvalue id="3473">Sharding 2019-12-16</customfieldvalue>
    <customfieldvalue id="3474">Sharding 2019-12-30</customfieldvalue>
    <customfieldvalue id="3475">Sharding 2020-01-13</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|hvylmn:</customfieldvalue>

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