Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update query cache behaviour on insertions and deletions #5300

Merged

Conversation

kasper-piskorski
Copy link
Contributor

@kasper-piskorski kasper-piskorski commented Jul 1, 2019

What is the goal of this PR?

To make the query cache acknowledge updates - respond to insertions and deletions of concepts. That is to ensure that the inserted information is included in the result and the deleted information is excluded from the results.

What are the changes implemented in this PR?

  • we make the query cache acknowledge insertions of concepts - if a concept gets inserted, we flush all query completions. That ensures that the new concept will be captured when queried after the insertion.
  • we make the query cache acknowledge deletion of concepts - if a concept gets deleted, all entries linked to its type as well as dependent types get flushed. Additionally we clear query completeness. That ensures that any mentions of the deleted concept are removed from the cache.

@kasper-piskorski kasper-piskorski changed the title update cache behaviour on insertions and deletions Update query cache behaviour on insertions and deletions Jul 1, 2019
@kasper-piskorski kasper-piskorski added this to the 1.5.7 milestone Jul 1, 2019
@kasper-piskorski kasper-piskorski merged commit 6d432b9 into vaticle:master Jul 2, 2019
kasper-piskorski added a commit that referenced this pull request Jul 4, 2019
## What is the goal of this PR?

Previously (#5300) we introduced cache flushing mechanism for insertions and deletions. The added behaviour flushes too often however - the completion is flushed on insertion of inferred concepts. Insertion of inferred concepts is an integral part of the reasoning and it doesn't require any extra mechanisms to ensure the query cache is up to date. As a result of flushing on insertion of inferred concepts we potentially need to do extra db checks to guarantee answer completion.

## What are the changes implemented in this PR?
- we do not ack a concept insertion in the query cache if the concept is inferred
- we reinstate the extra head satisfiability check
@kasper-piskorski kasper-piskorski deleted the query-cache-update branch December 2, 2019 15:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants