<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 06:19:41 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-71674] Yield handlers not handling WCE thrown from restoring cursors</title>
                <link>https://jira.mongodb.org/browse/SERVER-71674</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;In some query stages like delete, we will need to call restoreState() in case the actual delete throws a WCE which invalidates the cursor. But restoreState() can also throw a WCE which is &lt;a href=&quot;https://github.com/mongodb/mongo/blob/cb7e2bec9f2647c2ff19b342fcdb84980ebb47a4/src/mongo/db/exec/delete_stage.cpp#L327-L342&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;not handled&lt;/a&gt;. This can cause the following &lt;tt&gt;next()&lt;/tt&gt; call lands the cursor to the beginning of the collection again, hitting the out-of-order invariant.&lt;/p&gt;</description>
                <environment></environment>
        <key id="2197543">SERVER-71674</key>
            <summary>Yield handlers not handling WCE thrown from restoring cursors</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="10033" iconUrl="https://jira.mongodb.org/images/icons/statuses/information.png" description="Status for tickets that need to be escalated and unblocked on our team.">Blocked</status>
                    <statusCategory id="4" key="indeterminate" colorName="inprogress"/>
                                    <resolution id="-1">Unresolved</resolution>
                                        <assignee username="backlog-server-execution">Backlog - Storage Execution Team</assignee>
                                    <reporter username="yuhong.zhang@mongodb.com">Yuhong Zhang</reporter>
                        <labels>
                    </labels>
                <created>Tue, 29 Nov 2022 16:25:07 +0000</created>
                <updated>Wed, 29 Nov 2023 18:30:52 +0000</updated>
                                                                                                <votes>0</votes>
                                    <watches>12</watches>
                                                                                                                <comments>
                            <comment id="5234536" author="dianna.hohensee" created="Mon, 27 Feb 2023 21:40:22 +0000"  >&lt;p&gt;I&apos;m going to put this ticket back into Needs Triage to gain wider support for either&lt;/p&gt;

&lt;p&gt;(a) removing the failpoint testing for artificial read path WCEs&lt;br/&gt;
(b) leaving this problem alone until such time that work is scheduled to handle WCEs in the read paths.&lt;/p&gt;

&lt;p&gt;A pro of keeping the testing active would be to catch new use cases. Although it&apos;s unclear to me how useful the testing currently is in that regard, since we clearly have scenarios and they are rarely caught. Nor does the failure signal help us with the final solution (complete read path WCE handling).&lt;/p&gt;

&lt;p&gt;A con of keeping the testing active is it could lead to more crazy long investigations when the source of the failure is very non-obvious.&lt;/p&gt;</comment>
                            <comment id="5218467" author="JIRAUSER1253424" created="Tue, 21 Feb 2023 21:20:27 +0000"  >&lt;p&gt;I pointed Dianna to the wrong failpoint. The one that throws WCEs is actually &lt;a href=&quot;https://github.com/10gen/mongo/blob/8fe8ae436514e4e490e8571219b71339333f3ceb/src/mongo/db/storage/wiredtiger/wiredtiger_record_store.h#L62&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;here&lt;/a&gt;.&#160;&lt;/p&gt;

&lt;p&gt;I&apos;m unlinking &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-69101&quot; title=&quot;Remove WTPrepareConflictForReads fail point&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-69101&quot;&gt;&lt;del&gt;SERVER-69101&lt;/del&gt;&lt;/a&gt; because it&apos;s actually related to a different failpoint &lt;tt&gt;WTPrepareConflictForReads&lt;/tt&gt;. A somewhat similar name&lt;img class=&quot;emoticon&quot; src=&quot;https://jira.mongodb.org/images/icons/emoticons/smile.png&quot; height=&quot;16&quot; width=&quot;16&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt;&lt;/p&gt;</comment>
                            <comment id="5151351" author="dianna.hohensee" created="Mon, 30 Jan 2023 15:33:27 +0000"  >&lt;p&gt;Linking &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-69101&quot; title=&quot;Remove WTPrepareConflictForReads fail point&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-69101&quot;&gt;&lt;del&gt;SERVER-69101&lt;/del&gt;&lt;/a&gt; because it discusses the failpoint in question.&lt;/p&gt;</comment>
                            <comment id="5128244" author="dianna.hohensee" created="Fri, 20 Jan 2023 21:04:59 +0000"  >&lt;p&gt;I spoke offline with Yuhong.&lt;/p&gt;

&lt;p&gt;The idea here is that any query stage &lt;tt&gt;::restoreState()&lt;/tt&gt; function call, like &lt;a href=&quot;https://github.com/mongodb/mongo/blob/cb7e2bec9f2647c2ff19b342fcdb84980ebb47a4/src/mongo/db/exec/delete_stage.cpp#L324&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;this one where the WCE arose in the linked test failure &lt;/a&gt;, can potentially throw a &lt;tt&gt;WCE&lt;/tt&gt;. This happens because after an initial &lt;tt&gt;WCE A&lt;/tt&gt; causes the query stage to request a yield, the query restore state logic ultimately calls &lt;a href=&quot;https://github.com/mongodb/mongo/blob/5b893233d7497ff24ce82073426062c846a25ec9/src/mongo/db/storage/wiredtiger/wiredtiger_record_store.cpp#L2449&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;&lt;tt&gt;WT::search_near()&lt;/tt&gt; to reposition the cursor&lt;/a&gt; that was unpositioned by &lt;tt&gt;WCE A&lt;/tt&gt; and can throw a new&#160;&lt;tt&gt;WCE B&lt;/tt&gt;. &lt;a href=&quot;https://github.com/mongodb/mongo/blob/5b893233d7497ff24ce82073426062c846a25ec9/src/mongo/db/storage/wiredtiger/wiredtiger_prepare_conflict.h#L72-L76&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;This is the testing-only failpoint to randomly throw artificial WCEs&lt;/a&gt;. Because any WT read in theory could throw a &lt;tt&gt;WCE&lt;/tt&gt;.&lt;/p&gt;

&lt;p&gt;However, I don&apos;t believe WT ever does throw a WCE for a read today. It only happens artificially in the MDB layer for testing purposes. And I don&apos;t believe query code today is prepared to deal with a WCE. And that is what is happening in our test suite artificially, and the motivation for this ticket. Therefore the options for this ticket are,&lt;/p&gt;

&lt;p&gt;(a) we start supporting WCE for reads in the query layer.&lt;/p&gt;

&lt;p&gt;On first thought for (a), we retry the WCE someplace in the query operation stack, another WCE retry loop around the query ::restoreState() calls, or inside said function call. In theory an operation can throw WCEs endlessly, but that&apos;s true today for all WCE handling.&lt;/p&gt;

&lt;p&gt;(c) we modify our testing not to throw artificial WCEs in the query read path / for search_near() calls.&lt;/p&gt;</comment>
                            <comment id="5015574" author="JIRAUSER1253362" created="Tue, 29 Nov 2022 16:53:28 +0000"  >&lt;p&gt;When this ticket is addressed, we should request QE for a code review.&#160;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                            <outwardlinks description="depends on">
                                        <issuelink>
            <issuekey id="2480963">WT-11871</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is depended on by">
                                                        </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="320967">SERVER-26452</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="2012930">SERVER-65106</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="627560">SERVER-37861</issuekey>
        </issuelink>
                            </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_18555" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname># of Sprints</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>3.0</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                    <customfield id="customfield_12751" key="com.atlassian.jira.plugin.system.customfieldtypes:multiselect">
                        <customfieldname>Assigned Teams</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="25136"><![CDATA[Storage Execution]]></customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Tue, 29 Nov 2022 16:53:28 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        49 weeks, 2 days ago
    
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_18254" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Dependencies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue><![CDATA[<a href='https://jira.mongodb.org/browse/WT-11871'>WT-11871</a>]]></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>louis.williams@mongodb.com</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_11151" key="com.atlassian.jira.toolkit:LastCommentDate">
                        <customfieldname>Last public comment date</customfieldname>
                        <customfieldvalues>
                            49 weeks, 2 days ago
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_16465" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Linked BF Score</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>6.0</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                        <customfield id="customfield_10032" key="com.atlassian.jira.plugin.system.customfieldtypes:select">
                        <customfieldname>Operating System</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10026"><![CDATA[ALL]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>backlog-server-execution</customfieldvalue>
            <customfieldvalue>dianna.hohensee@mongodb.com</customfieldvalue>
            <customfieldvalue>fausto.leyva@mongodb.com</customfieldvalue>
            <customfieldvalue>yuhong.zhang@mongodb.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|i1kixz:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|i23td3:g</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_10557" key="com.pyxis.greenhopper.jira:gh-sprint">
                        <customfieldname>Sprint</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue id="6594">Execution Team 2023-02-20</customfieldvalue>
    <customfieldvalue id="6685">Execution Team 2023-02-06</customfieldvalue>
    <customfieldvalue id="6773">Execution Team 2023-03-06</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|i1k53b:</customfieldvalue>

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