[
https://issues.apache.org/jira/browse/OAK-3587?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14989945#comment-14989945
]
Chetan Mehrotra commented on OAK-3587:
--------------------------------------
Patch looks fine!
However not sure about all those config option. I was never clear on the
existing behaviour where checkpoing logic was non deterministic. It would be
just fine to always go for lock acquire directly (possibly with a timeout) just
like its being done in {{merge}} call as its an important operation.
Also we can have a separate catch for InterupptedException for the timeout part
and log a info message instead as its expected
> SegmentNodeStore should ensure that checkpoint is issued in case of frequent
> writes by taking an exclusive lock
> ---------------------------------------------------------------------------------------------------------------
>
> Key: OAK-3587
> URL: https://issues.apache.org/jira/browse/OAK-3587
> Project: Jackrabbit Oak
> Issue Type: Improvement
> Components: segmentmk
> Reporter: Chetan Mehrotra
> Assignee: Alex Parvulescu
> Fix For: 1.3.10, 1.2.8, 1.0.24
>
> Attachments: OAK-3587.patch
>
>
> AsyncIndexUpdate proceeds with an indexing cycle only if the NodeStore issues
> a checkpoint. A NodeStore implementation can issue a checkpoint but for it to
> be valid the caller must fetch NodeState for that checkpoint. If a non null
> NodeState is found it indicates that checkpoint is valid.
> With SegmentNodeStore its possible under high write conditions that
> checkpoint issues is not valid as it only attempts an optimistic lock. This
> can cause unbounded delays in acquiring a valid checkpoint and thus cause
> delay in AsyncIndexUpdate cycle and that causes effect on queries which rely
> on such async indexes.
> Instead of doing an optimistic lock it should attempt to acquire an exclusive
> lock. See [1] for some more details on checkpoint behaviour
> [1] http://markmail.org/thread/c7zo3zju7e2hakg4
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)