[
https://issues.apache.org/jira/browse/OAK-6074?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15981370#comment-15981370
]
Michael Dürig commented on OAK-6074:
------------------------------------
I'll have a look tomorrow. Sorry for the delay.
> Simplify merge logic in LockBasedScheduler
> ------------------------------------------
>
> Key: OAK-6074
> URL: https://issues.apache.org/jira/browse/OAK-6074
> Project: Jackrabbit Oak
> Issue Type: Task
> Components: segment-tar
> Reporter: Andrei Dulceanu
> Assignee: Andrei Dulceanu
> Priority: Minor
> Fix For: 1.8, 1.7.3
>
> Attachments: OAK-6074.patch
>
>
> The current logic for executing a commit in {{LockBasedScheduler}} is
> unnecessarily intricate, containing separate strategies for optimistic and
> pessimistic merges. While these would have made sense in a hierarchical,
> multi-journal approach, when using a single journal file we always end up on
> the optimistic merge branch, since a commit semaphore is acquired before
> attempting to merge the commit. The proposal is to remove
> {{LockBasedScheduler#optimisticMerge}} and
> {{LockBasedScheduler#pessimisticMerge}} methods, simplifying the logic inside
> {{LockBasedScheduler#execute}}.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)