<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 05:21:49 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-50132] Implement topology discovery in shell</title>
                <link>https://jira.mongodb.org/browse/SERVER-50132</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;Drivers provide two ways to discover the topology of a deployment and connect to it appropriately:&lt;/p&gt;

&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;By specifying multiple hosts:&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;mongo mongodb://localhost:14420,localhost:14421                                          &lt;/p&gt;

&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;By specifying directConnection=false URI option (recently standardized in &lt;a href=&quot;https://github.com/mongodb/specifications/commit/e56f5eceed7729f8b9b43a4a1f76c7e5840db49f&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/specifications/commit/e56f5eceed7729f8b9b43a4a1f76c7e5840db49f&lt;/a&gt;).&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;It seems to me that mongo shell does not implement either of these behaviors.&lt;/p&gt;

&lt;p&gt;Specifically, there appears to be no way to connect to replica set using mongo shell without providing the replica set name.&lt;/p&gt;

&lt;p&gt;The decision across drivers was to implement topology discovery by default. New drivers must implement it, existing drivers can continue with their existing behavior for BC reasons.&lt;/p&gt;

&lt;p&gt;To improve usability of the shell and make it consistent with drivers, I suggest implementing one or both of the above mentioned ways of discovering and connecting to replica set without specifying replica set name explicitly.&lt;/p&gt;</description>
                <environment></environment>
        <key id="1431306">SERVER-50132</key>
            <summary>Implement topology discovery in shell</summary>
                <type id="4" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14710&amp;avatarType=issuetype">Improvement</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-stm">Backlog - Server Tooling and Methods (STM)</assignee>
                                    <reporter username="oleg.pudeyev@mongodb.com">Oleg Pudeyev</reporter>
                        <labels>
                    </labels>
                <created>Wed, 5 Aug 2020 21:26:15 +0000</created>
                <updated>Tue, 6 Dec 2022 02:13:08 +0000</updated>
                            <resolved>Tue, 6 Oct 2020 14:32:58 +0000</resolved>
                                                                    <component>Shell</component>
                                        <votes>0</votes>
                                    <watches>9</watches>
                                                                                                                <comments>
                            <comment id="3428246" author="robert.guo" created="Tue, 6 Oct 2020 14:32:48 +0000"  >&lt;p&gt;Hi Oleg, Thank you for the insight. I understand the frustration that the shell does not behave like drivers in certain respects like topology discovery and does not provide the best experience for mongo shell users. The new shell (mongosh) is in fast active development and I would encourage you to reach out to see if topology discovery is something they could prioritize, or better yet, something they&apos;ve already done. The old shell is going to be deprecated in the near future and to be used exclusively for Server development; we expect it will continue to have behavior that deviates from other drivers.&lt;/p&gt;</comment>
                            <comment id="3405663" author="oleg.pudeyev" created="Tue, 22 Sep 2020 17:19:54 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=brooke.miller&quot; class=&quot;user-hover&quot; rel=&quot;brooke.miller&quot;&gt;brooke.miller&lt;/a&gt; I suppose what is not mentioned in the original description is that I use mongo shell as a user of MongoDB. As such, as a user of MongoDB, I would like the shell to perform topology discovery:&lt;/p&gt;

&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;When the directConnection=false URI option is given,&lt;/li&gt;
	&lt;li&gt;In addition to that, potentially, using some other mechanism that is shell-specific (such as a command line option dedicated to this function).&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;I understand that shell is also used by server engineers for various testing purposes and to that effect there are various helpers and tools implemented in the shell that do various things. If I need to perform complex testing, I would ordinarily do it using drivers I am familiar with (such as the Ruby one). The request here is for the shell to perform topology discovery in ordinary user-centric use cases, such as connecting to a deployment which happens to be a replica set to run commands.&lt;/p&gt;

&lt;p&gt;For example, if I want to issue stepdown:1 from the shell, I must provide RS name in the URI. The stepdown:1 command uses the documented runCommand API and does not use any internal shell helpers and such.&lt;/p&gt;</comment>
                            <comment id="3405485" author="brooke.miller" created="Tue, 22 Sep 2020 16:03:20 +0000"  >&lt;p&gt;Any update on your end, &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=oleg.pudeyev&quot; class=&quot;user-hover&quot; rel=&quot;oleg.pudeyev&quot;&gt;oleg.pudeyev&lt;/a&gt;?&#160;&lt;/p&gt;</comment>
                            <comment id="3385371" author="brooke.miller" created="Thu, 10 Sep 2020 15:01:26 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=oleg.pudeyev&quot; class=&quot;user-hover&quot; rel=&quot;oleg.pudeyev&quot;&gt;oleg.pudeyev&lt;/a&gt;, did you get a chance to review Judah&apos;s comment above?&lt;/p&gt;</comment>
                            <comment id="3368201" author="judah.schvimer" created="Mon, 31 Aug 2020 17:23:01 +0000"  >&lt;p&gt;Does &lt;a href=&quot;https://github.com/mongodb/mongo/blob/98d95e18f39540b33c491052901579b71ec430fc/jstests/libs/discover_topology.js&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;this javascript library&lt;/a&gt; meet your needs?&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <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>5.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                <customfield id="customfield_12751" key="com.atlassian.jira.plugin.system.customfieldtypes:multiselect">
                        <customfieldname>Assigned Teams</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="25142"><![CDATA[Server Tooling & Methods]]></customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Thu, 6 Aug 2020 16:17:25 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        3 years, 18 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>
                            3 years, 18 weeks, 1 day ago
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                    <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>backlog-server-stm</customfieldvalue>
            <customfieldvalue>brooke.miller@mongodb.com</customfieldvalue>
            <customfieldvalue>judah.schvimer@mongodb.com</customfieldvalue>
            <customfieldvalue>oleg.pudeyev@mongodb.com</customfieldvalue>
            <customfieldvalue>robert.guo@mongodb.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hxyjmv:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hxlax3:</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_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|hxy5w7:</customfieldvalue>

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