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 "Francesco Mari (JIRA)" <ji...@apache.org> on 2016/09/27 09:51:21 UTC

[jira] [Resolved] (OAK-4812) Reduce calls to SegmentStore#newSegmentId from the Segment class

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

Francesco Mari resolved OAK-4812.
---------------------------------
       Resolution: Fixed
    Fix Version/s: Segment Tar 0.0.14

The change for OAK-4844 should have fixed this problem. The record ID cache was replaced by a segment ID cache, and record IDs consume segment IDs from this cache instead of creating new ones if possible. Some benchmark results are attached to OAK-4844. Resolving this issue as fixed.

> Reduce calls to SegmentStore#newSegmentId from the Segment class
> ----------------------------------------------------------------
>
>                 Key: OAK-4812
>                 URL: https://issues.apache.org/jira/browse/OAK-4812
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: segment-tar
>            Reporter: Alex Parvulescu
>            Assignee: Francesco Mari
>            Priority: Minor
>             Fix For: Segment Tar 0.0.14
>
>
> OAK-4631 introduced a change in records handling in a segment that will amplify the number of calls to {{SegmentStore#newSegmentId}} by the number of external references [0]. It usually is the case that there are a lot of record references that point to the same segment id, and the existing {{recordIdCache}} would not help much in this case.
> The scenario I'm seeing for offline compaction (might be a bit biased) is a full traversal of segments that increases pressure on the {{SegmentIdTable}} by calling {{newSegmentId}} with a lot of already existing segments.
> I'm creating this issue as an 'Improvement' as I think it is interesting to look into reducing this pressure. This might be by squeezing more out of the {{SegmentIdTable}} bits (I'd like to followup on this with a benchmark) or revisiting the code paths from the {{Segment}} class.
> [0] https://github.com/apache/jackrabbit-oak/blob/trunk/oak-segment-tar/src/main/java/org/apache/jackrabbit/oak/segment/Segment.java#L405



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