You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jena.apache.org by "Andy Seaborne (Jira)" <ji...@apache.org> on 2019/11/28 15:23:00 UTC
[jira] [Commented] (JENA-1785) A newly created node can remain
invisible after commit
[ https://issues.apache.org/jira/browse/JENA-1785?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16984489#comment-16984489 ]
Andy Seaborne commented on JENA-1785:
-------------------------------------
Thank you for bring this up. It will will need some thinking about. In TDB1, the "miss" cache makes a difference because it stops going to the storage node table.
But the node cache is an area of difference between TDB1 and TDB2.
From a first pass over TDB2 NodeTableCache java comments, it looks like it may be a failure to manage the miss cache correctly.
> A newly created node can remain invisible after commit
> ------------------------------------------------------
>
> Key: JENA-1785
> URL: https://issues.apache.org/jira/browse/JENA-1785
> Project: Apache Jena
> Issue Type: Bug
> Components: TDB2
> Affects Versions: Jena 3.13.0, Jena 3.13.1
> Reporter: Pavel Mikhailovskii
> Assignee: Andy Seaborne
> Priority: Critical
> Attachments: TestVisibilityOfChanges.java
>
> Time Spent: 10m
> Remaining Estimate: 0h
>
> A node once marked as non-present (_NodeTableCache.nonPresent_) can remain invisible even after it's created and the transaction is committed. That might happen because there's no guarantee that *all* newly created nodes will be eventually added to the "base" version _ThreadBufferingCache.baseCache_ of the _node2id_Cache_ (as the _localCache_ has limited capacity) or removed from the "base" version of the _nonPresent_ cache (even if they were, there would still be a chance of re-adding them by some read transaction).
> The simplest fix is to get rid of the _nonPresent_ cache which seems to be of limited use anyway. A more sophisticated fix would involve keeping track of all newly allocated nodes and their removal from the base version of _nonPresent_ cache on transaction commit.
> To reproduce: see the attached test.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)