<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 08:39:35 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>[GODRIVER-2889] Create aggregation pipeline helpers</title>
                <link>https://jira.mongodb.org/browse/GODRIVER-2889</link>
                <project id="14289" key="GODRIVER">Go Driver</project>
                    <description>&lt;p&gt;Defining aggregation pipelines using the Go driver can be a bad experience. The &lt;tt&gt;bson.D&lt;/tt&gt; type (which is frequently used to define agg pipelines) does not provide compile-time safety for types used in aggregation pipelines and the syntax becomes difficult to read quickly as aggregation pipelines become more complex.&lt;/p&gt;

&lt;p&gt;Some other drivers, such as Java and .NET, provide helper functions that add a convenience (and sometimes type-safety) layer on top of the aggregation pipeline syntax, significantly improving the developer experience of using aggregation pipelines. Creating helper functions in the Go driver would provide a similar improvement in the experience of using aggregation pipelines in Go.&lt;/p&gt;

&lt;p&gt;Creating a comprehensive set of aggregation pipeline helpers is a very large task, so to help improve the experience for the majority of users faster, we should target creating helpers for the most popular aggregation pipelines. The helpers need to be able to interoperate with existing &lt;tt&gt;bson.D&lt;/tt&gt; pipeline declaration logic so that users have the option to use a mixture of pipeline stages defined with the helpers and with &lt;tt&gt;bson.D&lt;/tt&gt;.&lt;/p&gt;

&lt;p&gt;Definition of done:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;Create a set of aggregation pipeline helpers that output aggregation pipeline stages.
	&lt;ul&gt;
		&lt;li&gt;Consider using the &lt;a href=&quot;https://www.mongodb.com/docs/drivers/java/sync/current/fundamentals/builders/aggregates/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;Java driver aggregation builder&lt;/a&gt; as reference.&lt;/li&gt;
	&lt;/ul&gt;
	&lt;/li&gt;
	&lt;li&gt;The helper must be able to be combined with other aggregation pipeline stages defined as &lt;tt&gt;bson.D&lt;/tt&gt; or &lt;tt&gt;bson.M&lt;/tt&gt; (i.e. allow incrementally replacing pipeline stages defined with &lt;tt&gt;bson.D&lt;/tt&gt;/&lt;tt&gt;bson.M&lt;/tt&gt; with helper calls without replacing the entire pipeline).&lt;/li&gt;
	&lt;li&gt;Update all documentation to use the aggregation pipeline helpers instead of &lt;tt&gt;bson.D&lt;/tt&gt;/&lt;tt&gt;bson.M&lt;/tt&gt; where possible.&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;Open questions:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;Should we create a new package (e.g. &lt;tt&gt;aggregate.Match&lt;/tt&gt;), a new type (e.g. &lt;tt&gt;mongo.Aggregate().Match&lt;/tt&gt;), or something else?&lt;/li&gt;
	&lt;li&gt;Should the helper output &lt;tt&gt;bson.D&lt;/tt&gt; or another type? It must be possible to mix helper output with other pipeline stages defined using &lt;tt&gt;bson.D&lt;/tt&gt;/&lt;tt&gt;bson.M&lt;/tt&gt;.&lt;/li&gt;
&lt;/ul&gt;

</description>
                <environment></environment>
        <key id="2383050">GODRIVER-2889</key>
            <summary>Create aggregation pipeline helpers</summary>
                <type id="4" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14710&amp;avatarType=issuetype">Improvement</type>
                                            <priority id="10300" iconUrl="https://jira.mongodb.org/images/icons/priorities/medium.svg">Unknown</priority>
                        <status id="10038" iconUrl="https://jira.mongodb.org/images/icons/subtask.gif" description="">Backlog</status>
                    <statusCategory id="2" key="new" colorName="default"/>
                                    <resolution id="-1">Unresolved</resolution>
                                        <assignee username="-1">Unassigned</assignee>
                                    <reporter username="matt.dale@mongodb.com">Matt Dale</reporter>
                        <labels>
                    </labels>
                <created>Tue, 4 Jul 2023 01:46:13 +0000</created>
                <updated>Wed, 11 Oct 2023 21:54:54 +0000</updated>
                                                                            <component>Aggregation</component>
                                        <votes>0</votes>
                                    <watches>1</watches>
                                                                                                                <comments>
                            <comment id="5556133" author="JIRAUSER1259527" created="Mon, 10 Jul 2023 23:41:30 +0000"  >&lt;p&gt;Additional examples:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;Python MongoDB aggregation helpers: &lt;a href=&quot;https://github.com/mongodb-labs/PyMongoAgg&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb-labs/PyMongoAgg&lt;/a&gt;&lt;/li&gt;
	&lt;li&gt;Java MongoDB &lt;tt&gt;Aggregates&lt;/tt&gt; builders: &lt;a href=&quot;https://www.mongodb.com/docs/drivers/java/sync/current/fundamentals/builders/aggregates/#std-label-aggregates-builders&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://www.mongodb.com/docs/drivers/java/sync/current/fundamentals/builders/aggregates/#std-label-aggregates-builders&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="2472091">GODRIVER-3012</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1961560">GODRIVER-2271</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is related to">
                                        <issuelink>
            <issuekey id="2069890">GODRIVER-2459</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                    </issuelinks>
                <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_14266" key="com.atlassian.jira.plugin.system.customfieldtypes:textarea">
                        <customfieldname>Documentation Changes Summary</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>&lt;p&gt;1.  What would you like to communicate to the user about this feature?&lt;br/&gt;
2.  Would you like the user to see examples of the syntax and/or executable code and its output?&lt;br/&gt;
3.  Which versions of the driver/connector does this apply to?&lt;/p&gt;</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_21553" key="com.atlassian.jira.plugin.system.customfieldtypes:labels">
                        <customfieldname>Quarter</customfieldname>
                        <customfieldvalues>
                                        <label>FY24Q3</label>
    
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|i1ykhc:</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>