<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 08:37:58 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>[GODRIVER-2168] Prevent unnecessary connection churn and timeout idle connections</title>
                <link>https://jira.mongodb.org/browse/GODRIVER-2168</link>
                <project id="14289" key="GODRIVER">Go Driver</project>
                    <description>&lt;p&gt;Currently there&apos;s only a single idle timeout that applies to all connections and by default there&apos;s no timeout. Without a timeout then a burst in traffic will leave unnecessary connections around indefinitely. If you set a timeout then you cause unnecessary churn if your pool is already at the minimum size.&lt;/p&gt;

&lt;p&gt;Could there be some way to define a dynamic idle timeout where its x if the pool is more than the minimum but if its already at the minimum then its y. Maybe allow a user-defined function to be set to define it based on some pool stats that get sent to the function?&lt;/p&gt;

&lt;p&gt;What does the Mongo team recommend to solve these 2 issues?&lt;/p&gt;</description>
                <environment></environment>
        <key id="1887543">GODRIVER-2168</key>
            <summary>Prevent unnecessary connection churn and timeout idle connections</summary>
                <type id="4" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14710&amp;avatarType=issuetype">Improvement</type>
                                            <priority id="4" iconUrl="https://jira.mongodb.org/images/icons/priorities/minor.svg">Minor - P4</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="9">Done</resolution>
                                        <assignee username="matt.dale@mongodb.com">Matt Dale</assignee>
                                    <reporter username="james@getadmiral.com">James Hartig</reporter>
                        <labels>
                    </labels>
                <created>Fri, 1 Oct 2021 02:05:10 +0000</created>
                <updated>Wed, 24 Nov 2021 22:17:10 +0000</updated>
                            <resolved>Wed, 24 Nov 2021 22:17:10 +0000</resolved>
                                                                    <component>Connections</component>
                    <component>Options &amp;amp; Configuration</component>
                                        <votes>0</votes>
                                    <watches>2</watches>
                                                                                                                <comments>
                            <comment id="4211043" author="JIRAUSER1259527" created="Wed, 24 Nov 2021 22:16:22 +0000"  >&lt;p&gt;Sounds great! I&apos;m closing this for now.&lt;/p&gt;</comment>
                            <comment id="4192488" author="james@getadmiral.com" created="Tue, 16 Nov 2021 17:21:09 +0000"  >&lt;p&gt;Thanks for the detailed answer! Yes, I think that will work for now and the further enhancement will only help. Thanks again!&lt;/p&gt;</comment>
                            <comment id="4179351" author="JIRAUSER1259527" created="Wed, 10 Nov 2021 00:59:40 +0000"  >&lt;p&gt;Hey &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=james%40getadmiral.com&quot; class=&quot;user-hover&quot; rel=&quot;james@getadmiral.com&quot;&gt;james@getadmiral.com&lt;/a&gt;, thanks for the question! We&apos;ve actually started trying to address the default idle timeout and interaction between &lt;tt&gt;maxIdleTimeMS&lt;/tt&gt; and &lt;tt&gt;minPoolSize&lt;/tt&gt; with &lt;a href=&quot;https://jira.mongodb.org/browse/DRIVERS-1977&quot; class=&quot;external-link&quot; rel=&quot;nofollow&quot;&gt;DRIVERS-1977&lt;/a&gt;. That ticket (currently) recommends updating the specification for all drivers to use a 30-minute default idle timeout and only close idle connections if the pool size is greater than &lt;tt&gt;minPoolSize&lt;/tt&gt;. If that change is adopted, each driver team (including the Go driver team) will update the driver behavior to match the spec.&lt;/p&gt;

&lt;p&gt;As for what you can do right now, setting a high &lt;tt&gt;maxIdleTimeMS&lt;/tt&gt; value like 30 minutes to 1 hour may mitigate some connection churn caused by the interaction between &lt;tt&gt;maxIdleTimeMS&lt;/tt&gt; and &lt;tt&gt;minPoolSize&lt;/tt&gt; by reducing how often connections are closed due to idle timeout. Does setting &lt;tt&gt;maxIdleTimeMS&lt;/tt&gt; to a value like 1800000 (30 minutes) help manage connection pool size in your application?&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="1917803">DRIVERS-1977</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_15850" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hznmr3:</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>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            </customfields>
    </item>
</channel>
</rss>