<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Wed Feb 07 22:45:01 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>[COMPASS-7009] Frequent &quot;Connection pool cleared&quot; error</title>
                <link>https://jira.mongodb.org/browse/COMPASS-7009</link>
                <project id="13182" key="COMPASS">Compass </project>
                    <description>&lt;h3&gt;&lt;a name=&quot;ProblemStatement%2FRationale&quot;&gt;&lt;/a&gt;&lt;b&gt;Problem Statement/Rationale&lt;/b&gt;&lt;/h3&gt;

&lt;p&gt;&lt;font color=&quot;#505f79&quot;&gt;Experiencing a frequent error when trying to connect to mongos via GCP IAP tunnel:&lt;/font&gt;&lt;br/&gt;
&#160;&lt;br/&gt;
&lt;tt&gt;An error occurred while loading instance info: Connection pool for localhost:27027 was cleared because another operation failed with: &quot;connection &amp;lt;monitor&amp;gt; to 127.0.0.1:27027 closed&quot;&lt;/tt&gt; * This happens about 9 out of 10 times until it successfully connects.&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;Connecting on the command line via mongosh with the same connection string succeeds 100% of the time. Same for Studio 3T and JetBrains Goland (DB plugin).&lt;/li&gt;
	&lt;li&gt;Once successfully connected the error does not appear for the duration of the session.&lt;/li&gt;
	&lt;li&gt;I&apos;ve tried changing a bunch of different connection settings to no effect. e.g. direction connection, socket/connect timeouts, wait queue time, heartbeat frequency, etc.&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;&lt;b&gt;Please be sure to attach relevant logs &lt;em&gt;with any sensitive data redacted&lt;/em&gt;.&lt;/b&gt;&lt;/p&gt;

&lt;p&gt;Compass logs attached.&lt;/p&gt;
&lt;h3&gt;&lt;a name=&quot;StepstoReproduce&quot;&gt;&lt;/a&gt;&lt;b&gt;Steps to Reproduce&lt;/b&gt;&lt;/h3&gt;
&lt;ol&gt;
	&lt;li&gt;Set up Mongo on a GCP VM such that it&apos;s accessible via &lt;a href=&quot;https://cloud.google.com/iap/docs/using-tcp-forwarding&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;IAP&lt;/a&gt;, mongos is running on port 27018, and LDAP authentication is required.&lt;/li&gt;
	&lt;li&gt;Set up the tunnel. I used something like this: &lt;tt&gt;gcloud --project my-project compute start-iap-tunnel mongo-vm 27018 --local-host-port=127.0.0.1:27027 --zone=northamerica-northeast1-b&lt;/tt&gt;&lt;/li&gt;
	&lt;li&gt;Use a connection string like the following: mongodb://myusername%40example.com:*****@localhost:27027/?readPreference=primary&amp;amp;ssl=false&amp;amp;authMechanism=PLAIN&amp;amp;authSource=%24external&amp;amp;directConnection=true&lt;/li&gt;
	&lt;li&gt;Connect a few times&lt;/li&gt;
&lt;/ol&gt;


&lt;h3&gt;&lt;a name=&quot;ExpectedResults&quot;&gt;&lt;/a&gt;&lt;b&gt;Expected Results&lt;/b&gt;&lt;/h3&gt;

&lt;p&gt;&lt;font color=&quot;#505f79&quot;&gt;Successful connection&lt;/font&gt;&lt;/p&gt;
&lt;h3&gt;&lt;a name=&quot;ActualResults&quot;&gt;&lt;/a&gt;&lt;b&gt;Actual Results&lt;/b&gt;&lt;/h3&gt;

&lt;p&gt;&lt;font color=&quot;#505f79&quot;&gt;Most of the time it errors out.&lt;/font&gt;&lt;/p&gt;
&lt;h3&gt;&lt;a name=&quot;AdditionalNotes&quot;&gt;&lt;/a&gt;&lt;b&gt;Additional Notes&lt;/b&gt;&lt;/h3&gt;

&lt;p&gt;&lt;font color=&quot;#505f79&quot;&gt;My workaround right now is to quickly open a bunch of Compass windows and flip through them all, connecting in each one, and then closing any that have errored out. This is annoying enough that most of my team have moved off Compass.&lt;/font&gt;&lt;/p&gt;</description>
                <environment>OS: macOS Ventura 13.4.1&lt;br/&gt;
node.js / npm versions:&lt;br/&gt;
Additional info: Macbook Pro 16-inch, 2021, Apple M1 Pro, 16GB RAM. MongoDB Compass 1.38.2 (but issue has been happening in several past major versions at least as far back as 1.33)&lt;br/&gt;
</environment>
        <key id="2385294">COMPASS-7009</key>
            <summary>Frequent &quot;Connection pool cleared&quot; 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="1" iconUrl="https://jira.mongodb.org/images/icons/statuses/open.png" description="">Open</status>
                    <statusCategory id="2" key="new" colorName="default"/>
                                    <resolution id="-1">Unresolved</resolution>
                                        <assignee username="julia.oppenheim@mongodb.com">Julia Oppenheim</assignee>
                                    <reporter username="dv@glyphy.com">D V</reporter>
                        <labels>
                            <label>needs-prioritization</label>
                    </labels>
                <created>Thu, 6 Jul 2023 18:48:06 +0000</created>
                <updated>Fri, 4 Aug 2023 14:23:47 +0000</updated>
                                                                                <due></due>
                            <votes>0</votes>
                                    <watches>3</watches>
                                                                                                                <comments>
                            <comment id="5567043" author="dv@glyphy.com" created="Fri, 14 Jul 2023 15:13:30 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=anna.henningsen%40mongodb.com&quot; class=&quot;user-hover&quot; rel=&quot;anna.henningsen@mongodb.com&quot;&gt;anna.henningsen@mongodb.com&lt;/a&gt; Thanks for the context! I can definitely see how the &quot;proper&quot; solution is difficult.&lt;/p&gt;

&lt;p&gt;As far as I know there&apos;re no TOTP/OTP on my side. At least, I don&apos;t have another auth factor that I need to provide in order to connect via LDAP. I just run the gcloud start-iap-tunnel command.&lt;/p&gt;

&lt;p&gt;I agree that updating the error message could be sufficient, especially if it has the workaround of adding maxPool=1 as an explicit suggestion within it, since it&apos;s totally non-obvious. My entire team of 50+ engineers essentially gave up on Compass, because it was the only client that showed that error, so it felt like a Compass-specific bug.&lt;/p&gt;</comment>
                            <comment id="5559696" author="JIRAUSER1256529" created="Wed, 12 Jul 2023 09:51:09 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=dv%40glyphy.com&quot; class=&quot;user-hover&quot; rel=&quot;dv@glyphy.com&quot;&gt;dv@glyphy.com&lt;/a&gt; It&#8217;s not straightforward, unfortunately. I assume you&#8217;re using LDAP with some sort of TOTP mechanism, where the OTP is part of the password you pass to Compass?&lt;/p&gt;

&lt;p&gt;The reason why that fails is that Compass opens (and this might be obvious from the error message here) a connection pool, but uses the same OTP for all of those connections, so some of them will successfully authenticate and some not. This is a very specific use case, though, and not one that we can reliably detect at that, and in general, Compass &lt;em&gt;does&lt;/em&gt; utilize the connection pool to improve application performance.&lt;/p&gt;

&lt;p&gt;So, yes, we are aware of this pain point. We might be able to improve the error message here, but a &#8220;proper&#8221; solution is unfortunately not trivial.&lt;/p&gt;

&lt;p&gt;(As a side note, we announced upcoming preview support for OpenID Connect authentication for MongoDB 7.0+ databases just last month. Switching authentication mechanisms is obviously a bigger change for users, but that&#8217;s part of our long-term story for better support for &#8220;modern&#8221; human-facing authentication.)&lt;/p&gt;</comment>
                            <comment id="5559060" author="dv@glyphy.com" created="Tue, 11 Jul 2023 22:28:15 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=anna.henningsen%40mongodb.com&quot; class=&quot;user-hover&quot; rel=&quot;anna.henningsen@mongodb.com&quot;&gt;anna.henningsen@mongodb.com&lt;/a&gt; Thank you, that entirely solves the issue! Should this setting be enabled by default?&lt;/p&gt;</comment>
                            <comment id="5557550" author="JIRAUSER1256529" created="Tue, 11 Jul 2023 15:07:41 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=dv%40glyphy.com&quot; class=&quot;user-hover&quot; rel=&quot;dv@glyphy.com&quot;&gt;dv@glyphy.com&lt;/a&gt; What happens if you add &lt;tt&gt;maxPoolSize=1&lt;/tt&gt; to your connection string? Does that make any difference?&lt;/p&gt;</comment>
                            <comment id="5548476" author="dbeng-pm-bot" created="Thu, 6 Jul 2023 18:48:09 +0000"  >&lt;p&gt;Hello &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=dv%40glyphy.com&quot; class=&quot;user-hover&quot; rel=&quot;dv@glyphy.com&quot;&gt;dv@glyphy.com&lt;/a&gt;, thank you for reaching out to us! The team will review your issue and get back to you soon as soon as possible. &lt;/p&gt;

&lt;p&gt;Please review your issue to ensure you&apos;ve included your environment details and have attached relevant logs (with any sensitive data redacted), so that we&apos;re best able to provide you a timely and thorough response. Thanks again!&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="1927137">SERVER-61585</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1559556">COMPASS-4527</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <attachments>
                            <attachment id="460596" name="SCR-20230706-nclu.png" size="105862" author="dv@glyphy.com" created="Thu, 6 Jul 2023 18:46:26 +0000"/>
                            <attachment id="460597" name="compass-logs.json" size="24775" author="dv@glyphy.com" created="Thu, 6 Jul 2023 18:35:11 +0000"/>
                    </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_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Thu, 6 Jul 2023 18:48:09 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        29 weeks, 5 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_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>jessica.sigafoos@mongodb.com</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_11151" key="com.atlassian.jira.toolkit:LastCommentDate">
                        <customfieldname>Last public comment date</customfieldname>
                        <customfieldvalues>
                            29 weeks, 5 days ago
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>anna.henningsen@mongodb.com</customfieldvalue>
            <customfieldvalue>dv@glyphy.com</customfieldvalue>
            <customfieldvalue>julia.oppenheim@mongodb.com</customfieldvalue>
            <customfieldvalue>dbeng-pm-bot</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|i2gslj:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|i1yy5s:</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_10555" key="com.atlassian.jira.plugin.system.customfieldtypes:float">
                        <customfieldname>Story Points</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>3.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_14350" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>serverRank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|i2geqv:</customfieldvalue>

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