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 "Michael Dürig (JIRA)" <ji...@apache.org> on 2017/06/07 09:22:18 UTC

[jira] [Resolved] (OAK-2968) Reduce commits memory footprint of ModifiedNodeState

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

Michael Dürig resolved OAK-2968.
--------------------------------
    Resolution: Not A Problem

This should not be a problem when using the {{NodeBuilder}} API as the underlying store should write ahead changes to the store once there are many. 

> Reduce commits memory footprint of ModifiedNodeState
> ----------------------------------------------------
>
>                 Key: OAK-2968
>                 URL: https://issues.apache.org/jira/browse/OAK-2968
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: core
>    Affects Versions: 1.2.2
>            Reporter: Timothee Maret
>              Labels: perfomance
>
> As described in [0] large commits consume a fair amount of memory. With very large commits, this become problematic as commits may eat up 100GB or more and thus causing OOME and aborting the commit.
> The current representation of commits in memory uses a tree which each node contains HashMaps for the changed properties as well as sub-nodes.
> In cases where the tree is deep but not sparse, most of the children HashMaps will contain 1 element yet they are created with the default capacity (16) thus wasting space.
> This issue covers a simple way to reduce the memory consumption in this case by simply creating HashMaps of the required capacity (where applicable) or of minimal capacity (1) where unknown.
> [0] http://permalink.gmane.org/gmane.comp.apache.jackrabbit.oak.devel/8196



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)