<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Wed Feb 07 22:00: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>[CXX-940] Default constructed bsoncxx::oid object is dangerous</title>
                <link>https://jira.mongodb.org/browse/CXX-940</link>
                <project id="11980" key="CXX">C++ Driver</project>
                    <description>&lt;p&gt;See &lt;a href=&quot;https://groups.google.com/forum/?utm_medium=email&amp;amp;utm_source=footer#!msg/mongodb-user/25T40eHhAMg/xIgyOoUVCQAJ&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://groups.google.com/forum/?utm_medium=email&amp;amp;utm_source=footer#!msg/mongodb-user/25T40eHhAMg/xIgyOoUVCQAJ&lt;/a&gt;&lt;/p&gt;</description>
                <environment></environment>
        <key id="295008">CXX-940</key>
            <summary>Default constructed bsoncxx::oid object is dangerous</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="9">Done</resolution>
                                        <assignee username="backlog-cxx-driver">Backlog - CXX Driver Team</assignee>
                                    <reporter username="andrew.morrow@mongodb.com">Andrew Morrow</reporter>
                        <labels>
                    </labels>
                <created>Sun, 19 Jun 2016 15:19:09 +0000</created>
                <updated>Mon, 19 Sep 2016 20:24:20 +0000</updated>
                            <resolved>Fri, 15 Jul 2016 18:02:49 +0000</resolved>
                                                    <fixVersion>3.0.2</fixVersion>
                                    <component>API</component>
                                        <votes>0</votes>
                                    <watches>3</watches>
                                                                                                                <comments>
                            <comment id="1325598" author="xgen-internal-githook" created="Fri, 15 Jul 2016 18:00:25 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;username&apos;: u&apos;adamchel&apos;, u&apos;name&apos;: u&apos;Adam Chelminski&apos;, u&apos;email&apos;: u&apos;adam.chelminski@mongodb.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/CXX-940&quot; title=&quot;Default constructed bsoncxx::oid object is dangerous&quot; class=&quot;issue-link&quot; data-issue-key=&quot;CXX-940&quot;&gt;&lt;del&gt;CXX-940&lt;/del&gt;&lt;/a&gt; Deprecate bsoncxx::oid::init_tag and make bsoncxx::oid&apos;s default constructor do full OID initialization&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-cxx-driver/commit/c25e50b8b9353595d3f01bf9bb07d81a59416b8f&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-cxx-driver/commit/c25e50b8b9353595d3f01bf9bb07d81a59416b8f&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1323357" author="acm" created="Wed, 13 Jul 2016 21:56:49 +0000"  >&lt;p&gt;Code review: &lt;a href=&quot;https://github.com/mongodb/mongo-cxx-driver/pull/506&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-cxx-driver/pull/506&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1303504" author="alb@neptunesystems.com" created="Wed, 22 Jun 2016 21:23:03 +0000"  >&lt;p&gt;With reference to the linked discussion, IMO an all-zero OID seems unnecessary given the plethora of better alternatives available; in general magic sentinel values tends to be something that one quickly regrets having gone with.&lt;/p&gt;

&lt;p&gt;I think that the most common use case for expressly declaring an OID is that one, well, wants an OID, and it seems reasonable in that case to have it default-constructed to a usable state; I think to do otherwise is unexpected.&lt;/p&gt;

&lt;p&gt;The optional approach in order to avoid the cost of such construction is certainly nice to have, but I suppose that I&apos;d be surprised in the first place to find the cost to be non-trivial.&lt;/p&gt;</comment>
                            <comment id="1302852" author="acm" created="Wed, 22 Jun 2016 15:40:53 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=alb&quot; class=&quot;user-hover&quot; rel=&quot;alb&quot;&gt;alb&lt;/a&gt; - We would also be interested in feedback on this issue. Please see the linked group discussion. We are considering removing the bsoncxx::oid::init_tag and making the class default constructible with the semantics of doing full OID initialization. The idea is that users needing to defer that cost could use bsoncxx::stdx::optional&amp;lt;bsoncxx::oid&amp;gt;.&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                                        </outwardlinks>
                                                        </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_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hrdt7z:</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="1065">Platforms 17 (07/15/16)</customfieldvalue>

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