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

Chetan Mehrotra edited comment on OAK-1312 at 8/24/16 9:48 AM:
---------------------------------------------------------------

As a crude test started an Oak based large app and against empty db (Mongo 
2.6.4 yes its old!)
* Without bundling
{code:javascript}
$db.nodes.stats(1024*1024)
{
        "ns" : "aem-author-63.nodes",
        "count" : 451216,
        "size" : 313,
        "avgObjSize" : 729,
        "storageSize" : 439,
        "numExtents" : 15,
        "nindexes" : 5,
        "lastExtentSize" : 119,
        "paddingFactor" : 1.0260000000001268,
        "systemFlags" : 1,
        "userFlags" : 1,
        "totalIndexSize" : 180,
        "indexSizes" : {
                "_id_" : 86,
                "_modified_1__id_1" : 93,
                "_bin_1" : 0,
                "_deletedOnce_1" : 0,
                "_sdType_1" : 0
        },
        "ok" : 1
}
{code}
* With bundling
{code:javascript}
$db.nodes.stats(1024*1024)
{
        "ns" : "aem-author-63-2.nodes",
        "count" : 422347,
        "size" : 320,
        "avgObjSize" : 796,
        "storageSize" : 439,
        "numExtents" : 15,
        "nindexes" : 5,
        "lastExtentSize" : 119,
        "paddingFactor" : 1.364000000000087,
        "systemFlags" : 1,
        "userFlags" : 1,
        "totalIndexSize" : 170,
        "indexSizes" : {
                "_id_" : 81,
                "_modified_1__id_1" : 88,
                "_bin_1" : 0,
                "_deletedOnce_1" : 0,
                "_sdType_1" : 0
        },
        "ok" : 1
}

{code}

So around ~30k lesser Mongo docs and 5 MB reduction in total index size. 
Runtime performance impact via some benchmark yet to be done!


was (Author: chetanm):
As a crude test started an Oak based large app and against empty db
* Without bundling
{code:javascript}
$db.nodes.stats(1024*1024)
{
        "ns" : "aem-author-63.nodes",
        "count" : 451216,
        "size" : 313,
        "avgObjSize" : 729,
        "storageSize" : 439,
        "numExtents" : 15,
        "nindexes" : 5,
        "lastExtentSize" : 119,
        "paddingFactor" : 1.0260000000001268,
        "systemFlags" : 1,
        "userFlags" : 1,
        "totalIndexSize" : 180,
        "indexSizes" : {
                "_id_" : 86,
                "_modified_1__id_1" : 93,
                "_bin_1" : 0,
                "_deletedOnce_1" : 0,
                "_sdType_1" : 0
        },
        "ok" : 1
}
{code}
* With bundling
{code:javascript}
$db.nodes.stats(1024*1024)
{
        "ns" : "aem-author-63-2.nodes",
        "count" : 422347,
        "size" : 320,
        "avgObjSize" : 796,
        "storageSize" : 439,
        "numExtents" : 15,
        "nindexes" : 5,
        "lastExtentSize" : 119,
        "paddingFactor" : 1.364000000000087,
        "systemFlags" : 1,
        "userFlags" : 1,
        "totalIndexSize" : 170,
        "indexSizes" : {
                "_id_" : 81,
                "_modified_1__id_1" : 88,
                "_bin_1" : 0,
                "_deletedOnce_1" : 0,
                "_sdType_1" : 0
        },
        "ok" : 1
}

{code}

So around ~30k lesser Mongo docs and 5 MB reduction in total index size. 
Runtime performance impact via some benchmark yet to be done!

> Bundle nodes into a document
> ----------------------------
>
>                 Key: OAK-1312
>                 URL: https://issues.apache.org/jira/browse/OAK-1312
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: core, documentmk
>            Reporter: Marcel Reutegger
>            Assignee: Chetan Mehrotra
>              Labels: performance
>             Fix For: 1.6
>
>         Attachments: OAK-1312-meta-prop-handling.patch, 
> OAK-1312-review-v1.diff, OAK-1312-review-v2.diff
>
>
> For very fine grained content with many nodes and only few properties per 
> node it would be more efficient to bundle multiple nodes into a single 
> MongoDB document. Mostly reading would benefit because there are less 
> roundtrips to the backend. At the same time storage footprint would be lower 
> because metadata overhead is per document.
> Feature branch - 
> https://github.com/chetanmeh/jackrabbit-oak/compare/trunk...chetanmeh:OAK-1312



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

Reply via email to