<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 08:51:21 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-26] support meta data in gridfs</title>
                <link>https://jira.mongodb.org/browse/JAVA-26</link>
                <project id="10006" key="JAVA">Java Driver</project>
                    <description>&lt;p&gt;there already is a _metadata variable, just not used&lt;/p&gt;</description>
                <environment></environment>
        <key id="10525">JAVA-26</key>
            <summary>support meta data in gridfs</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="9">Done</resolution>
                                        <assignee username="kristina">Kristina Chodorow</assignee>
                                    <reporter username="eliot">Eliot Horowitz</reporter>
                        <labels>
                    </labels>
                <created>Tue, 1 Sep 2009 11:48:10 +0000</created>
                <updated>Fri, 2 Oct 2009 11:38:54 +0000</updated>
                            <resolved>Tue, 1 Sep 2009 19:19:24 +0000</resolved>
                                                    <fixVersion>0.8</fixVersion>
                                                        <votes>1</votes>
                                    <watches>0</watches>
                                                                                                                <comments>
                            <comment id="10635" author="jmsachs" created="Fri, 4 Sep 2009 10:28:49 +0000"  >&lt;p&gt;The class&apos;s members were also changed from protected to private. Probably a good idea but there&apos;s no setters for _metadata available even to subclasses.&lt;/p&gt;

&lt;p&gt;C:\bin\install\servers\mongodb&amp;gt;javap -private -classpath ./mongo-0.8.1.jar com.m&lt;br/&gt;
ongodb.util.gridfs.GridFSObject&lt;br/&gt;
Compiled from &quot;GridFSObject.java&quot;&lt;br/&gt;
public class com.mongodb.util.gridfs.GridFSObject extends java.lang.Object{&lt;br/&gt;
    private com.mongodb.ObjectId _id;&lt;br/&gt;
    private java.lang.String _filename;&lt;br/&gt;
    private java.lang.String _contentType;&lt;br/&gt;
    private long _length;&lt;br/&gt;
    private int _chunkSize;&lt;br/&gt;
    private java.util.Date _uploadDate;&lt;br/&gt;
    private java.util.List _aliases;&lt;br/&gt;
    private com.mongodb.DBObject _metadata;&lt;br/&gt;
    private byte[] _myBuffer;&lt;br/&gt;
    private java.io.InputStream _inStream;&lt;br/&gt;
    private int _nextChunkID;&lt;br/&gt;
    private com.mongodb.util.gridfs.GridFS _gridfs;&lt;br/&gt;
    private com.mongodb.DBCursor _chunkCursor;&lt;br/&gt;
    public com.mongodb.util.gridfs.GridFSObject(java.lang.String, java.io.InputS&lt;br/&gt;
tream);&lt;br/&gt;
    public com.mongodb.util.gridfs.GridFSObject(com.mongodb.util.gridfs.GridFS,&lt;br/&gt;
com.mongodb.DBObject);&lt;br/&gt;
    public com.mongodb.util.gridfs.GridFSObject(com.mongodb.util.gridfs.GridFS,&lt;br/&gt;
com.mongodb.DBObject, com.mongodb.DBObject);&lt;br/&gt;
    public java.io.InputStream getInputStream();&lt;br/&gt;
    protected com.mongodb.util.gridfs.GridFSChunk getNextChunkFromDB();&lt;br/&gt;
    protected com.mongodb.util.gridfs.GridFSChunk getNextChunkFromStream()&lt;br/&gt;
 throws java.io.IOException;&lt;br/&gt;
    public java.lang.String getFilename();&lt;br/&gt;
    public void setFilename(java.lang.String);&lt;br/&gt;
    public java.lang.String getContentType();&lt;br/&gt;
    public void setContentType(java.lang.String);&lt;br/&gt;
    protected void setLength(long);&lt;br/&gt;
    public com.mongodb.ObjectId getID();&lt;br/&gt;
    public com.mongodb.DBObject getMetadata();&lt;br/&gt;
    public com.mongodb.DBObject getDBObject();&lt;br/&gt;
}&lt;/p&gt;
</comment>
                            <comment id="10633" author="jmsachs" created="Fri, 4 Sep 2009 10:19:35 +0000"  >&lt;p&gt;please reopen.... looks like it is possible to read metadata but not write metadata. There are still some things missing:&lt;/p&gt;

&lt;p&gt;1) GridFSObject has a constructor (GridFS, DBObject, DBObject metadata) as an alternative to constructtor (GridFS, DBObject), but not a constructor (String, InputStream, DBObject metadata) as an alternative to constructor (String, InputStream). By the way, what is the proper use for the different constructors? The String/InputStream one makes sense (then you call GridFS.write(gridFSObject) on the GridFSObject you created, but I can&apos;t make heads or tails of the (GridFS, DBObject) constructor. Does it automatically write to the GridFS in question? What data gets stored?&lt;br/&gt;
2) GridFSObject.getMetadata() exists, but not GridFSObject.setMetadata()&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|hrhdnz:</customfieldvalue>

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