<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 05:32:19 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-53966] Allow specifying maxTransactionLockRequestTimeoutMillis per-transaction</title>
                <link>https://jira.mongodb.org/browse/SERVER-53966</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;When using Transactions, it is useful to control write timeouts avoid WriteConflict errors.&lt;/p&gt;

&lt;p&gt;From the MongoDB docs:&#160;&lt;a href=&quot;https://docs.mongodb.com/manual/reference/parameters/#param.maxTransactionLockRequestTimeoutMillis)&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://docs.mongodb.com/manual/reference/parameters/#param.maxTransactionLockRequestTimeoutMillis&lt;/a&gt;&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;&quot;By default,&#160;&lt;a href=&quot;https://docs.mongodb.com/manual/core/transactions/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;multi-document transactions&lt;/a&gt;&#160;wait&#160;&lt;tt&gt;5&lt;/tt&gt;&#160;milliseconds.... If an operation provides a greater timeout in a lock request,&#160;&lt;a href=&quot;https://docs.mongodb.com/manual/reference/parameters/#param.maxTransactionLockRequestTimeoutMillis&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;&lt;tt&gt;maxTransactionLockRequestTimeoutMillis&lt;/tt&gt;&lt;/a&gt;&#160;overrides the operation-specific timeout.&quot;&lt;/li&gt;
	&lt;li&gt;&quot;&lt;tt&gt;-1&lt;/tt&gt;&#160;to use the operation specific timeout.&quot;&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;5ms is quite low for my use case, I&apos;m getting frequent WriteConflict errors I&apos;d like to make it larger. My feedback here:&lt;/p&gt;
&lt;ol&gt;
	&lt;li&gt;It is not clear to me how to set operation specific timeout. It appears would use maxTimeMs &lt;img class=&quot;emoticon&quot; src=&quot;https://jira.mongodb.org/images/icons/emoticons/help_16.png&quot; height=&quot;16&quot; width=&quot;16&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt; or wtimeout &lt;img class=&quot;emoticon&quot; src=&quot;https://jira.mongodb.org/images/icons/emoticons/help_16.png&quot; height=&quot;16&quot; width=&quot;16&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt;, however many write operations such as &quot;update&quot; do not support this parameter.&#160;&lt;a href=&quot;https://docs.mongodb.com/manual/reference/method/db.collection.update/index.html&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://docs.mongodb.com/manual/reference/method/db.collection.update/index.html&lt;/a&gt;&lt;/li&gt;
	&lt;li&gt;It would be nice to be able to set this parameter at the transaction level. Perhaps that would need to be done in the driver (and passed down to the individual operations)?&lt;/li&gt;
	&lt;li&gt;The docs imply that even if you set an operation specific timeout, unless you&apos;ve set maxTransactionLockRequestTimeoutMillis to -1, the max timeout will still be 5ms.&lt;/li&gt;
	&lt;li&gt;If you set&#160;maxTransactionLockRequestTimeoutMillis to -1, does it still use 5ms as a default? Or 0? or Infinity?&lt;/li&gt;
&lt;/ol&gt;


&lt;p&gt;&#160;&lt;/p&gt;</description>
                <environment></environment>
        <key id="1597330">SERVER-53966</key>
            <summary>Allow specifying maxTransactionLockRequestTimeoutMillis per-transaction</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="13202">Works as Designed</resolution>
                                        <assignee username="judah.schvimer@mongodb.com">Judah Schvimer</assignee>
                                    <reporter username="shields@tablecheck.com">Johnny Shields</reporter>
                        <labels>
                    </labels>
                <created>Fri, 22 Jan 2021 07:03:10 +0000</created>
                <updated>Fri, 27 Oct 2023 13:52:31 +0000</updated>
                            <resolved>Wed, 2 Nov 2022 14:03:17 +0000</resolved>
                                                                                        <votes>0</votes>
                                    <watches>10</watches>
                                                                                                                <comments>
                            <comment id="4938416" author="judah.schvimer" created="Mon, 31 Oct 2022 00:11:39 +0000"  >&lt;p&gt;Hi! &lt;/p&gt;

&lt;p&gt;Thank you for this report and I&apos;m sorry for the very long delay, this seems to have gotten lost in our backlog.&lt;/p&gt;

&lt;p&gt;In the description, it says you are receiving WriteConflict errors. WriteConflicts in MongoDB are caused by &lt;a href=&quot;https://www.mongodb.com/docs/manual/core/transactions-production-consideration/#in-progress-transactions-and-write-conflicts&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;concurrent conflicting document writes&lt;/a&gt;. This is done to ensure we provide snapshot isolation transactions. If a lock acquisition times out (locks are only acquired at the collection, database, and global levels), you&apos;ll receive a &lt;a href=&quot;https://github.com/mongodb/mongo/blob/ab34541c92e3ee679ea155b6331253a4e031d451/src/mongo/base/error_codes.yml#L61&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;LockTimeout&lt;/a&gt; error. If you get a WriteConflict, there is no amount of time you could wait for the conflict to resolve, you must abort the transaction and restart with a new storage engine snapshot.&lt;/p&gt;

&lt;p&gt;Does this answer your question? If so, I will close this ticket as &quot;Works as Designed&quot;.&lt;/p&gt;</comment>
                            <comment id="4013930" author="JIRAUSER1254095" created="Fri, 20 Aug 2021 18:09:25 +0000"  >&lt;p&gt;Yes please, thank you for following up on this.&lt;/p&gt;</comment>
                            <comment id="3764937" author="JIRAUSER1256207" created="Mon, 10 May 2021 20:28:05 +0000"  >&lt;p&gt;We will investigate this, and get back to you. the main questions to answer: &lt;/p&gt;

&lt;p&gt;Clarify:&lt;/p&gt;

&lt;p&gt;1. The docs imply that even if you set an operation specific timeout, unless you&apos;ve set maxTransactionLockRequestTimeoutMillis to -1, the max timeout will still be 5ms.&lt;br/&gt;
2. If you set maxTransactionLockRequestTimeoutMillis to -1, does it still use 5ms as a default? Or 0? or Infinity?&lt;/p&gt;

&lt;p&gt;3. how to set operation specific timeout. It appears would use maxTimeMs  or wtimeout , however many write operations such as &quot;update&quot; do not support this parameter. &lt;a href=&quot;https://docs.mongodb.com/manual/reference/method/db.collection.update/index.html&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://docs.mongodb.com/manual/reference/method/db.collection.update/index.html&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="3585516" author="eric.sedor" created="Wed, 27 Jan 2021 18:41:07 +0000"  >&lt;p&gt;Hi &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=shields%40tablecheck.com&quot; class=&quot;user-hover&quot; rel=&quot;shields@tablecheck.com&quot;&gt;shields@tablecheck.com&lt;/a&gt;,&lt;/p&gt;

&lt;p&gt;Some of these questions may be more appropriate for the &lt;a href=&quot;https://community.mongodb.com&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;MongoDB Developer Community Forums&lt;/a&gt;, but I am passing this to an appropriate team to consider your request to allow specifying maxTransactionLockRequestTimeoutMillis at a transaction level, and to obtain clarity on the operation-specific timeout documentation.&lt;/p&gt;

&lt;p&gt;Thanks,&lt;br/&gt;
Eric&lt;/p&gt;</comment>
                    </comments>
                    <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                <customfield id="customfield_10050" key="com.atlassian.jira.toolkit:comments">
                        <customfieldname># Replies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>4.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Wed, 27 Jan 2021 18:38:14 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        1 year, 14 weeks, 3 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>luke.bonanomi@mongodb.com</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_11151" key="com.atlassian.jira.toolkit:LastCommentDate">
                        <customfieldname>Last public comment date</customfieldname>
                        <customfieldvalues>
                            1 year, 14 weeks, 3 days ago
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                    <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>eric.sedor@mongodb.com</customfieldvalue>
            <customfieldvalue>gaurav.gk@mongodb.com</customfieldvalue>
            <customfieldvalue>shields@tablecheck.com</customfieldvalue>
            <customfieldvalue>judah.schvimer@mongodb.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hyqr53:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hycfgf:</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>
                                    <customfieldvalue><![CDATA[eric.sedor@mongodb.com]]></customfieldvalue>
    

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_14350" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>serverRank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hyqde7:</customfieldvalue>

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