<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 09:01:37 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>[JAVA-4258] Aggregation helper fails on simplified string form for $merge stage</title>
                <link>https://jira.mongodb.org/browse/JAVA-4258</link>
                <project id="10006" key="JAVA">Java Driver</project>
                    <description>&lt;p&gt;Originally reported in &lt;a href=&quot;https://github.com/spring-projects/spring-data-mongodb/issues/3743&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;spring-data-mongodb#3743&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;In &lt;tt&gt;AggregateIterableImpl.getOutNamespace&lt;/tt&gt; method&lt;br/&gt;
 &lt;tt&gt;BsonDocument mergeDocument = lastStageDocument.getDocument(&quot;$merge&quot;)&lt;/tt&gt;&lt;br/&gt;
 this line does not consider simple &lt;tt&gt;String&lt;/tt&gt; type when &lt;tt&gt;$merge&lt;/tt&gt; use the simplified form, like {&lt;tt&gt;$merge: &amp;lt;collection&amp;gt;&lt;/tt&gt;}&lt;/p&gt;

&lt;p&gt;The workaround is to use the long form of &lt;tt&gt;$merge&lt;/tt&gt;, as documented&#160;&lt;a href=&quot;https://docs.mongodb.com/manual/reference/operator/aggregation/merge/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;here&lt;/a&gt;.&lt;/p&gt;</description>
                <environment></environment>
        <key id="1829151">JAVA-4258</key>
            <summary>Aggregation helper fails on simplified string form for $merge stage</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="jeff.yemin@mongodb.com">Jeffrey Yemin</assignee>
                                    <reporter username="cstrobl">Christoph Strobl</reporter>
                        <labels>
                            <label>external-user</label>
                    </labels>
                <created>Fri, 23 Jul 2021 07:29:41 +0000</created>
                <updated>Sat, 28 Oct 2023 11:21:06 +0000</updated>
                            <resolved>Sun, 1 Aug 2021 14:58:22 +0000</resolved>
                                                    <fixVersion>4.3.1</fixVersion>
                    <fixVersion>3.12.10</fixVersion>
                                    <component>Write Operations</component>
                                        <votes>0</votes>
                                    <watches>2</watches>
                                                                                                                <comments>
                            <comment id="3970752" author="xgen-internal-githook" created="Thu, 29 Jul 2021 15:29:10 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Jeff Yemin&apos;, &apos;email&apos;: &apos;jeff.yemin@mongodb.com&apos;, &apos;username&apos;: &apos;jyemin&apos;}
&lt;p&gt;Message: Support aggregation with $merge as a string (#768)&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-4258&quot; title=&quot;Aggregation helper fails on simplified string form for $merge stage&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-4258&quot;&gt;&lt;del&gt;JAVA-4258&lt;/del&gt;&lt;/a&gt;&lt;br/&gt;
Branch: 3.12.x&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/2a32ac3a7c2c277c7406bb83024df0af13b50008&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/2a32ac3a7c2c277c7406bb83024df0af13b50008&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="3970370" author="xgen-internal-githook" created="Thu, 29 Jul 2021 13:44:21 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Jeff Yemin&apos;, &apos;email&apos;: &apos;jeff.yemin@mongodb.com&apos;, &apos;username&apos;: &apos;jyemin&apos;}
&lt;p&gt;Message: Support aggregation with $merge as a string (#768)&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-4258&quot; title=&quot;Aggregation helper fails on simplified string form for $merge stage&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-4258&quot;&gt;&lt;del&gt;JAVA-4258&lt;/del&gt;&lt;/a&gt;&lt;br/&gt;
Branch: 4.3.x&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/05fdd7e941d42d19de361758d0a012414c5dba32&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/05fdd7e941d42d19de361758d0a012414c5dba32&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="3970222" author="xgen-internal-githook" created="Thu, 29 Jul 2021 12:38:41 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Jeff Yemin&apos;, &apos;email&apos;: &apos;jeff.yemin@mongodb.com&apos;, &apos;username&apos;: &apos;jyemin&apos;}
&lt;p&gt;Message: Support aggregation with $merge as a string (#768)&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-4258&quot; title=&quot;Aggregation helper fails on simplified string form for $merge stage&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-4258&quot;&gt;&lt;del&gt;JAVA-4258&lt;/del&gt;&lt;/a&gt;&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/7d1eabbd631e62e3da7e71080d7d893066443228&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/7d1eabbd631e62e3da7e71080d7d893066443228&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="3959426" author="jeff.yemin" created="Fri, 23 Jul 2021 11:39:35 +0000"  >&lt;p&gt;Thanks for opening this case, &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=cstrobl&quot; class=&quot;user-hover&quot; rel=&quot;cstrobl&quot;&gt;cstrobl&lt;/a&gt;.  I agree it&apos;s a bug.  We missed the fact that there is a simplified form of &lt;tt&gt;$merge&lt;/tt&gt;.   &lt;/p&gt;</comment>
                    </comments>
                    <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_15850" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10257" key="com.atlassian.jira.plugin.system.customfieldtypes:radiobuttons">
                        <customfieldname>Documentation Changes</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="11861"><![CDATA[Not Needed]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hr6tlz:</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>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            </customfields>
    </item>
</channel>
</rss>