You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ignite.apache.org by "Andrey Mashenkov (Jira)" <ji...@apache.org> on 2021/11/18 19:02:00 UTC

[jira] [Updated] (IGNITE-15949) Support inherited classes in Mappers.

     [ https://issues.apache.org/jira/browse/IGNITE-15949?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrey Mashenkov updated IGNITE-15949:
--------------------------------------
    Summary: Support inherited classes in Mappers.  (was: Support class hierarchy in Mappers.)

> Support inherited classes in Mappers.
> -------------------------------------
>
>                 Key: IGNITE-15949
>                 URL: https://issues.apache.org/jira/browse/IGNITE-15949
>             Project: Ignite
>          Issue Type: Improvement
>            Reporter: Andrey Mashenkov
>            Priority: Major
>              Labels: iep-54, ignite-3
>
> Mappers support only POJOs that extend the Object class.
> It looks possible to map more complex objects to the table columns. 
> E.g. class B in the code example below, could be mapped to the schema with columns
> {f1:INT32, f2: INT64}
> However, parent fields could be hidden in descendants (see class C in the example below). The default behavior in the case should be failing.
> One could use annotations to map hidden fields to a different column,
> but there should be a way to express this programmatically with a mapper (without annotations).
> {code:java}
> class A {
>     int f1;
> }
> class B extends A {
>     long f2
> }
> class C extends A {
>    int f1; // Hides field A.f1
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)