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 "Marcel Reutegger (JIRA)" <ji...@apache.org> on 2016/06/23 10:26:16 UTC

[jira] [Commented] (OAK-4497) RDBDocumentStore: potential race condition between update and invalidate can cause stale cache entries

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

Marcel Reutegger commented on OAK-4497:
---------------------------------------

Shouldn't {{invalidateNodesCache(String id, boolean remove)}} call {{nodeCache.markChanged(id)}} unconditionally for the {{remove == false}} case? Consider a slow query that read a document which is subsequently modified. The invalidate call after the modification may see a cache that does not have the document in the cache and will not signal to the query that it must not put the document in the cache. The query is now able to put an outdated document into the cache.

> RDBDocumentStore: potential race condition between update and invalidate can cause stale cache entries
> ------------------------------------------------------------------------------------------------------
>
>                 Key: OAK-4497
>                 URL: https://issues.apache.org/jira/browse/OAK-4497
>             Project: Jackrabbit Oak
>          Issue Type: Technical task
>          Components: rdbmk
>    Affects Versions: 1.0.31, 1.4.3, 1.2.16, 1.5.4
>            Reporter: Julian Reschke
>            Assignee: Julian Reschke
>              Labels: candidate_oak_1_0, candidate_oak_1_2, candidate_oak_1_4
>             Fix For: 1.6, 1.5.4, 1.0.32, 1.4.4, 1.2.17
>
>         Attachments: OAK-4497.diff
>
>
> The test in OAK-4489 shows that concurrency of queries and invalidations can cause validations to be lost, leading to stale content in the cache.



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