<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 08:57: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>[JAVA-2447] Implement Extended JSON specification</title>
                <link>https://jira.mongodb.org/browse/JAVA-2447</link>
                <project id="10006" key="JAVA">Java Driver</project>
                    <description>&lt;p&gt;Specification: &lt;a href=&quot;https://github.com/mongodb/specifications/blob/master/source/extended-json.rst&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/specifications/blob/master/source/extended-json.rst&lt;/a&gt;&lt;br/&gt;
Tests: &lt;a href=&quot;https://github.com/mongodb/specifications/tree/master/source/bson-corpus/tests&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/specifications/tree/master/source/bson-corpus/tests&lt;/a&gt;&lt;/p&gt;</description>
                <environment></environment>
        <key id="353464">JAVA-2447</key>
            <summary>Implement Extended JSON specification</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="9">Done</resolution>
                                        <assignee username="jeff.yemin@mongodb.com">Jeffrey Yemin</assignee>
                                    <reporter username="jeff.yemin@mongodb.com">Jeffrey Yemin</reporter>
                        <labels>
                    </labels>
                <created>Mon, 13 Feb 2017 14:21:34 +0000</created>
                <updated>Sun, 28 Apr 2019 17:21:55 +0000</updated>
                            <resolved>Fri, 21 Jul 2017 19:23:17 +0000</resolved>
                                                    <fixVersion>3.5.0</fixVersion>
                                    <component>JSON</component>
                                        <votes>0</votes>
                                    <watches>4</watches>
                                                                                                                <comments>
                            <comment id="2227086" author="sivakeshavulu" created="Sun, 28 Apr 2019 17:21:55 +0000"  >&lt;p&gt;HI Jeff Yemin&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;com.mongodb.util.JSON.serialize is working properly is there any other alternate solution?&lt;/p&gt;

&lt;p&gt;// or use a connection string// or use a connection string MongoClientURI connectionString = new MongoClientURI(&quot;mongodb://localhost:27017&quot;); MongoClient mongoClient = new MongoClient(connectionString);&lt;br/&gt;
 MongoDatabase database = mongoClient.getDatabase(&quot;testdb&quot;); MongoCollection&amp;lt;Document&amp;gt; collection = database.getCollection(&quot;user&quot;); //JsonWriterSettings writerSettings = new JsonWriterSettings(JsonMode.SHELL, true);&#160; &#160; &#160; &#160; &#160; &#160; //System.out.println(doc.toJson(writerSettings)); Document myDoc = collection.find().first(); //System.out.println(myDoc.toJson(writerSettings)); System.out.println(&quot;output (JSON) = &quot; + com.mongodb.util.JSON.serialize(myDoc));&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;output (JSON) = { &quot;_id&quot; : &lt;/p&gt;
{ &quot;$oid&quot; : &quot;5cc2e1d4734a1f4d66966554&quot;}
&lt;p&gt; , &quot;name&quot; : &quot;mkyong-updated&quot; , &quot;age&quot; : 30 , &quot;createdDate&quot; : { &quot;$date&quot; : &quot;2019-04-26T10:47:48.643Z&quot;}}&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;</comment>
                            <comment id="2225801" author="keshavlu4u" created="Fri, 26 Apr 2019 12:49:49 +0000"  >&lt;p&gt;Dear Jeff Yemin&lt;/p&gt;

&lt;p&gt;can you please give me one java example for more understanding.&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;</comment>
                            <comment id="2225797" author="jeff.yemin" created="Fri, 26 Apr 2019 12:46:06 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=keshavlu4u&quot; class=&quot;user-hover&quot; rel=&quot;keshavlu4u&quot;&gt;keshavlu4u&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;See our extended JSON specification at &lt;a href=&quot;https://github.com/mongodb/specifications/blob/master/source/extended-json.rst#id10&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/specifications/blob/master/source/extended-json.rst#id10&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;You may be looking for &quot;Relaxed&quot; extended JSON format, which is not the default but can be requested via the &lt;tt&gt;Document.toJson(JsonWriterSettings)&lt;/tt&gt; overloaded method&lt;/p&gt;</comment>
                            <comment id="2225789" author="keshavlu4u" created="Fri, 26 Apr 2019 12:38:16 +0000"  >&lt;p&gt;Dear&#160;Jeff Yemin&lt;/p&gt;

&lt;p&gt;Date format is wrong my MongoDb and&#160; java Driver rutting the date is not same please refer below.&lt;/p&gt;

&lt;p&gt;&quot;createdDate&quot; : ISODate(&quot;2019-04-26T10:47:48.643+0000&quot;) - MongodB collection data&lt;/p&gt;

&lt;p&gt;&quot;createdDate&quot;: {&quot;$date&quot;: 1556275668643}} - Java Driver Reponse&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;&lt;b&gt;Please help us&lt;/b&gt;&lt;/p&gt;

&lt;p&gt;&lt;font color=&quot;#FF0000&quot;&gt;Expecting same as mongodb:&#160;&lt;/font&gt;&lt;/p&gt;

&lt;p&gt;&lt;font color=&quot;#FF0000&quot;&gt;i am facing issue on date (&lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-2454&quot; title=&quot;Document.toJson incorrectly serializes Date&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-2454&quot;&gt;&lt;del&gt;JAVA-2454&lt;/del&gt;&lt;/a&gt;) same issue.&lt;/font&gt;&lt;/p&gt;

&lt;p&gt;Java Code&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;// or use a connection string// or use a connection string MongoClientURI connectionString = new MongoClientURI(&quot;mongodb://localhost:27017&quot;); MongoClient mongoClient = new MongoClient(connectionString);&lt;br/&gt;
 MongoDatabase database = mongoClient.getDatabase(&quot;testdb&quot;); MongoCollection&amp;lt;Document&amp;gt; collection = database.getCollection(&quot;user&quot;); Document myDoc = collection.find().first(); System.out.println(myDoc.toJson());&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;Reponse :{&quot;_id&quot;: &lt;/p&gt;
{&quot;$oid&quot;: &quot;5cc2e1d4734a1f4d66966554&quot;}
&lt;p&gt;, &quot;name&quot;: &quot;mkyong-updated&quot;, &quot;age&quot;: 30, &quot;createdDate&quot;: {&quot;$date&quot;: 1556275668643}}&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;MongoDB :&#160;&lt;/p&gt;

{ 
 &quot;_id&quot; : ObjectId(&quot;5cc2e1d4734a1f4d66966554&quot;), 
 &quot;name&quot; : &quot;mkyong-updated&quot;, 
 &quot;age&quot; : NumberInt(30), 
 &quot;createdDate&quot; : ISODate(&quot;2019-04-26T10:47:48.643+0000&quot;)
}

&lt;p&gt;&#160;&lt;/p&gt;</comment>
                            <comment id="1628990" author="xgen-internal-githook" created="Fri, 21 Jul 2017 19:15:34 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;username&apos;: u&apos;jyemin&apos;, u&apos;name&apos;: u&apos;Jeff Yemin&apos;, u&apos;email&apos;: u&apos;jeff.yemin@10gen.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-2447&quot; title=&quot;Implement Extended JSON specification&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-2447&quot;&gt;&lt;del&gt;JAVA-2447&lt;/del&gt;&lt;/a&gt;: Implement revised extended JSON specification&lt;/p&gt;

&lt;p&gt;  Support new canonical and relaxed extended JSON forms&lt;/p&gt;

&lt;p&gt;  Change extended JSON parser to throw exceptions for documents&lt;br/&gt;
  that have at least one of the reserved $-prefixed keys&lt;br/&gt;
  but otherwise do not match the extended JSON form&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/775f75f49ef51df16c7ab15ad0fdd27cc05a73c9&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/775f75f49ef51df16c7ab15ad0fdd27cc05a73c9&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1530237" author="xgen-internal-githook" created="Wed, 22 Mar 2017 13:51:04 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;username&apos;: u&apos;jyemin&apos;, u&apos;name&apos;: u&apos;Jeff Yemin&apos;, u&apos;email&apos;: u&apos;jeff.yemin@10gen.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-2447&quot; title=&quot;Implement Extended JSON specification&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-2447&quot;&gt;&lt;del&gt;JAVA-2447&lt;/del&gt;&lt;/a&gt;: Treat values that don&apos;t parse as the required types for extended JSON as an indication&lt;br/&gt;
that the document does not match the Extended JSON production and therefore should be treated as a&lt;br/&gt;
normal document.&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/b5135623e73ff38149ad2deba1b891f7f35bb222&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/b5135623e73ff38149ad2deba1b891f7f35bb222&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1530236" author="xgen-internal-githook" created="Wed, 22 Mar 2017 13:51:03 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;username&apos;: u&apos;jyemin&apos;, u&apos;name&apos;: u&apos;Jeff Yemin&apos;, u&apos;email&apos;: u&apos;jeff.yemin@10gen.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-2447&quot; title=&quot;Implement Extended JSON specification&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-2447&quot;&gt;&lt;del&gt;JAVA-2447&lt;/del&gt;&lt;/a&gt;:  Handle $-prefixed keys that don&apos;t match the extended JSON production by treating them as regular BSON documents&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/4627b5ad2239daa05b7066d679e32d4b30ecdf21&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/4627b5ad2239daa05b7066d679e32d4b30ecdf21&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1525676" author="xgen-internal-githook" created="Thu, 16 Mar 2017 13:40:12 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;username&apos;: u&apos;jyemin&apos;, u&apos;name&apos;: u&apos;Jeff Yemin&apos;, u&apos;email&apos;: u&apos;jeff.yemin@10gen.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-2447&quot; title=&quot;Implement Extended JSON specification&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-2447&quot;&gt;&lt;del&gt;JAVA-2447&lt;/del&gt;&lt;/a&gt;: Remove Java 7/8 dependency for unsigned long operations&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/9d3c02c97e75fce5369c1a943a0e15c8cfa36c37&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/9d3c02c97e75fce5369c1a943a0e15c8cfa36c37&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1524783" author="xgen-internal-githook" created="Wed, 15 Mar 2017 16:21:08 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;username&apos;: u&apos;jyemin&apos;, u&apos;name&apos;: u&apos;Jeff Yemin&apos;, u&apos;email&apos;: u&apos;jeff.yemin@10gen.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-2447&quot; title=&quot;Implement Extended JSON specification&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-2447&quot;&gt;&lt;del&gt;JAVA-2447&lt;/del&gt;&lt;/a&gt;: Support the Extended JSON specification.&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/ebe94bce0c5616cf8cfc0768949a84bd30cef1fd&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/ebe94bce0c5616cf8cfc0768949a84bd30cef1fd&lt;/a&gt;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                                                <inwardlinks description="is depended on by">
                                        <issuelink>
            <issuekey id="353164">DRIVERS-351</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10010">
                    <name>Duplicate</name>
                                            <outwardlinks description="duplicates">
                                        <issuelink>
            <issuekey id="350501">JAVA-2439</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is duplicated by">
                                        <issuelink>
            <issuekey id="293670">JAVA-2224</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="357973">JAVA-2454</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="198637">JAVA-1769</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="366919">JAVA-2475</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                                                <inwardlinks description="is related to">
                                        <issuelink>
            <issuekey id="404230">JAVA-2556</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="281022">JAVA-2173</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="373766">JAVA-2489</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|hraqtr:</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>
                                                                                                                                                                                                                                                                    <customfield id="customfield_10557" key="com.pyxis.greenhopper.jira:gh-sprint">
                        <customfieldname>Sprint</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue id="1564">JVM Sprint 38</customfieldvalue>
    <customfieldvalue id="1750">JVM Sprint 40</customfieldvalue>

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