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 "Thomas Mueller (Jira)" <ji...@apache.org> on 2020/11/24 14:42:00 UTC

[jira] [Commented] (OAK-6911) Provide a way to tune inline size while storing binaries

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

Thomas Mueller commented on OAK-6911:
-------------------------------------

I think it's enough to change the place where binaries are written: org.apache.jackrabbit.oak.segment.DefaultSegmentWriter:

{noformat}
    private RecordId internalWriteStream(@NotNull InputStream stream) throws IOException {
            // Special case for short binaries (up to about 16kB):
            // store them directly as small- or medium-sized value records
            byte[] data = new byte[Segment.MEDIUM_LIMIT];
            int n = read(stream, data, 0, data.length);
            if (n < Segment.MEDIUM_LIMIT) {  <<<<<==== this would need to be changed
                return writeValueRecord(n, data);
            }
{noformat}


> Provide a way to tune inline size while storing binaries
> --------------------------------------------------------
>
>                 Key: OAK-6911
>                 URL: https://issues.apache.org/jira/browse/OAK-6911
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: segment-tar
>            Reporter: Chetan Mehrotra
>            Priority: Major
>              Labels: performance, scalability
>             Fix For: 1.38.0
>
>
> SegmentNodeStore currently inlines binaries of size less that 16KB (Segment.MEDIUM_LIMIT) even if external BlobStore is configured. 
> Due to this behaviour quite a bit of segment tar storage consist of blob data. In one setup out of 370 GB segmentstore size 290GB is due to inlined binary. If most of this binary content is moved to BlobStore then it would allow same repository to work better in lesser RAM
> So it would be useful if some way is provided to disable this default behaviour and let BlobStore take control of inline size i.e. in presence of BlobStore no inlining is attempted by SegmentWriter.



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