<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 08:57: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>[JAVA-2698] Include more of the command document when logging command execution</title>
                <link>https://jira.mongodb.org/browse/JAVA-2698</link>
                <project id="10006" key="JAVA">Java Driver</project>
                    <description>&lt;p&gt;Currently the logging of a command looks like this:&lt;/p&gt;

&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;Sending command {find : BsonString{value=&apos;mycoll&apos;}}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;

&lt;p&gt;which makes it more difficult than necessary to determine the contents of the command.  Instead, the driver should log a fixed number of characters from the relaxed extended JSON representation of the command:&lt;/p&gt;

&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;Sending command {&quot;find&quot; : &quot;myColl&quot;, filter : { &quot;open&quot; : true }, lim...&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;

&lt;p&gt;Suggested character count: 100&lt;/p&gt;</description>
                <environment></environment>
        <key id="469994">JAVA-2698</key>
            <summary>Include more of the command document when logging command execution</summary>
                <type id="2" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14711&amp;avatarType=issuetype">New Feature</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="jeff.yemin@mongodb.com">Jeffrey Yemin</assignee>
                                    <reporter username="jeff.yemin@mongodb.com">Jeffrey Yemin</reporter>
                        <labels>
                    </labels>
                <created>Fri, 8 Dec 2017 19:34:37 +0000</created>
                <updated>Sat, 28 Oct 2023 11:23:04 +0000</updated>
                            <resolved>Tue, 9 Jan 2018 14:21:56 +0000</resolved>
                                                    <fixVersion>3.7.0</fixVersion>
                                    <component>Monitoring</component>
                                        <votes>0</votes>
                                    <watches>1</watches>
                                                                                                                <comments>
                            <comment id="1768865" author="xgen-internal-githook" created="Tue, 9 Jan 2018 14:20:18 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Jeff Yemin&apos;, &apos;username&apos;: &apos;jyemin&apos;, &apos;email&apos;: &apos;jeff.yemin@10gen.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-2697&quot; title=&quot;Include elapsed time and request id when logging command execution&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-2697&quot;&gt;&lt;del&gt;JAVA-2697&lt;/del&gt;&lt;/a&gt;, &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-2698&quot; title=&quot;Include more of the command document when logging command execution&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-2698&quot;&gt;&lt;del&gt;JAVA-2698&lt;/del&gt;&lt;/a&gt;: Log successful and failed command events, including elapsed time, request id, and truncated (at 1000 characters) JSON representation of the command.  Logs now look like this (against a 3.6 server)&lt;/p&gt;

&lt;p&gt;10:37:29.099 [cluster-ClusterId&lt;/p&gt;
{value=&apos;5a466138741fc252712a6d71&apos;, description=&apos;null&apos;}-127.0.0.1:27017] DEBUG org.mongodb.driver.protocol.command - Sending command &apos;{ &quot;ismaster&quot; : 1, &quot;$db&quot; : &quot;admin&quot; } ...&apos; with request id 4 to database admin on connection &lt;span class=&quot;error&quot;&gt;&amp;#91;connectionId{localValue:1, serverValue:1958}&amp;#93;&lt;/span&gt; to server 127.0.0.1:27017&lt;br/&gt;
10:37:29.104 [cluster-ClusterId{value=&apos;5a466138741fc252712a6d71&apos;, description=&apos;null&apos;}
&lt;p&gt;-127.0.0.1:27017] DEBUG org.mongodb.driver.protocol.command - Execution of command with request id 4 completed successfully in 22.44 ms on connection [connectionId&lt;/p&gt;
{localValue:1, serverValue:1958}
&lt;p&gt;] to server 127.0.0.1:27017&lt;br/&gt;
10:37:29.154 &lt;span class=&quot;error&quot;&gt;&amp;#91;main&amp;#93;&lt;/span&gt; DEBUG org.mongodb.driver.protocol.command - Sending command &apos;{ &quot;insert&quot; : &quot;test&quot;, &quot;ordered&quot; : true, &quot;writeConcern&quot; : &lt;/p&gt;
{ &quot;w&quot; : 0 }
&lt;p&gt;, &quot;$db&quot; : &quot;test&quot;, &quot;documents&quot; : [{ &quot;_id&quot; : &lt;/p&gt;
{ &quot;$oid&quot; : &quot;5a466139741fc252712a6d72&quot; }
&lt;p&gt;, &quot;bytes&quot; : { &quot;$binary&quot; : { &quot;base64&quot; : &quot;AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA ...&apos; with request id 8 to database test on connection [connectionId&lt;/p&gt;
{localValue:2, serverValue:1959}
&lt;p&gt;] to server 127.0.0.1:27017&lt;br/&gt;
10:37:29.154 &lt;span class=&quot;error&quot;&gt;&amp;#91;main&amp;#93;&lt;/span&gt; DEBUG org.mongodb.driver.protocol.command - Execution of one-way command with request id 8 completed successfully in 24.02 ms on connection [connectionId&lt;/p&gt;
{localValue:2, serverValue:1959}
&lt;p&gt;] to server 127.0.0.1:27017&lt;br/&gt;
10:37:29.161 &lt;span class=&quot;error&quot;&gt;&amp;#91;main&amp;#93;&lt;/span&gt; DEBUG org.mongodb.driver.protocol.command - Sending command &apos;{ &quot;ping&quot; : 1, &quot;$db&quot; : &quot;admin&quot;, &quot;lsid&quot; : { &quot;id&quot; : { &quot;$binary&quot; : &lt;/p&gt;
{ &quot;base64&quot; : &quot;1VaSnyegTCy9yXzgsmP0FQ==&quot;, &quot;subType&quot; : &quot;04&quot; }
&lt;p&gt; } } } ...&apos; with request id 9 to database admin on connection [connectionId&lt;/p&gt;
{localValue:2, serverValue:1959}
&lt;p&gt;] to server 127.0.0.1:27017&lt;br/&gt;
10:37:29.162 &lt;span class=&quot;error&quot;&gt;&amp;#91;main&amp;#93;&lt;/span&gt; DEBUG org.mongodb.driver.protocol.command - Execution of command with request id 9 completed successfully in 1.46 ms on connection [connectionId&lt;/p&gt;
{localValue:2, serverValue:1959}
&lt;p&gt;] to server 127.0.0.1:27017&lt;br/&gt;
10:37:29.163 &lt;span class=&quot;error&quot;&gt;&amp;#91;main&amp;#93;&lt;/span&gt; DEBUG org.mongodb.driver.protocol.command - Sending command &apos;{ &quot;unknown&quot; : 1, &quot;$db&quot; : &quot;admin&quot;, &quot;lsid&quot; : { &quot;id&quot; : { &quot;$binary&quot; : &lt;/p&gt;
{ &quot;base64&quot; : &quot;1VaSnyegTCy9yXzgsmP0FQ==&quot;, &quot;subType&quot; : &quot;04&quot; }
&lt;p&gt; } } } ...&apos; with request id 10 to database admin on connection [connectionId&lt;/p&gt;
{localValue:2, serverValue:1959}
&lt;p&gt;] to server 127.0.0.1:27017&lt;br/&gt;
10:37:29.175 &lt;span class=&quot;error&quot;&gt;&amp;#91;main&amp;#93;&lt;/span&gt; DEBUG org.mongodb.driver.protocol.command - Execution of command with request id 10 failed to complete successfully in 5.34 ms on connection [connectionId&lt;/p&gt;
{localValue:2, serverValue:1959}
&lt;p&gt;] to server 127.0.0.1:27017&lt;br/&gt;
com.mongodb.MongoCommandException: Command failed with error 59: &apos;no such command: &apos;unknown&apos;, bad cmd: &apos;{ unknown: 1, $db: &quot;admin&quot;, lsid: &lt;/p&gt;
{ id: UUID(&quot;d556929f-27a0-4c2c-bdc9-7ce0b263f415&quot;) }
&lt;p&gt; }&apos;&apos; on server 127.0.0.1:27017. The full response is { &quot;operationTime&quot; : { &quot;$timestamp&quot; : &lt;/p&gt;
{ &quot;t&quot; : 1514556771, &quot;i&quot; : 1 }
&lt;p&gt; }, &quot;ok&quot; : 0.0, &quot;errmsg&quot; : &quot;no such command: &apos;unknown&apos;, bad cmd: &apos;{ unknown: 1, $db: \&quot;admin\&quot;, lsid: &lt;/p&gt;
{ id: UUID(\&quot;d556929f-27a0-4c2c-bdc9-7ce0b263f415\&quot;) }
&lt;p&gt; }&apos;&quot;, &quot;code&quot; : 59, &quot;codeName&quot; : &quot;CommandNotFound&quot; }&lt;br/&gt;
    at com.mongodb.connection.ProtocolHelper.getCommandFailureException(ProtocolHelper.java:164)&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/a93299f7a9a18e9febabfd8445a24af0f8a8c194&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/a93299f7a9a18e9febabfd8445a24af0f8a8c194&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1768863" author="xgen-internal-githook" created="Tue, 9 Jan 2018 14:20:13 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Jeff Yemin&apos;, &apos;username&apos;: &apos;jyemin&apos;, &apos;email&apos;: &apos;jeff.yemin@10gen.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-2698&quot; title=&quot;Include more of the command document when logging command execution&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-2698&quot;&gt;&lt;del&gt;JAVA-2698&lt;/del&gt;&lt;/a&gt;: Add ability in JsonWriter to abort execution of the pipe method based on whether the max length of the JSON text has been reached.&lt;/p&gt;

&lt;p&gt;   Implemented by adding an abortPipe() method in AbstractBsonWriter which just returns true, and overriding it in JsonWriter&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/8a07eeb25e0a88dd59d726c595920cc4f2c53f14&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/8a07eeb25e0a88dd59d726c595920cc4f2c53f14&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1768862" author="xgen-internal-githook" created="Tue, 9 Jan 2018 14:20:10 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Jeff Yemin&apos;, &apos;username&apos;: &apos;jyemin&apos;, &apos;email&apos;: &apos;jeff.yemin@10gen.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-2698&quot; title=&quot;Include more of the command document when logging command execution&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-2698&quot;&gt;&lt;del&gt;JAVA-2698&lt;/del&gt;&lt;/a&gt;: Add asBsonReader to BsonDocument so that subclasses can determine the most efficient&lt;br/&gt;
implemenation of BsonReader to use&lt;/p&gt;

&lt;p&gt;The default implementation just returns a BsonDocumentReader&lt;br/&gt;
RawBsonDocument and ByteBufBsonDocument override it to return a BsonBinaryReader&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/0d19db19c2b1803cd06e3a01b17193de4cb1c848&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/0d19db19c2b1803cd06e3a01b17193de4cb1c848&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1768861" author="xgen-internal-githook" created="Tue, 9 Jan 2018 14:20:09 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Jeff Yemin&apos;, &apos;username&apos;: &apos;jyemin&apos;, &apos;email&apos;: &apos;jeff.yemin@10gen.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-2698&quot; title=&quot;Include more of the command document when logging command execution&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-2698&quot;&gt;&lt;del&gt;JAVA-2698&lt;/del&gt;&lt;/a&gt;: BsonReader extends Closeable&lt;/p&gt;

&lt;p&gt;   Note: this is a backwards-breaking change for any implementation of BsonReader that don&apos;t already implement Closeable&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/827427e5c0da062c81c92c63af078f7782f83dbc&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/827427e5c0da062c81c92c63af078f7782f83dbc&lt;/a&gt;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                            <outwardlinks description="depends on">
                                        <issuelink>
            <issuekey id="476948">JAVA-2721</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                            <issuelinktype id="10010">
                    <name>Duplicate</name>
                                                                <inwardlinks description="is duplicated by">
                                        <issuelink>
            <issuekey id="509693">JAVA-2804</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="149910">JAVA-1322</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                                                <inwardlinks description="is related to">
                                        <issuelink>
            <issuekey id="469984">JAVA-2697</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|hr9073:</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>