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

Michael Dürig commented on OAK-4732:
------------------------------------

Patch looks good to me. Maybe we increase the 
{{SynchronizedDescriptiveStatistics}} window a bit? 1000 instead of 100? 

As a follow up, it would be good to add a feature flag to control this feature 
if this turns out to be necessary. One way would be to add a flag to configure 
the percentile used in {{LockBasedScheduler.getHeadNodeState()}}. Setting it to 
{{0}} would basically disable this. Setting it to a different value might be 
interesting in future experiments. 

> (Slightly) prioritise reads over writes 
> ----------------------------------------
>
>                 Key: OAK-4732
>                 URL: https://issues.apache.org/jira/browse/OAK-4732
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: segment-tar
>            Reporter: Michael Dürig
>            Assignee: Andrei Dulceanu
>            Priority: Minor
>              Labels: Performance, scalability
>             Fix For: 1.8, 1.7.4
>
>         Attachments: OAK-4732.patch
>
>
> When fetching the current root from the {{SegmentNodeStore}} an older 
> revision will be returned when a commit is being processed concurrently. I 
> think it would make sense to wait for a short time in this case increasing 
> the chance of returning an up to date state. The idea is that this would 
> lower the rebasing work that need to be done later on should the returned 
> root be used for further modifications. 
> An interesting value for the wait time is to use  the median (or more general 
> a percentile) of the commit time of the last say 1000 commits. This would 
> mean that (for the median) we have a 50% chance of getting up to date date. 
> For a 90% percentile we would have longer wait times but then a 90% chance of 
> getting up to date date. 



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to