<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 03:12:14 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>[SERVER-6625]  db.adminCommand(&apos;top&apos;) seems to record commands as queries</title>
                <link>https://jira.mongodb.org/browse/SERVER-6625</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;In a database where the collection &apos;test.gamma&apos; does not exist, I run the following shell command:&lt;/p&gt;

&lt;p&gt;&amp;gt;&amp;gt; for( i in [ 1, 2, 3, 4,5,6,7,8,9,10]) { db.gamma.insert( &lt;/p&gt;
{x:i}
&lt;p&gt; ); db.gamma.count(); }&lt;/p&gt;

&lt;p&gt;I then run the following command to display the operations on that collection:&lt;/p&gt;

&lt;p&gt;&amp;gt;&amp;gt; db.adminCommand(&apos;top&apos;).totals&lt;span class=&quot;error&quot;&gt;&amp;#91;&amp;#39;test.gamma&amp;#39;&amp;#93;&lt;/span&gt;;&lt;/p&gt;

&lt;p&gt;{ &lt;br/&gt;
      &quot;total&quot; :         &lt;/p&gt;
{ &quot;time&quot; : 1036852,     &quot;count&quot; : 30 }
&lt;p&gt;,&lt;br/&gt;
      &quot;readLock&quot; :      &lt;/p&gt;
{ &quot;time&quot; : 80,          &quot;count&quot; : 20 }
&lt;p&gt;,&lt;br/&gt;
      &quot;writeLock&quot; :     &lt;/p&gt;
{ &quot;time&quot; : 1036772,     &quot;count&quot; : 10 }
&lt;p&gt;,&lt;br/&gt;
      &quot;queries&quot; :       &lt;/p&gt;
{ &quot;time&quot; : 80,          &quot;count&quot; : 20 }
&lt;p&gt;,&lt;br/&gt;
      &quot;getmore&quot; :       &lt;/p&gt;
{ &quot;time&quot; : 0,           &quot;count&quot; : 0 }
&lt;p&gt;,&lt;br/&gt;
      &quot;insert&quot; :        &lt;/p&gt;
{ &quot;time&quot; : 1036772,     &quot;count&quot; : 10 }
&lt;p&gt;,&lt;br/&gt;
      &quot;update&quot; :        &lt;/p&gt;
{ &quot;time&quot; : 0,           &quot;count&quot; : 0 }
&lt;p&gt;,&lt;br/&gt;
      &quot;remove&quot; :        &lt;/p&gt;
{ &quot;time&quot; : 0,           &quot;count&quot; : 0 }
&lt;p&gt;,&lt;br/&gt;
      &quot;commands&quot; :      &lt;/p&gt;
{ &quot;time&quot; : 0,           &quot;count&quot; : 0 }
&lt;p&gt; &lt;br/&gt;
}&lt;/p&gt;

&lt;p&gt;Note that the counts show 10 inserts 10 write locks, and also 20 read locks and 20 queries.&lt;/p&gt;

&lt;p&gt;I believe that it should show 0 queries and 10 commands.&lt;/p&gt;

&lt;p&gt;Checking with &quot;db.serverStatus().opcounters&quot; shows that there should be 0 queries and 10 commands.&lt;/p&gt;</description>
                <environment></environment>
        <key id="45631">SERVER-6625</key>
            <summary> db.adminCommand(&apos;top&apos;) seems to record commands as queries</summary>
                <type id="1" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14703&amp;avatarType=issuetype">Bug</type>
                                            <priority id="4" iconUrl="https://jira.mongodb.org/images/icons/priorities/minor.svg">Minor - P4</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="sverch">Shaun Verch</assignee>
                                    <reporter username="william.zola@10gen.com">William Zola</reporter>
                        <labels>
                    </labels>
                <created>Fri, 27 Jul 2012 15:38:03 +0000</created>
                <updated>Mon, 11 Jul 2016 17:58:37 +0000</updated>
                            <resolved>Tue, 27 Nov 2012 18:51:06 +0000</resolved>
                                    <version>2.0.6</version>
                    <version>2.1.2</version>
                                    <fixVersion>2.2.2</fixVersion>
                    <fixVersion>2.3.2</fixVersion>
                                    <component>Diagnostics</component>
                                        <votes>1</votes>
                                    <watches>4</watches>
                                                                                                                <comments>
                            <comment id="200395" author="dan@10gen.com" created="Tue, 27 Nov 2012 18:51:06 +0000"  >&lt;p&gt;breaking out jstest to separate task: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-7774&quot; title=&quot;Add jstest for db.adminCommand(&amp;#39;top&amp;#39;)&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-7774&quot;&gt;&lt;del&gt;SERVER-7774&lt;/del&gt;&lt;/a&gt;.&lt;/p&gt;</comment>
                            <comment id="185792" author="auto" created="Sun, 11 Nov 2012 20:11:50 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;date&apos;: u&apos;2012-10-18T21:20:01Z&apos;, u&apos;email&apos;: u&apos;shaun.verch@10gen.com&apos;, u&apos;name&apos;: u&apos;Shaun Verch&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-6625&quot; title=&quot; db.adminCommand(&amp;#39;top&amp;#39;) seems to record commands as queries&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-6625&quot;&gt;&lt;del&gt;SERVER-6625&lt;/del&gt;&lt;/a&gt; Log commands as commands instead of queries in top stats&lt;br/&gt;
Branch: v2.2&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/e716273e6e340b69d3ffc16545c297d76bca85fb&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/e716273e6e340b69d3ffc16545c297d76bca85fb&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="183873" author="auto" created="Thu, 8 Nov 2012 02:18:36 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;date&apos;: u&apos;2012-10-18T21:20:01Z&apos;, u&apos;email&apos;: u&apos;shaun.verch@10gen.com&apos;, u&apos;name&apos;: u&apos;Shaun Verch&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-6625&quot; title=&quot; db.adminCommand(&amp;#39;top&amp;#39;) seems to record commands as queries&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-6625&quot;&gt;&lt;del&gt;SERVER-6625&lt;/del&gt;&lt;/a&gt; Log commands as commands instead of queries in top stats&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo/commit/8f98f933e8997db213994ab6f7de9908ba01ab8d&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/commit/8f98f933e8997db213994ab6f7de9908ba01ab8d&lt;/a&gt;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                                                <inwardlinks description="is depended on by">
                                                        </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="57630">SERVER-7774</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is related to">
                                                        </inwardlinks>
                                    </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                <customfield id="customfield_10050" key="com.atlassian.jira.toolkit:comments">
                        <customfieldname># Replies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>3.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Sun, 29 Jul 2012 21:13:44 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        11 years, 12 weeks, 1 day ago
    
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_18254" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Dependencies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue><![CDATA[]]></customfieldvalue>


                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_15850" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_10057" key="com.atlassian.jira.toolkit:lastusercommented">
                        <customfieldname>Last comment by Customer</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>true</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_10056" key="com.atlassian.jira.toolkit:lastupdaterorcommenter">
                        <customfieldname>Last commenter</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>ramon.fernandez@mongodb.com</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_11151" key="com.atlassian.jira.toolkit:LastCommentDate">
                        <customfieldname>Last public comment date</customfieldname>
                        <customfieldvalues>
                            11 years, 12 weeks, 1 day ago
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                    <customfield id="customfield_10032" key="com.atlassian.jira.plugin.system.customfieldtypes:select">
                        <customfieldname>Operating System</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10026"><![CDATA[ALL]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>auto</customfieldvalue>
            <customfieldvalue>dan@mongodb.com</customfieldvalue>
            <customfieldvalue>sverch</customfieldvalue>
            <customfieldvalue>william.zola@10gen.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hrntn3:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hrfx2n:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10558" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>5697</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_23361" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Requested By</customfieldname>
                        <customfieldvalues>
                                

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            <customfield id="customfield_10053" key="com.atlassian.jira.ext.charting:timeinstatus">
                        <customfieldname>Time In Status</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_22870" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Triagers</customfieldname>
                        <customfieldvalues>
                                

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_14350" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>serverRank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hsge4n:</customfieldvalue>

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