You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ignite.apache.org by "Valentin Kulichenko (JIRA)" <ji...@apache.org> on 2015/09/25 04:13:04 UTC

[jira] [Commented] (IGNITE-1542) MetaDataEnabled flag is partially ignored when set in PortableTypeConfiguration

    [ https://issues.apache.org/jira/browse/IGNITE-1542?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14907409#comment-14907409 ] 

Valentin Kulichenko commented on IGNITE-1542:
---------------------------------------------

Denis,

We can't do this. We now save metadata for any registered classes because it can potentially contain affinity key field name. Otherwise collocation can be broken if metadata is disabled. But fields info is still not collected in this case, there are tests for this: {{GridPortableMetaDataDisabledSelfTest}}.

> MetaDataEnabled flag is partially ignored when set in PortableTypeConfiguration
> -------------------------------------------------------------------------------
>
>                 Key: IGNITE-1542
>                 URL: https://issues.apache.org/jira/browse/IGNITE-1542
>             Project: Ignite
>          Issue Type: Bug
>          Components: general
>    Affects Versions: ignite-1.4
>            Reporter: Denis Magda
>            Assignee: Denis Magda
>            Priority: Critical
>             Fix For: ignite-1.5
>
>
> Define a type using {{PortableTypeConfiguration}} and disable meta data for the type by setting {{metaDataEnabled}} flag to false.
> Then set this portable type configuration in {{PortableMarshaller's}} configuration list and start a node.
> Despite of the fact that the metadata is disable for the type it will be added to the metadata handler.
> The fix is trivial.
> Change last line of {{PortableContext.registerUserType()}} to:
> {noformat}
> if (metadataenabled)
> metaHnd.addMeta(id, new PortableMetaDataImpl(typeName, fieldsMeta, affKeyFieldName));
> {noformat}
> Add tests.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)