<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 08:39:15 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-2734] Reduce memory allocations in &quot;bson.Raw.String&quot; to improve logging performance</title>
                <link>https://jira.mongodb.org/browse/GODRIVER-2734</link>
                <project id="14289" key="GODRIVER">Go Driver</project>
                    <description>&lt;p&gt;There are a number of simple optimizations we can make to &lt;a href=&quot;https://github.com/mongodb/mongo-go-driver/blob/60cfd91eb66c2646de5034327c50208d13c05db3/x/bsonx/bsoncore/document.go#L265&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;bsoncore.Document.String&lt;/a&gt;, &lt;a href=&quot;https://github.com/mongodb/mongo-go-driver/blob/60cfd91eb66c2646de5034327c50208d13c05db3/x/bsonx/bsoncore/array.go#L84&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;bsoncore.Array.String&lt;/a&gt;, and &lt;a href=&quot;https://github.com/mongodb/mongo-go-driver/blob/60cfd91eb66c2646de5034327c50208d13c05db3/x/bsonx/bsoncore/element.go#L118&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;bsoncore.Element.String&lt;/a&gt; that can significantly reduce allocations. Historically those haven&apos;t been a major concern, but the logging implementation (&lt;a href=&quot;https://jira.mongodb.org/browse/GODRIVER-1712&quot; title=&quot;Easier debugging with standardized logging&quot; class=&quot;issue-link&quot; data-issue-key=&quot;GODRIVER-1712&quot;&gt;&lt;del&gt;GODRIVER-1712&lt;/del&gt;&lt;/a&gt;) for command logging relies heavily on the &lt;tt&gt;bson.Raw.String&lt;/tt&gt; function.&lt;/p&gt;

&lt;p&gt;Definition of done:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;Replace all uses of &lt;tt&gt;bytes.Buffer&lt;/tt&gt; with &lt;tt&gt;strings.Builder&lt;/tt&gt; in &lt;tt&gt;bsoncore&lt;/tt&gt; where the function output is a &lt;tt&gt;string&lt;/tt&gt;.&lt;/li&gt;
	&lt;li&gt;Remove all uses of &lt;tt&gt;fmt.Fprintf&lt;/tt&gt; and &lt;tt&gt;fmt.Sprintf&lt;/tt&gt; where there is little or no string formatting added.&lt;/li&gt;
	&lt;li&gt;Add a benchmark that exercises &lt;tt&gt;bson.Raw.String&lt;/tt&gt; for various inputs.&lt;/li&gt;
&lt;/ul&gt;
</description>
                <environment></environment>
        <key id="2235630">GODRIVER-2734</key>
            <summary>Reduce memory allocations in &quot;bson.Raw.String&quot; to improve logging performance</summary>
                <type id="4" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14710&amp;avatarType=issuetype">Improvement</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="matt.dale@mongodb.com">Matt Dale</assignee>
                                    <reporter username="matt.dale@mongodb.com">Matt Dale</reporter>
                        <labels>
                    </labels>
                <created>Wed, 18 Jan 2023 02:31:13 +0000</created>
                <updated>Sat, 28 Oct 2023 11:37:22 +0000</updated>
                            <resolved>Fri, 20 Jan 2023 18:20:06 +0000</resolved>
                                                    <fixVersion>1.12.0</fixVersion>
                    <fixVersion>1.12.0-alpha1</fixVersion>
                                    <component>BSON</component>
                    <component>Logging</component>
                                        <votes>0</votes>
                                    <watches>1</watches>
                                                                                                                <comments>
                            <comment id="5127697" author="xgen-internal-githook" created="Fri, 20 Jan 2023 18:17:59 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Matt Dale&apos;, &apos;email&apos;: &apos;9760375+matthewdale@users.noreply.github.com&apos;, &apos;username&apos;: &apos;matthewdale&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/GODRIVER-2734&quot; title=&quot;Reduce memory allocations in &amp;quot;bson.Raw.String&amp;quot; to improve logging performance&quot; class=&quot;issue-link&quot; data-issue-key=&quot;GODRIVER-2734&quot;&gt;&lt;del&gt;GODRIVER-2734&lt;/del&gt;&lt;/a&gt; Benchmark and reduce allocations in bson.Raw.String (#1160)&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-go-driver/commit/de9108a5c0d9f3bfc51c6f654ecb406d274885c0&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-go-driver/commit/de9108a5c0d9f3bfc51c6f654ecb406d274885c0&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="5119537" author="JIRAUSER1259527" created="Wed, 18 Jan 2023 02:48:08 +0000"  >&lt;p&gt;PR: &lt;a href=&quot;https://github.com/mongodb/mongo-go-driver/pull/1160&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-go-driver/pull/1160&lt;/a&gt;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                                                <inwardlinks description="is related to">
                                        <issuelink>
            <issuekey id="1438134">GODRIVER-1712</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|i19k0g:</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>