<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 08:53: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-858] Deprecate callbacks</title>
                <link>https://jira.mongodb.org/browse/JAVA-858</link>
                <project id="10006" key="JAVA">Java Driver</project>
                    <description>&lt;p&gt;If we look at the usage of the following classes, we will see that they are actually used only by corresponding decoders. &lt;/p&gt;

&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;org.bson.BSONCallback&lt;/li&gt;
	&lt;li&gt;org.bson.EmptyBSONCallback&lt;/li&gt;
	&lt;li&gt;org.bson.LazyBSONCallback&lt;/li&gt;
	&lt;li&gt;org.bson.BasicBSONCallback&lt;/li&gt;
	&lt;li&gt;com.mongodb.DBCallback&lt;/li&gt;
	&lt;li&gt;com.mongodb.DefaultDBCallback&lt;/li&gt;
	&lt;li&gt;com.mongodb.LazyDBCallback&lt;/li&gt;
	&lt;li&gt;com.mongodb.LazyWritableDBCallback&lt;/li&gt;
	&lt;li&gt;com.mongodb.util.JSONCallback&lt;/li&gt;
	&lt;li&gt;com.mongodb.DBCallbackFactory&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;At the same time &lt;b&gt;com.mongodb.DBCallbackFactory&lt;/b&gt; is used only by &lt;b&gt;DefaultDBCallback&lt;/b&gt;, where it is a &lt;b&gt;public static&lt;/b&gt; field. So I think that it&apos;s better to hide all this from public api in future releases, and for now we can deprecate them.&lt;/p&gt;

&lt;p&gt;&lt;span class=&quot;image-wrap&quot; style=&quot;&quot;&gt;&lt;img src=&quot;http://f.cl.ly/items/3q1I4125270v2C461L0r/Image%202013.06.21%206%3A57%3A59%20PM.png&quot; style=&quot;border: 0px solid black&quot; /&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;Also we will be able to deprecate the following methods:&lt;/p&gt;
&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;org.bson.BSONDecoder
	&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
		&lt;li&gt;int decode( byte[] b , BSONCallback callback );&lt;/li&gt;
		&lt;li&gt;int decode( InputStream in , BSONCallback callback ) throws IOException;&lt;/li&gt;
	&lt;/ul&gt;
	&lt;/li&gt;
	&lt;li&gt;com.mongodb.DBDecoder
	&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
		&lt;li&gt;DBCallback getDBCallback(DBCollection collection);&lt;/li&gt;
	&lt;/ul&gt;
	&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;As for com.mongodb.util.JSONCallback, we can just make it package-private and use directly in &lt;b&gt;com.mongodb.util.JSON.JSONParser&lt;/b&gt;.&lt;/p&gt;</description>
                <environment></environment>
        <key id="79947">JAVA-858</key>
            <summary>Deprecate callbacks</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="2">Won&apos;t Fix</resolution>
                                        <assignee username="-1">Unassigned</assignee>
                                    <reporter username="uladzimir_mihura@epam.com">Uladzimir Mihura</reporter>
                        <labels>
                    </labels>
                <created>Fri, 21 Jun 2013 16:23:23 +0000</created>
                <updated>Fri, 26 Jul 2013 14:01:27 +0000</updated>
                            <resolved>Fri, 26 Jul 2013 14:01:27 +0000</resolved>
                                                                    <component>API</component>
                                        <votes>0</votes>
                                    <watches>1</watches>
                                                                                                                <comments>
                            <comment id="366412" author="uladzimir_mihura@epam.com" created="Mon, 24 Jun 2013 14:13:14 +0000"  >&lt;p&gt;I revised the usage of callbacks. I&apos;ve digged through github to find some patterns.&lt;/p&gt;

&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;&lt;a href=&quot;https://github.com/nlloyd/horn-of-mongo&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/nlloyd/horn-of-mongo&lt;/a&gt;&lt;br/&gt;
Extends &lt;a href=&quot;https://github.com/nlloyd/horn-of-mongo/blob/master/src/main/java/com/github/nlloyd/hornofmongo/bson/HornOfMongoDBCallback.java&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;DefaultDBCallback&lt;/a&gt; to change behaviour regarding &apos;undefined&apos; values. To inject callback into decoding process - another &lt;a href=&quot;https://github.com/nlloyd/horn-of-mongo/blob/master/src/main/java/com/github/nlloyd/hornofmongo/bson/HornOfMongoBSONDecoder.java&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;decoder&lt;/a&gt; created.&lt;/li&gt;
	&lt;li&gt;&lt;a href=&quot;https://github.com/jeppetto/jeppetto&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/jeppetto/jeppetto&lt;/a&gt;&lt;br/&gt;
Overrides &lt;a href=&quot;https://github.com/jeppetto/jeppetto/blob/master/jeppetto-dao-mongo/src/main/java/org/iternine/jeppetto/dao/mongodb/enhance/MongoDBCallback.java#L78&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;DefaultDBCallback.create(boolean, List&amp;lt;String&amp;gt;)&lt;/a&gt; to create corresponding objects according to class map (similar to DBOBjectFactory)&lt;/li&gt;
	&lt;li&gt;&lt;a href=&quot;https://github.com/bguerout/jongo&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/bguerout/jongo&lt;/a&gt;&lt;br/&gt;
Overrides &lt;a href=&quot;https://github.com/bguerout/jongo/blob/master/src/main/java/org/jongo/bson/BsonDBDecoder.java#L55&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;LazyBSONCallback.createObject(String, byte, byte[])&lt;/a&gt; to use RelaxedLazyDBObject (extends LazyDBObject) class for newly created objects&lt;/li&gt;
	&lt;li&gt;&lt;a href=&quot;https://github.com/eldenbishop/grinder&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/eldenbishop/grinder&lt;/a&gt;&lt;br/&gt;
Implements &lt;a href=&quot;https://github.com/eldenbishop/grinder/blob/master/src/main/java/org/jauntsy/grinder/panama/api/DboBsonDecoder.java#L29&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;BSONCallback&lt;/a&gt; to provide it&apos;s own way of organising returned document&lt;/li&gt;
	&lt;li&gt;&lt;a href=&quot;https://github.com/mongodb/mongo-ruby-driver&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-ruby-driver&lt;/a&gt;&lt;br/&gt;
Guys have their own mapping from java to ruby &lt;a href=&quot;https://github.com/mongodb/mongo-ruby-driver/blob/master/ext/jbson/src/main/jbson/RubyBSONCallback.java&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;here&lt;/a&gt; but there is no dependency from java-driver because there is a &lt;a href=&quot;https://github.com/mongodb/mongo-ruby-driver/tree/master/ext/jbson/lib&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;jar&lt;/a&gt; with all required classes in repository.&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;-vova&lt;/p&gt;

</comment>
                    </comments>
                    <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|hrraev:</customfieldvalue>

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