<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 08:51:42 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-194] Improved Performance of BSONDecoder</title>
                <link>https://jira.mongodb.org/browse/JAVA-194</link>
                <project id="10006" key="JAVA">Java Driver</project>
                    <description>&lt;p&gt;Hi,&lt;/p&gt;

&lt;p&gt;my commit&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;http://github.com/theunique/mongo-java-driver/commit/8b0ca1ba9f53285b5a3084e233b116d9228bc277&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://github.com/theunique/mongo-java-driver/commit/8b0ca1ba9f53285b5a3084e233b116d9228bc277&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;contains a path to improve performance of BSONDecoder. Due to thread&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;http://groups.google.com/group/mongodb-dev/browse_thread/thread/74fa538f4281a2be&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://groups.google.com/group/mongodb-dev/browse_thread/thread/74fa538f4281a2be&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;the improvement is up to 40%&lt;/p&gt;

&lt;p&gt;ciao.hans.&lt;/p&gt;



</description>
                <environment></environment>
        <key id="13446">JAVA-194</key>
            <summary>Improved Performance of BSONDecoder</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="9">Done</resolution>
                                        <assignee username="-1">Unassigned</assignee>
                                    <reporter username="hmeiser">Hans Meiser</reporter>
                        <labels>
                    </labels>
                <created>Thu, 21 Oct 2010 12:00:30 +0000</created>
                <updated>Tue, 25 Jun 2013 04:33:15 +0000</updated>
                            <resolved>Tue, 25 Jun 2013 04:33:15 +0000</resolved>
                                    <version>2.2</version>
                                                    <component>Performance</component>
                                        <votes>5</votes>
                                    <watches>7</watches>
                                                                                                                <comments>
                            <comment id="367016" author="jeff.yemin" created="Tue, 25 Jun 2013 04:33:15 +0000"  >&lt;p&gt;The BSON decoder has been re-written several times since this was opened.  Please open a new issue if you are still seeing problems in the latest driver.&lt;/p&gt;</comment>
                            <comment id="26075" author="lpouzac" created="Thu, 17 Mar 2011 10:06:36 +0000"  >&lt;p&gt;Hi, &lt;/p&gt;

&lt;p&gt;When will this correction is expected? 2.6?&lt;/p&gt;</comment>
                            <comment id="21600" author="eliot" created="Mon, 20 Dec 2010 16:20:23 +0000"  >&lt;p&gt;We&apos;ve made a number of the changes for 2.4, but there are still more which is why i haven&apos;t moved this case.&lt;/p&gt;</comment>
                            <comment id="21599" author="jeff_y" created="Mon, 20 Dec 2010 12:14:47 +0000"  >&lt;p&gt;Is this now for 2.4, or is it still unscheduled?&lt;/p&gt;</comment>
                            <comment id="21366" author="eliot" created="Mon, 13 Dec 2010 15:05:16 +0000"  >&lt;p&gt;Correct&lt;/p&gt;</comment>
                            <comment id="21359" author="hmeiser" created="Mon, 13 Dec 2010 08:15:31 +0000"  >&lt;p&gt;&apos;master&apos; is your current version in github?&lt;/p&gt;</comment>
                            <comment id="21223" author="eliot" created="Thu, 9 Dec 2010 12:23:43 +0000"  >&lt;p&gt;A lot of the changes are in 2.4&lt;br/&gt;
A number of edge cases had to be tweaked, but can you test master vs 2.3?&lt;/p&gt;</comment>
                            <comment id="21216" author="hmeiser" created="Thu, 9 Dec 2010 07:27:21 +0000"  >&lt;p&gt;Any news on that issue?&lt;/p&gt;</comment>
                            <comment id="19479" author="eliot" created="Fri, 22 Oct 2010 12:37:16 +0000"  >&lt;p&gt;Stil want to try to see what&apos;s actually making the difference.&lt;br/&gt;
IN my profiling, I think the big differences is reading -&amp;gt; bytes vs. readingto char.&lt;br/&gt;
going to try merge something like that in.&lt;/p&gt;</comment>
                            <comment id="19477" author="hmeiser" created="Fri, 22 Oct 2010 07:53:37 +0000"  >&lt;p&gt;My BSONDecoder didn&apos;t support surrogates. Now it does. &lt;br/&gt;
BSONDecoder now does a simple caching of short strings (inspired by your one-byte-strings)&lt;/p&gt;

&lt;p&gt;I also removed my previous commit and committed a new version without formatting it.&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;http://github.com/theunique/mongo-java-driver/commit/ab29686a2f152556bf2d46f8506bfd216597444e&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://github.com/theunique/mongo-java-driver/commit/ab29686a2f152556bf2d46f8506bfd216597444e&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="19444" author="hmeiser" created="Thu, 21 Oct 2010 15:57:55 +0000"  >&lt;p&gt;I have a version without formatting it with the eclipse formatter from your github. Would that help?&lt;/p&gt;</comment>
                            <comment id="19443" author="hmeiser" created="Thu, 21 Oct 2010 15:56:46 +0000"  >&lt;p&gt;Some of the performance improvements came from utf-8 but the improvements come from readahead. For example no allocation of byte&lt;span class=&quot;error&quot;&gt;&amp;#91;4&amp;#93;&lt;/span&gt; for reading simple int.&lt;br/&gt;
And most come from tied inner loop.&lt;/p&gt;

&lt;p&gt;Sorry, I previously had a fork with all the commits and erased it to give you one commit to simplify pull request &lt;img class=&quot;emoticon&quot; src=&quot;https://jira.mongodb.org/images/icons/emoticons/sad.png&quot; height=&quot;16&quot; width=&quot;16&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt;&lt;/p&gt;

&lt;p&gt;PS: Your isAscii is faster if you do &lt;/p&gt;

&lt;p&gt;isAscii = 0&lt;br/&gt;
...&lt;br/&gt;
while()&lt;br/&gt;
{&lt;br/&gt;
b = ...&lt;br/&gt;
isAscii |= b;&lt;br/&gt;
...&lt;br/&gt;
}&lt;/p&gt;

&lt;p&gt;if(isAscii&amp;amp;0x80!=0)&lt;br/&gt;
{&lt;br/&gt;
no&lt;br/&gt;
}&lt;br/&gt;
else&lt;br/&gt;
{&lt;br/&gt;
ascii&lt;br/&gt;
}&lt;/p&gt;
</comment>
                            <comment id="19436" author="auto" created="Thu, 21 Oct 2010 13:05:35 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;login&apos;: &apos;erh&apos;, &apos;name&apos;: &apos;Eliot Horowitz&apos;, &apos;email&apos;: &apos;eliot@10gen.com&apos;}
&lt;p&gt;Message: removed some UTF-8 conversions by checking values &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-194&quot; title=&quot;Improved Performance of BSONDecoder&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-194&quot;&gt;&lt;del&gt;JAVA-194&lt;/del&gt;&lt;/a&gt;&lt;br/&gt;
&lt;a href=&quot;http://github.com/mongodb/mongo-java-driver/commit/306e36c148c19447a03c81a9d93c4e947d97feb0&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://github.com/mongodb/mongo-java-driver/commit/306e36c148c19447a03c81a9d93c4e947d97feb0&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="19435" author="eliot" created="Thu, 21 Oct 2010 12:57:53 +0000"  >&lt;p&gt;Reading the diff I think the main reason you see a speed bump is because you&apos;re not doing some utf8 encoding in some places.&lt;br/&gt;
The problem is that we need to, as the unit tests don&apos;t pass with your change.&lt;/p&gt;

&lt;p&gt;Try &quot;ant test&quot; to see some failures.&lt;/p&gt;

&lt;p&gt;There are a lot of diffs in that commit.&lt;br/&gt;
Some seem to by stylistic formatting, and there are a few other concepts.&lt;/p&gt;

&lt;p&gt;very hard to see what&apos;s going on exactly.&lt;/p&gt;

&lt;p&gt;will try to see if there is anything we can use, but breaking it up into smaller commits, and making sure style/formatting doesn&apos;t change would be very helpful&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                                                <inwardlinks description="is depended on by">
                                                        </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|hrhcpz:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10558" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>14861</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            </customfields>
    </item>
</channel>
</rss>