<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 08:53:15 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-863] gridFs.remove((DBObject)null) removes all elements from bucket</title>
                <link>https://jira.mongodb.org/browse/JAVA-863</link>
                <project id="10006" key="JAVA">Java Driver</project>
                    <description>&lt;p&gt;When passing null to GridFS.remove(DBObject dbobject) all files of the current bucket are removed. This is inconsistent compared to the other remove() methods of GridFS:&lt;/p&gt;

&lt;p&gt;gridFs.remove((String)null);	// nothing happens&lt;br/&gt;
gridFs.remove((ObjectId)null);	// nothing happens&lt;br/&gt;
gridFs.remove((DBObject)null);  // all files from bucket are removed&lt;/p&gt;

&lt;p&gt;If this is intended behavior it should be documented in the javadoc comment.&lt;/p&gt;</description>
                <environment>java version &amp;quot;1.7.0_25&amp;quot;&lt;br/&gt;
Java(TM) SE Runtime Environment (build 1.7.0_25-b17)&lt;br/&gt;
Java HotSpot(TM) Client VM (build 23.25-b01, mixed mode, sharing)&lt;br/&gt;
Mongodb version: 2.0.6&lt;br/&gt;
Java driver version: 2.11.2</environment>
        <key id="81296">JAVA-863</key>
            <summary>gridFs.remove((DBObject)null) removes all elements from bucket</summary>
                <type id="1" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14703&amp;avatarType=issuetype">Bug</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="micha">Micha S.</reporter>
                        <labels>
                    </labels>
                <created>Thu, 4 Jul 2013 21:04:52 +0000</created>
                <updated>Thu, 27 Feb 2014 14:50:06 +0000</updated>
                            <resolved>Thu, 5 Dec 2013 15:03:00 +0000</resolved>
                                    <version>2.11.2</version>
                                    <fixVersion>2.12.0</fixVersion>
                    <fixVersion>3.0.0</fixVersion>
                                    <component>GridFS</component>
                                        <votes>0</votes>
                                    <watches>3</watches>
                                                                                                                <comments>
                            <comment id="506328" author="jeff.yemin" created="Thu, 27 Feb 2014 14:50:06 +0000"  >&lt;p&gt;Hi Micha,&lt;/p&gt;

&lt;p&gt;Would you mind testing with 2.12.0-rc0, available either on &lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/releases/tag/r2.12.0-rc0&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;github&lt;/a&gt; or &lt;a href=&quot;http://central.maven.org/maven2/org/mongodb/mongo-java-driver/2.12.0-rc0/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;Maven Central&lt;/a&gt;?&lt;/p&gt;


&lt;p&gt;Thanks,&lt;br/&gt;
Jeff&lt;/p&gt;</comment>
                            <comment id="466161" author="jeff.yemin" created="Thu, 5 Dec 2013 15:03:00 +0000"  >&lt;p&gt;All three remove methods in GridFS now throw IllegalArgumentException if the parameter value is null.&lt;/p&gt;</comment>
                            <comment id="466157" author="xgen-internal-githook" created="Thu, 5 Dec 2013 15:02:05 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{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-863&quot; title=&quot;gridFs.remove((DBObject)null) removes all elements from bucket&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-863&quot;&gt;&lt;del&gt;JAVA-863&lt;/del&gt;&lt;/a&gt;: Added null checks in remove methods for GridFS.&lt;br/&gt;
Branch: 3.0.x&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/06d7d907d64d130bc84242c8c4fcbc3ca20afafe&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/06d7d907d64d130bc84242c8c4fcbc3ca20afafe&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="466152" author="xgen-internal-githook" created="Thu, 5 Dec 2013 14:54:34 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;username&apos;: u&apos;neerajbhatt&apos;, u&apos;name&apos;: u&apos;neerajbhatt&apos;, u&apos;email&apos;: u&apos;neerajbhatt2000@gmail.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-863&quot; class=&quot;external-link&quot; rel=&quot;nofollow&quot;&gt;https://jira.mongodb.org/browse/JAVA-863&lt;/a&gt;, fixed null checks in remove method&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/4ef307e7ad9174e2ee138b01dcb2424017b9822d&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/4ef307e7ad9174e2ee138b01dcb2424017b9822d&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="466151" author="xgen-internal-githook" created="Thu, 5 Dec 2013 14:54:32 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;username&apos;: u&apos;neerajbhatt&apos;, u&apos;name&apos;: u&apos;neerajbhatt&apos;, u&apos;email&apos;: u&apos;neerajbhatt2000@gmail.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-863&quot; class=&quot;external-link&quot; rel=&quot;nofollow&quot;&gt;https://jira.mongodb.org/browse/JAVA-863&lt;/a&gt;, fixed null checks in reove method&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/6fad5e473d6f37a640d36926ff66c8460d386cf2&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/6fad5e473d6f37a640d36926ff66c8460d386cf2&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="465935" author="neerajbhatt" created="Thu, 5 Dec 2013 00:54:55 +0000"  >&lt;p&gt;Hi Jeff&lt;br/&gt;
I have raised a pull request to fix this bug&lt;/p&gt;</comment>
                            <comment id="461537" author="jeff.yemin" created="Mon, 25 Nov 2013 20:55:36 +0000"  >&lt;p&gt;My preference is to change (and Javadoc, of course) all three methods to throw IllegalArgumentException if the parameter is null.  This would more closely match the behavior of DBCollection.remove, which also throws if the query is null (though it throws an NPE, which we should also change).&lt;/p&gt;</comment>
                            <comment id="461410" author="jeff.yemin" created="Mon, 25 Nov 2013 19:22:41 +0000"  >&lt;p&gt;Hi Micha,&lt;/p&gt;

&lt;p&gt;We&apos;re going to look into doing something about this in the next release.&lt;/p&gt;
</comment>
                    </comments>
                    <attachments>
                            <attachment id="28619" name="Main.java" size="966" author="micha" created="Thu, 4 Jul 2013 21:04:52 +0000"/>
                    </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|hrri47:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10558" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>74322</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                    <customfield id="customfield_10557" key="com.pyxis.greenhopper.jira:gh-sprint">
                        <customfieldname>Sprint</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue id="77">Sprint 1</customfieldvalue>

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