<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 04:29: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-32308] Add the ability for a $lookup stage to execute on mongos against a sharded foreign collection</title>
                <link>https://jira.mongodb.org/browse/SERVER-32308</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;In order to support &lt;tt&gt;$changeStreams&lt;/tt&gt; &quot;updateLookup&quot; functionality (&lt;a href=&quot;https://docs.mongodb.com/manual/tutorial/change-streams-example/#lookup-full-document-for-update-operations&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;see the documentation here&lt;/a&gt;), the aggregation subsystem now has machinery for $lookup-like query execution on mongos.&lt;/p&gt;

&lt;p&gt;We should extend this functionality to work for the &lt;tt&gt;$lookup&lt;/tt&gt; stage itself:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;When the foreign collection is sharded, split the pipeline such that the &lt;tt&gt;$lookup&lt;/tt&gt; is part of the merging pipeline. Execute the merging pipeline on mongos, performing lookups across the network to the shards as needed.&lt;/li&gt;
	&lt;li&gt;If the foreign collection is not sharded, send the merging part of the pipeline to the primary shard and perform local lookups, just as we do in all existing versions of MongoDB.&lt;/li&gt;
	&lt;li&gt;If the merging part of the pipeline containing the &lt;tt&gt;$lookup&lt;/tt&gt; cannot execute on mongos, raise an error to the application.&lt;/li&gt;
	&lt;li&gt;Support only &lt;tt&gt;localField&lt;/tt&gt;/&lt;tt&gt;foreignField&lt;/tt&gt; &lt;tt&gt;$lookup&lt;/tt&gt; for now; adding support for &lt;tt&gt;$lookup&lt;/tt&gt; with a sub-pipeline into a sharded foreign collection is future work.&lt;/li&gt;
&lt;/ul&gt;
</description>
                <environment></environment>
        <key id="471792">SERVER-32308</key>
            <summary>Add the ability for a $lookup stage to execute on mongos against a sharded foreign collection</summary>
                <type id="2" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14711&amp;avatarType=issuetype">New Feature</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="james.wahlin@mongodb.com">James Wahlin</assignee>
                                    <reporter username="david.storch@mongodb.com">David Storch</reporter>
                        <labels>
                    </labels>
                <created>Wed, 13 Dec 2017 19:33:32 +0000</created>
                <updated>Mon, 30 Oct 2023 23:09:57 +0000</updated>
                            <resolved>Fri, 14 Dec 2018 17:09:35 +0000</resolved>
                                                    <fixVersion>4.1.7</fixVersion>
                                    <component>Aggregation Framework</component>
                    <component>Querying</component>
                                        <votes>4</votes>
                                    <watches>9</watches>
                                                                                                                <comments>
                            <comment id="2091121" author="xgen-internal-githook" created="Fri, 14 Dec 2018 17:09:18 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;username&apos;: &apos;jameswahlin&apos;, &apos;email&apos;: &apos;james@mongodb.com&apos;, &apos;name&apos;: &apos;James Wahlin&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-32308&quot; title=&quot;Add the ability for a $lookup stage to execute on mongos against a sharded foreign collection&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-32308&quot;&gt;&lt;del&gt;SERVER-32308&lt;/del&gt;&lt;/a&gt; Address ASAN failure due to leaked Pipeline in attachCursorSourceToPipeline&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/7416ce3c3e6e1a84d8ccc111bf1cd3895bada6f3&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/7416ce3c3e6e1a84d8ccc111bf1cd3895bada6f3&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="2090910" author="james.wahlin@10gen.com" created="Fri, 14 Dec 2018 14:50:41 +0000"  >&lt;p&gt;Reopening to address memory leak when an exception is thrown in attachCursorSourceToPipeline().&lt;/p&gt;</comment>
                            <comment id="2089171" author="xgen-internal-githook" created="Thu, 13 Dec 2018 00:25:53 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Benety Goh&apos;, &apos;email&apos;: &apos;benety@mongodb.com&apos;, &apos;username&apos;: &apos;benety&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-32308&quot; title=&quot;Add the ability for a $lookup stage to execute on mongos against a sharded foreign collection&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-32308&quot;&gt;&lt;del&gt;SERVER-32308&lt;/del&gt;&lt;/a&gt; remove unused variable&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/6b0e401683ad1bc3938a1111a95750fce96e2d72&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/6b0e401683ad1bc3938a1111a95750fce96e2d72&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="2089093" author="james.wahlin@10gen.com" created="Wed, 12 Dec 2018 22:41:57 +0000"  >&lt;p&gt;Reopening to address&#160;BF-11527, a compile_all failure on the &quot;* Enterprise Windows 2008R2 compile_all&quot; and &quot;* Windows 2008R2 DEBUG&quot; due to an unused variable in&#160;document_source_lookup_change_post_image_test.cpp.&lt;/p&gt;</comment>
                            <comment id="2088852" author="xgen-internal-githook" created="Wed, 12 Dec 2018 19:51:04 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;James Wahlin&apos;, &apos;email&apos;: &apos;james@mongodb.com&apos;, &apos;username&apos;: &apos;jameswahlin&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-32308&quot; title=&quot;Add the ability for a $lookup stage to execute on mongos against a sharded foreign collection&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-32308&quot;&gt;&lt;del&gt;SERVER-32308&lt;/del&gt;&lt;/a&gt; Support for $lookup to execute on mongos against a sharded foreign collection&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/056d61676f91f6da0a030347ae4b92255d752d8f&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/056d61676f91f6da0a030347ae4b92255d752d8f&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1775517" author="nicholas.zolnierz" created="Tue, 16 Jan 2018 19:28:35 +0000"  >&lt;p&gt;Re-opening this ticket as we&apos;re currently re-evaluating the priority of the sharded $lookup project.&lt;/p&gt;</comment>
                            <comment id="1775505" author="xgen-internal-githook" created="Tue, 16 Jan 2018 19:22:30 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;email&apos;: &apos;nicholas.zolnierz@mongodb.com&apos;, &apos;name&apos;: &apos;Nick Zolnierz&apos;, &apos;username&apos;: &apos;nzolnierzmdb&apos;}
&lt;p&gt;Message: Revert &quot;&lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-32308&quot; title=&quot;Add the ability for a $lookup stage to execute on mongos against a sharded foreign collection&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-32308&quot;&gt;&lt;del&gt;SERVER-32308&lt;/del&gt;&lt;/a&gt;: Add the ability for a $lookup stage to execute on mongos against a sharded foreign collection&quot;&lt;/p&gt;

&lt;p&gt;This reverts commit 7298d273c0497f2720ec1471ad0f4910bff07af4.&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/4eabf1ea6225f444b3b0b3b2fee785aaa306212f&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/4eabf1ea6225f444b3b0b3b2fee785aaa306212f&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1773047" author="xgen-internal-githook" created="Fri, 12 Jan 2018 18:02:32 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;email&apos;: &apos;nicholas.zolnierz@mongodb.com&apos;, &apos;name&apos;: &apos;Nick Zolnierz&apos;, &apos;username&apos;: &apos;nzolnierzmdb&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-32308&quot; title=&quot;Add the ability for a $lookup stage to execute on mongos against a sharded foreign collection&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-32308&quot;&gt;&lt;del&gt;SERVER-32308&lt;/del&gt;&lt;/a&gt;: Add the ability for a $lookup stage to execute on mongos against a sharded foreign collection&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/7298d273c0497f2720ec1471ad0f4910bff07af4&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/7298d273c0497f2720ec1471ad0f4910bff07af4&lt;/a&gt;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                                                <inwardlinks description="is depended on by">
                                        <issuelink>
            <issuekey id="658989">SERVER-38728</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="471794">SERVER-32309</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="481814">SERVER-32666</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="679189">SERVER-39238</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10320">
                    <name>Documented</name>
                                                                <inwardlinks description="is documented by">
                                        <issuelink>
            <issuekey id="653057">DOCS-12271</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>8.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_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>Wed, 3 Jan 2018 17:33:36 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        5 years, 8 weeks, 5 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_10857" key="com.pyxis.greenhopper.jira:gh-epic-link">
                        <customfieldname>Epic Link</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>PM-282</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>
                            5 years, 8 weeks, 5 days ago
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_16465" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Linked BF Score</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>100.0</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>david.storch@mongodb.com</customfieldvalue>
            <customfieldvalue>xgen-internal-githook</customfieldvalue>
            <customfieldvalue>james.wahlin@mongodb.com</customfieldvalue>
            <customfieldvalue>nicholas.zolnierz@mongodb.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|htm5tj:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hr8ejr:</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="2076">Query 2018-01-01</customfieldvalue>
    <customfieldvalue id="2077">Query 2018-01-15</customfieldvalue>
    <customfieldvalue id="2572">Query 2018-12-17</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|htlrxr:</customfieldvalue>

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