<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 08:56:39 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-2223] support interfaces for field types</title>
                <link>https://jira.mongodb.org/browse/JAVA-2223</link>
                <project id="10006" key="JAVA">Java Driver</project>
                    <description>&lt;p&gt;If a field is declared to be a &lt;tt&gt;Foo&lt;/tt&gt; where &lt;tt&gt;Foo&lt;/tt&gt; is an interface, we need a mechanism to indicate the concrete class to instantiate when deserializing.  For embedded entities we can rely on the discriminator value in the nested document.  For the case where &lt;tt&gt;foo&lt;/tt&gt; is a &lt;tt&gt;enum&lt;/tt&gt; that implements &lt;tt&gt;Foo&lt;/tt&gt;, we lack sufficient context to rehydrate those objects.  Options:&lt;/p&gt;

&lt;ol&gt;
	&lt;li&gt;Require an annotation (or programmatic configuration) to define the concrete class.  The container types (&lt;tt&gt;List&lt;/tt&gt;/&lt;tt&gt;Map&lt;/tt&gt;/&lt;tt&gt;Set&lt;/tt&gt;) already use this to guess at the appropriate container type to create.  We could expose this for use in the more general case&lt;/li&gt;
	&lt;li&gt;We could serialize these cases as documents containing &lt;tt&gt;_t&lt;/tt&gt; with the concrete type and the value.  This would make queries slightly awkward outside of Java so that&apos;s slightly less attractive.  It&apos;s more flexible at runtime though since we&apos;re not tying that interface implementation to just one type which kind of defeats the purpose of programming to interfaces.&lt;/li&gt;
&lt;/ol&gt;
</description>
                <environment></environment>
        <key id="293544">JAVA-2223</key>
            <summary>support interfaces for field types</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="-1">Unassigned</assignee>
                                    <reporter username="justin.lee">Justin Lee</reporter>
                        <labels>
                    </labels>
                <created>Mon, 13 Jun 2016 20:39:11 +0000</created>
                <updated>Mon, 3 Apr 2017 15:09:50 +0000</updated>
                            <resolved>Mon, 3 Apr 2017 15:09:49 +0000</resolved>
                                                    <fixVersion>3.5.0</fixVersion>
                                    <component>Codecs</component>
                                        <votes>0</votes>
                                    <watches>1</watches>
                                                                                                                <comments>
                            <comment id="1539315" author="ross@10gen.com" created="Mon, 3 Apr 2017 15:09:50 +0000"  >&lt;p&gt;See &lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-1812&quot; title=&quot;Codec support for POJOs&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-1812&quot;&gt;&lt;del&gt;JAVA-1812&lt;/del&gt;&lt;/a&gt; for the commit containing the commit covering this ticket.&lt;/p&gt;</comment>
                            <comment id="1525782" author="ross@10gen.com" created="Thu, 16 Mar 2017 15:12:44 +0000"  >&lt;p&gt;Other than List/Map/Set I&apos;m not sure what other specialisation we need.  As long as you have a codec for the field&apos;s class then it will hydrate as required and cast to the interface type.&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_10857" key="com.pyxis.greenhopper.jira:gh-epic-link">
                        <customfieldname>Epic Link</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>JAVA-1812</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hrc7f3:</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>