You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "José Andrés Cordero Benítez (Jira)" <ji...@apache.org> on 2020/07/17 08:06:00 UTC

[jira] [Comment Edited] (OAK-9134) Remove mix:referenceable from nt:frozenNode definition

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

José Andrés Cordero Benítez edited comment on OAK-9134 at 7/17/20, 8:05 AM:
----------------------------------------------------------------------------

Added a new patch [^OAK-9134-remove-referenceable-frozenNode-2.patch]

I haven't added a check to see if the built-in nodetypes are already registered because the last argument of the method *CndImporter.registerNodeTypes* sets if the definitions will be rewrited or not, and it is set to false when importing the cnd file:

I have added the system property *oak.referenceableFrozenNode* to control if the repository is initialized or not with nt:frozenNode implementing mix:referenceable.

Finally, the solution I have implemented edits internally the inputStream of the *builtin_nodetypes.cnd* file, which I don't think is an elegant solution, but I wanted to avoid editing the *CndImporter.registerNodeTypes* which belongs to Jackrabbit.

As a reminder, the patch [^OAK-9134-remove-referenceable-from-test.patch] has to be applied to Jackrabbit, as that tests checks explicitly if nt:frozenNodes implements mix:referenceable.


was (Author: corderob):
Added a new patch [^OAK-9134-remove-referenceable-frozenNode-2.patch]

I haven't added a check to see if the built-in nodetypes are already registered because the last argument of the method *CndImporter.registerNodeTypes* sets if the definitions will be rewrited or not, and it is set to false when importing the cnd file:

I have added the system property *oak.referenceableFrozenNode* to control if the repository is initialized or not with nt:frozenNode implementing mix:referenceable.

Finally, the solution I have implemented edits internally the inputStream of the *builtin_nodetypes.cnd* file, which I don't think is an elegant solution, but I wanted to avoid editing the *CndImporter.registerNodeTypes* which belongs to Jackrabbit.

> Remove mix:referenceable from nt:frozenNode definition
> ------------------------------------------------------
>
>                 Key: OAK-9134
>                 URL: https://issues.apache.org/jira/browse/OAK-9134
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: core, jcr
>            Reporter: José Andrés Cordero Benítez
>            Priority: Minor
>              Labels: patch
>         Attachments: OAK-9134-remove-referenceable-from-test.patch, OAK-9134-remove-referenceable-frozenNode-2.patch, OAK-9134-remove-referenceable-frozenNode.patch
>
>
> One of the changes between JCR 1.0 and JCR 2.0 is the definition of nt:frozenNode. In JCR 1.0 the node type extends from mix:referenceable, while in JCR 2.0 it does [not anymore|https://docs.adobe.com/docs/en/spec/jcr/2.0/3_Repository_Model.html#3.13.4.1%20nt:frozenNode].
> Oak currently uses a nt:frozenNode definition that extends from mix:referenceable. This adds quite a bit of overhead because each node written under a JCR version gets a jcr:uuid, which is indexed by default.
> The proposal is to remove the supertype "mix:referenceable" from nt:frozenNode.
> Removing this supertype, the frozenNodes wouldn't have a "jcr:uuid" field, which at the end is not used, and allows to reduce the size of the index.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)