<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 04:27:51 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-31684] QueryPlanKilled (operation exceeded time limit) in $changeStream with updateLookup</title>
                <link>https://jira.mongodb.org/browse/SERVER-31684</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;On a 3.6.0-rc0 single node replica set, while applying a CRUD workload with 16 or more threads, a change stream using the option fullDocument: updateLookup eventually fails during a getMore with the following error:&lt;/p&gt;
&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;2017-10-23T16:51:32.883-0400 I QUERY    [thread2] js thread raised js exception: JSInterpreterFailure: Error: getMore command failed: {&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	&quot;operationTime&quot; : Timestamp(1508791892, 30247),&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	&quot;ok&quot; : 0,&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	&quot;errmsg&quot; : &quot;collection or index disappeared when cursor yielded: ExceededTimeLimit: operation exceeded time limit&quot;,&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	&quot;code&quot; : 175,&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	&quot;codeName&quot; : &quot;QueryPlanKilled&quot;,&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	&quot;$clusterTime&quot; : {&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;		&quot;clusterTime&quot; : Timestamp(1508791892, 30249),&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;		&quot;signature&quot; : {&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;			&quot;hash&quot; : BinData(0,&quot;AAAAAAAAAAAAAAAAAAAAAAAAAAA=&quot;),&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;			&quot;keyId&quot; : NumberLong(0)&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;		}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;	}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;</description>
                <environment></environment>
        <key id="449643">SERVER-31684</key>
            <summary>QueryPlanKilled (operation exceeded time limit) in $changeStream with updateLookup</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="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="13201">Fixed</resolution>
                                        <assignee username="martin.neupauer@mongodb.com">Martin Neupauer</assignee>
                                    <reporter username="yves.duhem">Yves Duhem</reporter>
                        <labels>
                    </labels>
                <created>Mon, 23 Oct 2017 21:01:43 +0000</created>
                <updated>Mon, 30 Oct 2023 23:12:34 +0000</updated>
                            <resolved>Mon, 18 Dec 2017 17:40:34 +0000</resolved>
                                    <version>3.6.0-rc0</version>
                                    <fixVersion>3.6.2</fixVersion>
                    <fixVersion>3.7.1</fixVersion>
                                    <component>Querying</component>
                    <component>Replication</component>
                                        <votes>0</votes>
                                    <watches>13</watches>
                                                                                                                <comments>
                            <comment id="1763970" author="xgen-internal-githook" created="Wed, 3 Jan 2018 16:26:37 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Martin Neupauer&apos;, &apos;username&apos;: &apos;MartinNeupauer&apos;, &apos;email&apos;: &apos;martin.neupauer@mongodb.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-31684&quot; title=&quot;QueryPlanKilled (operation exceeded time limit) in $changeStream with updateLookup&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-31684&quot;&gt;&lt;del&gt;SERVER-31684&lt;/del&gt;&lt;/a&gt; Fix unexpected &quot;operation exceeded time limit&quot; errors&lt;/p&gt;

&lt;p&gt;The changestream queries used an operation context deadline to track&lt;br/&gt;
a wait time before returning EOF. This occasionaly interfered with&lt;br/&gt;
normal operation deadlines leading to unexpected errors.&lt;/p&gt;

&lt;p&gt;(cherry picked from commit 962c5c61c93776aa4d1a8efb67a1a80cb3bb2ad0)&lt;br/&gt;
Branch: v3.6&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/8d2276dfa94673f0ca1480fc87977a6f36c2816a&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/8d2276dfa94673f0ca1480fc87977a6f36c2816a&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1754549" author="xgen-internal-githook" created="Mon, 18 Dec 2017 16:19:23 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Martin Neupauer&apos;, &apos;email&apos;: &apos;martin.neupauer@mongodb.com&apos;, &apos;username&apos;: &apos;MartinNeupauer&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-31684&quot; title=&quot;QueryPlanKilled (operation exceeded time limit) in $changeStream with updateLookup&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-31684&quot;&gt;&lt;del&gt;SERVER-31684&lt;/del&gt;&lt;/a&gt; Fix unexpected &quot;operation exceeded time limit&quot; errors&lt;/p&gt;

&lt;p&gt;The changestream queries used an operation context deadline to track&lt;br/&gt;
a wait time before returning EOF. This occasionaly interfered with&lt;br/&gt;
normal operation deadlines leading to unexpected errors.&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/962c5c61c93776aa4d1a8efb67a1a80cb3bb2ad0&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/962c5c61c93776aa4d1a8efb67a1a80cb3bb2ad0&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1753174" author="david.storch" created="Fri, 15 Dec 2017 16:58:42 +0000"  >&lt;p&gt;Agree: this should be backported to 3.6.&lt;/p&gt;</comment>
                            <comment id="1752355" author="xgen-internal-githook" created="Thu, 14 Dec 2017 19:59:09 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Spencer Jackson&apos;, &apos;email&apos;: &apos;spencer.jackson@mongodb.com&apos;, &apos;username&apos;: &apos;spencerjackson&apos;}
&lt;p&gt;Message: Revert &quot;&lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-31684&quot; title=&quot;QueryPlanKilled (operation exceeded time limit) in $changeStream with updateLookup&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-31684&quot;&gt;&lt;del&gt;SERVER-31684&lt;/del&gt;&lt;/a&gt; Fix unexpected &quot;operation exceeded time limit&quot; errors&quot;&lt;/p&gt;

&lt;p&gt;This reverts commit b79e5f04ffc79b5892f89c22b9e5f26a297b1185.&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/1f38fb202b9f8696cf28d39e674242e036c0b75c&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/1f38fb202b9f8696cf28d39e674242e036c0b75c&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1751908" author="charlie.swanson" created="Thu, 14 Dec 2017 15:36:15 +0000"  >&lt;p&gt;I&apos;m just gonna jump in and vote yes, I checked the backport requested box &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="1751809" author="james.wahlin@10gen.com" created="Thu, 14 Dec 2017 13:59:44 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=martin.neupauer&quot; class=&quot;user-hover&quot; rel=&quot;martin.neupauer&quot;&gt;martin.neupauer&lt;/a&gt; / &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=david.storch&quot; class=&quot;user-hover&quot; rel=&quot;david.storch&quot;&gt;david.storch&lt;/a&gt; - should we consider backporting this to 3.6?&lt;/p&gt;</comment>
                            <comment id="1750186" author="xgen-internal-githook" created="Tue, 12 Dec 2017 20:55:13 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Martin Neupauer&apos;, &apos;email&apos;: &apos;martin.neupauer@mongodb.com&apos;, &apos;username&apos;: &apos;MartinNeupauer&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-31684&quot; title=&quot;QueryPlanKilled (operation exceeded time limit) in $changeStream with updateLookup&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-31684&quot;&gt;&lt;del&gt;SERVER-31684&lt;/del&gt;&lt;/a&gt; Fix unexpected &quot;operation exceeded time limit&quot; errors&lt;/p&gt;

&lt;p&gt;The changestream queries used an operation context deadline to track&lt;br/&gt;
a wait time before returning EOF. This occasionaly interfered with&lt;br/&gt;
normal operation deadlines leading to unexpected errors.&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/b79e5f04ffc79b5892f89c22b9e5f26a297b1185&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/b79e5f04ffc79b5892f89c22b9e5f26a297b1185&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1722929" author="martin.neupauer" created="Fri, 10 Nov 2017 19:52:48 +0000"  >&lt;p&gt;almost there ... the timeout errors are gone but the test hangs.&lt;/p&gt;</comment>
                            <comment id="1722573" author="martin.neupauer" created="Fri, 10 Nov 2017 15:23:03 +0000"  >&lt;p&gt;oh, in the DocumentSourceLookupChangePostImage::getNext there is pSource-&amp;gt;getNext() call not guarded by the OperationContext::DeadlineStash. I&apos;ll move the guard to the top of getNext and see what happens.&lt;/p&gt;</comment>
                            <comment id="1722017" author="martin.neupauer" created="Thu, 9 Nov 2017 21:02:22 +0000"  >&lt;p&gt;somethings not right and I have no idea what - it seems that two DocumentSourceCursors are both marked as normal (i.e. not tailable) hence all timeouts fire as expected. &lt;br/&gt;
It looks like that it is not the lookup cursor (&lt;a href=&quot;https://github.com/mongodb/mongo/blob/r3.6.0-rc2/src/mongo/db/pipeline/document_source_lookup_change_post_image.cpp#L71-L72&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/blob/r3.6.0-rc2/src/mongo/db/pipeline/document_source_lookup_change_post_image.cpp#L71-L72&lt;/a&gt;) that is failing.&lt;/p&gt;</comment>
                            <comment id="1721343" author="charlie.swanson" created="Thu, 9 Nov 2017 12:25:36 +0000"  >&lt;p&gt;Ah yes, &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=martin.neupauer&quot; class=&quot;user-hover&quot; rel=&quot;martin.neupauer&quot;&gt;martin.neupauer&lt;/a&gt; - there are two DocumentSourceCursors at play here, one is the one reading the oplog and generate the change notifications, the other is the one doing the lookup for the post-image of any update operations. For that update lookup cursor, we only generate one document and so expect it to be shortly lived, and is not tailable. Further, we explicitly suspend the maxTimeMS deadline while creating/using that cursor, &lt;a href=&quot;https://github.com/mongodb/mongo/blob/r3.6.0-rc2/src/mongo/db/pipeline/document_source_lookup_change_post_image.cpp#L71-L72&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;done here&lt;/a&gt;. Can you investigate why that doesn&apos;t seem to be working? It looks like somehow there is still a perceived deadline that&apos;s causing it to think it has exceeded its time limit.&lt;/p&gt;</comment>
                            <comment id="1719945" author="martin.neupauer" created="Tue, 7 Nov 2017 23:43:51 +0000"  >&lt;p&gt;It turns out it&apos;s not that easy. When I copied tailableMode in the ExpressionContext::copyWith I got a different error from the repro:&lt;/p&gt;

&lt;p&gt;2017-11-07T18:36:45.326-0500 I QUERY    &lt;span class=&quot;error&quot;&gt;&amp;#91;thread2&amp;#93;&lt;/span&gt; js thread raised js exception: JSInterpreterFailure: Error: getMore command failed: {&lt;br/&gt;
        &quot;operationTime&quot; : Timestamp(1510097805, 54),&lt;br/&gt;
        &quot;ok&quot; : 0,&lt;br/&gt;
        &quot;errmsg&quot; : &quot;error processing query: ns=change_streams.change_streams_32Tree: _id == ObjectId(&apos;5a0243868ccce3bdbd7c99ea&apos;)\nSort: {}\nProj: {}\n tailable cursor requested on non capped collection&quot;,&lt;br/&gt;
        &quot;code&quot; : 2,&lt;br/&gt;
        &quot;codeName&quot; : &quot;BadValue&quot;,&lt;br/&gt;
        &quot;$clusterTime&quot; : {&lt;br/&gt;
                &quot;clusterTime&quot; : Timestamp(1510097805, 54),&lt;br/&gt;
                &quot;signature&quot; : &lt;/p&gt;
{
                        &quot;hash&quot; : BinData(0,&quot;AAAAAAAAAAAAAAAAAAAAAAAAAAA=&quot;),
                        &quot;keyId&quot; : NumberLong(0)
                }
&lt;p&gt;        }&lt;br/&gt;
} :&lt;/p&gt;</comment>
                            <comment id="1719549" author="martin.neupauer" created="Tue, 7 Nov 2017 18:10:29 +0000"  >&lt;p&gt;And the answer turns out to be trivial. We forgot to copy tailableMode filed in the &quot;copy constructor&quot; ExpressionContext::copyWith&lt;/p&gt;</comment>
                            <comment id="1718251" author="martin.neupauer" created="Tue, 7 Nov 2017 00:24:42 +0000"  >&lt;p&gt;So the code that should ignore the timeout looks like this:&lt;/p&gt;

&lt;p&gt;if (state == PlanExecutor::IS_EOF &amp;amp;&amp;amp; pExpCtx-&amp;gt;isTailableAwaitData())&lt;/p&gt;

&lt;p&gt;and the definition of isTailableAwaitData is straightforward: return tailableMode == TailableMode::kTailableAndAwaitData;&lt;/p&gt;

&lt;p&gt;However, the current value of pExpCtx-&amp;gt;tailableMode is kNormal (0). The $64k question is why?&lt;/p&gt;</comment>
                            <comment id="1716925" author="yves.duhem" created="Fri, 3 Nov 2017 20:29:12 +0000"  >&lt;p&gt;The error still occurs after the fix for &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-31597&quot; title=&quot;Refactor $changeStream post-update lookup&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-31597&quot;&gt;&lt;del&gt;SERVER-31597&lt;/del&gt;&lt;/a&gt;. I tested with the repro script on commit &lt;a href=&quot;https://github.com/mongodb/mongo/commit/628160ab7ae0348d4ae7fe274409368a2bc3c9fb&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;628160ab7a&lt;/a&gt;. Note that it can sometimes take a few tries before seeing the error.&lt;/p&gt;</comment>
                            <comment id="1716828" author="martin.neupauer" created="Fri, 3 Nov 2017 18:56:01 +0000"  >&lt;p&gt;I&apos;ve confirmed that the test fails before &lt;a href=&quot;https://github.com/mongodb/mongo/commit/81c5724d9d11a1ff2b16937dc01e6439d9e0f266&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/81c5724d9d11a1ff2b16937dc01e6439d9e0f266&lt;/a&gt;  commit and works fine afterwards. It&apos;s a dup of &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-31597&quot; title=&quot;Refactor $changeStream post-update lookup&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-31597&quot;&gt;&lt;del&gt;SERVER-31597&lt;/del&gt;&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1716054" author="bernard.gorman" created="Thu, 2 Nov 2017 21:46:13 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=charlie.swanson&quot; class=&quot;user-hover&quot; rel=&quot;charlie.swanson&quot;&gt;charlie.swanson&lt;/a&gt;: no, that was deliberate - I figured that the &lt;tt&gt;mongoD&lt;/tt&gt; lookup would be susceptible to in-pipeline timeouts in exactly the same way as it had been on the &lt;tt&gt;mongoS&lt;/tt&gt;, so it made sense to stash the deadline before the lookup no matter what context it was running in. I didn&apos;t realise we already had this ticket for an actual incident of the timeout though - nice bonus! &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="1715995" author="charlie.swanson" created="Thu, 2 Nov 2017 21:03:47 +0000"  >&lt;p&gt;Looks like &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=bernard.gorman&quot; class=&quot;user-hover&quot; rel=&quot;bernard.gorman&quot;&gt;bernard.gorman&lt;/a&gt; (accidentally?) fixed this when he refactored the update lookup to stash the deadline within DocumentSourceLookupChangePostImage instead of within mongos&apos; implementation of the lookup: &lt;a href=&quot;https://github.com/mongodb/mongo/commit/81c5724d9d11a1ff2b16937dc01e6439d9e0f266#diff-77917bcdb3b940573a2fb1311147602eL735&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/81c5724d9d11a1ff2b16937dc01e6439d9e0f266#diff-77917bcdb3b940573a2fb1311147602eL735&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=martin.neupauer&quot; class=&quot;user-hover&quot; rel=&quot;martin.neupauer&quot;&gt;martin.neupauer&lt;/a&gt; to confirm with the reproduction script, then close out if that hypothesis is correct.&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10420">
                    <name>Backports</name>
                                            <outwardlinks description="backported by">
                                                        </outwardlinks>
                                                        </issuelinktype>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                                                <inwardlinks description="is depended on by">
                                                        </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10010">
                    <name>Duplicate</name>
                                            <outwardlinks description="duplicates">
                                        <issuelink>
            <issuekey id="446540">SERVER-31597</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                                        </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <attachments>
                            <attachment id="169047" name="change_streams_repro.js" size="6425" author="yves.duhem" created="Mon, 23 Oct 2017 20:56:08 +0000"/>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                <customfield id="customfield_10050" key="com.atlassian.jira.toolkit:comments">
                        <customfieldname># Replies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>18.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_18555" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname># of Sprints</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>4.0</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_12450" key="com.atlassian.jira.plugin.system.customfieldtypes:multicheckboxes">
                        <customfieldname>Backport Requested</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="15141"><![CDATA[v3.6]]></customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10011" key="com.atlassian.jira.plugin.system.customfieldtypes:radiobuttons">
                        <customfieldname>Backwards Compatibility</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10038"><![CDATA[Fully Compatible]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                            <customfield id="customfield_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Tue, 24 Oct 2017 12:33:58 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        6 years, 6 weeks 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_14262" key="com.atlassian.jira.plugin.system.customfieldtypes:datepicker">
                        <customfieldname>End date</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Thu, 2 Nov 2017 00:00:00 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                        <customfield id="customfield_10857" key="com.pyxis.greenhopper.jira:gh-epic-link">
                        <customfieldname>Epic Link</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>PM-876</customfieldvalue>
                        </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>
                            6 years, 6 weeks ago
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_16465" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Linked BF Score</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>0.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>bernard.gorman@mongodb.com</customfieldvalue>
            <customfieldvalue>charlie.swanson@mongodb.com</customfieldvalue>
            <customfieldvalue>david.storch@mongodb.com</customfieldvalue>
            <customfieldvalue>xgen-internal-githook</customfieldvalue>
            <customfieldvalue>james.wahlin@mongodb.com</customfieldvalue>
            <customfieldvalue>martin.neupauer@mongodb.com</customfieldvalue>
            <customfieldvalue>yves.duhem</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|htiiun:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hr9c3j:</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_23361" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Requested By</customfieldname>
                        <customfieldvalues>
                                

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_10557" key="com.pyxis.greenhopper.jira:gh-sprint">
                        <customfieldname>Sprint</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue id="1952">Query 2017-11-13</customfieldvalue>
    <customfieldvalue id="1979">Query 2017-12-04</customfieldvalue>
    <customfieldvalue id="2034">Query 2017-12-18</customfieldvalue>
    <customfieldvalue id="2076">Query 2018-01-01</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_14261" key="com.atlassian.jira.plugin.system.customfieldtypes:datepicker">
                        <customfieldname>Start date</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Mon, 23 Oct 2017 00:00:00 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10750" key="com.atlassian.jira.plugin.system.customfieldtypes:textarea">
                        <customfieldname>Steps To Reproduce</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>&lt;ol&gt;
	&lt;li&gt;start a single node replica set&lt;/li&gt;
	&lt;li&gt;cd into mongo repository&lt;/li&gt;
	&lt;li&gt;download the attached repro script: &lt;span class=&quot;nobr&quot;&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/attachment/169047/169047_change_streams_repro.js&quot; title=&quot;change_streams_repro.js attached to SERVER-31684&quot;&gt;change_streams_repro.js&lt;sup&gt;&lt;img class=&quot;rendericon&quot; src=&quot;https://jira.mongodb.org/images/icons/link_attachment_7.gif&quot; height=&quot;7&quot; width=&quot;7&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt;&lt;/sup&gt;&lt;/a&gt;&lt;/span&gt;&lt;/li&gt;
	&lt;li&gt;run the script:&lt;br/&gt;
  &lt;tt&gt;&amp;gt; mongo change_streams_repro.js&lt;/tt&gt;&lt;/li&gt;
&lt;/ol&gt;
</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>
                                

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

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