<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 06:00:40 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-64584] Don&apos;t hard-code the connection thread stack size</title>
                <link>https://jira.mongodb.org/browse/SERVER-64584</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;We are currently setting the connection thread stack size at a hard-coded 1MB here:&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://github.com/mongodb/mongo/blob/0e1fc9235a8aea220f10bacb76ef44fecd98bdfd/src/mongo/transport/service_executor_utils.cpp#L81&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/blob/0e1fc9235a8aea220f10bacb76ef44fecd98bdfd/src/mongo/transport/service_executor_utils.cpp#L81&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Technically, we are setting the size to the maximum of either the current stack size &lt;tt&gt;ulimit&lt;/tt&gt; or 1MB, whichever is less. This was done at the request of a user a long, long time ago in &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-2707&quot; title=&quot;make default stack size lower on linux&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-2707&quot;&gt;&lt;del&gt;SERVER-2707&lt;/del&gt;&lt;/a&gt; to reduce memory pressure on highly-threaded systems:&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://groups.google.com/g/mongodb-user/c/GOAOwYH483c&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://groups.google.com/g/mongodb-user/c/GOAOwYH483c&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This is not actually the case. The initial stack size is not an allocation but a reservation of address space. There is no additional memory pressure introduced by keeping the stack size at the default 8MB limit. The function of the &lt;tt&gt;ulimit&lt;/tt&gt; only prevents actually &lt;b&gt;using&lt;/b&gt; beyond a certain amount and does to by inducing an artificial stack exhaustion. In any case, this is not a thing you can do on Windows anyway, so it also represents a self-imposed platform difference.&lt;/p&gt;

&lt;p&gt;Since stack consumption is generally a function of platform (compiler, kernel, etc.) and usage, the optimal stack size is not actually predictable in this way. We should instead offer an option that allows users on supported platforms to set an initial stack size lower than the default 8MB and (potentially) an upper limit using &lt;tt&gt;setrlimit&lt;/tt&gt;. This should be documented as a feature available on resource-constrained platforms and not as a means of limiting resource consumption on production systems in general.&lt;/p&gt;</description>
                <environment></environment>
        <key id="2003367">SERVER-64584</key>
            <summary>Don&apos;t hard-code the connection thread stack size</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="10038" iconUrl="https://jira.mongodb.org/images/icons/subtask.gif" description="">Backlog</status>
                    <statusCategory id="2" key="new" colorName="default"/>
                                    <resolution id="-1">Unresolved</resolution>
                                        <assignee username="backlog-server-servicearch">Backlog - Service Architecture</assignee>
                                    <reporter username="ryan.egesdahl@mongodb.com">Ryan Egesdahl</reporter>
                        <labels>
                            <label>sa-remove-fv-backlog-22</label>
                    </labels>
                <created>Wed, 16 Mar 2022 19:38:25 +0000</created>
                <updated>Tue, 29 Aug 2023 13:27:00 +0000</updated>
                                                                                                <votes>1</votes>
                                    <watches>7</watches>
                                                                                                                <comments>
                            <comment id="4419550" author="billy.donahue" created="Thu, 17 Mar 2022 21:01:48 +0000"  >&lt;p&gt;We&apos;re talking about the difference between 1MiB and 2MiB I think.&lt;br/&gt;
Are we using the 2MiB &quot;jumbo&quot; pagesize in Linux now?&lt;br/&gt;
If so, then it&apos;s a matter of whether a page can fit two thread stacks or one.&lt;/p&gt;

&lt;p&gt;If page size is 2MiB, would the allocator let those 1MiB allocations share a page or would it force them onto their own page?&lt;br/&gt;
The allocation of exactly half the page size is an interesting edge. The allocator, if it needs any overhead would JUST BARELY not fit both into one page.&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="2143424">SERVER-69905</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is related to">
                                        <issuelink>
            <issuekey id="2003477">SERVER-64594</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="25132"><![CDATA[Service Arch]]></customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Wed, 16 Mar 2022 20:31:20 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        1 year, 46 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_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>rachelle.palmer@mongodb.com</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_11151" key="com.atlassian.jira.toolkit:LastCommentDate">
                        <customfieldname>Last public comment date</customfieldname>
                        <customfieldvalues>
                            1 year, 46 weeks, 6 days ago
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                    <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>backlog-server-servicearch</customfieldvalue>
            <customfieldvalue>billy.donahue@mongodb.com</customfieldvalue>
            <customfieldvalue>ryan.egesdahl@mongodb.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|i0nk73:</customfieldvalue>

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

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