<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Wed Feb 07 21:14:47 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>[CDRIVER-2290] OPMsg size for a Document Sequence is encoded as native endianness</title>
                <link>https://jira.mongodb.org/browse/CDRIVER-2290</link>
                <project id="10030" key="CDRIVER">C Driver</project>
                    <description>&lt;p&gt;Currently, when the C driver writes the length of a document sequence payload in an OpMsg, it writes the length as native-endian instead of little-endian.&lt;/p&gt;

&lt;p&gt;Here is the problematic line:&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-c-driver/blob/e86e19589294b348ef8e7c547d65babb42fb089b/src/mongoc/mongoc-rpc.c#L116&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-c-driver/blob/e86e19589294b348ef8e7c547d65babb42fb089b/src/mongoc/mongoc-rpc.c#L116&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Support for document sequences was added in the change below, and did the endian encoding correctly:&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-c-driver/commit/c2073231209f20f5eef7263e969ae69ed47a031e&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-c-driver/commit/c2073231209f20f5eef7263e969ae69ed47a031e&lt;/a&gt;&lt;br/&gt;
A regression in behavior was added in this change&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-c-driver/commit/0f12b9d2782feef0418894bcd0134c89e21a5b5e&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-c-driver/commit/0f12b9d2782feef0418894bcd0134c89e21a5b5e&lt;/a&gt;&lt;/p&gt;</description>
                <environment></environment>
        <key id="428746">CDRIVER-2290</key>
            <summary>OPMsg size for a Document Sequence is encoded as native endianness</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="jesse@mongodb.com">A. Jesse Jiryu Davis</assignee>
                                    <reporter username="mark.benvenuto@mongodb.com">Mark Benvenuto</reporter>
                        <labels>
                    </labels>
                <created>Mon, 18 Sep 2017 14:46:33 +0000</created>
                <updated>Sat, 28 Oct 2023 11:30:27 +0000</updated>
                            <resolved>Fri, 20 Oct 2017 08:46:51 +0000</resolved>
                                                    <fixVersion>1.9.0</fixVersion>
                                                        <votes>0</votes>
                                    <watches>4</watches>
                                                                                                                <comments>
                            <comment id="1704498" author="jesse" created="Fri, 20 Oct 2017 08:47:54 +0000"  >&lt;p&gt;It &lt;b&gt;is&lt;/b&gt; fixed, but BUILD-3865 had me confused.&lt;/p&gt;</comment>
                            <comment id="1699452" author="jesse" created="Mon, 16 Oct 2017 09:29:02 +0000"  >&lt;p&gt;I thought I fixed this, I was tricked by a display quirk of Evergreen. I haven&apos;t fixed it completely.&lt;/p&gt;</comment>
                            <comment id="1699012" author="xgen-internal-githook" created="Sat, 14 Oct 2017 13:31:22 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;email&apos;: &apos;jesse@mongodb.com&apos;, &apos;name&apos;: &apos;A. Jesse Jiryu Davis&apos;, &apos;username&apos;: &apos;ajdavis&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/CDRIVER-2290&quot; title=&quot;OPMsg size for a Document Sequence is encoded as native endianness&quot; class=&quot;issue-link&quot; data-issue-key=&quot;CDRIVER-2290&quot;&gt;&lt;del&gt;CDRIVER-2290&lt;/del&gt;&lt;/a&gt; OP_MSG payload type 1, big-endian fix&lt;/p&gt;

&lt;p&gt;Don&apos;t overwrite payload.sequence.size with a little-endian int32. That&lt;br/&gt;
size is used later in calculations which are wrong on big-endian boxes.&lt;br/&gt;
Instead, write the little-endian number to a separate field.&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-c-driver/commit/42d8a658f4e9178ce76a9af60fbfcc7b0c1aa041&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-c-driver/commit/42d8a658f4e9178ce76a9af60fbfcc7b0c1aa041&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1675589" author="bjori" created="Mon, 18 Sep 2017 17:09:43 +0000"  >&lt;p&gt;wow. Hot diddily doo! Than you so much for thorough debugging &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=mark.benvenuto&quot; class=&quot;user-hover&quot; rel=&quot;mark.benvenuto&quot;&gt;mark.benvenuto&lt;/a&gt; !&lt;/p&gt;

&lt;p&gt;That payload length is indeed being written in native endian rather the little endian&lt;/p&gt;</comment>
                            <comment id="1675432" author="jesse" created="Mon, 18 Sep 2017 15:10:31 +0000"  >&lt;p&gt;Beautiful, thanks Mark.&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                                                <inwardlinks description="is related to">
                                        <issuelink>
            <issuekey id="426489">SERVER-31052</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_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|ht6vdb:</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>