github vaticle/typedb 1.5.7
Grakn Core 1.5.7

latest releases: 2.28.0, 2.28.0-rc0, 2.27.0...
4 years ago

Install & Run: http://dev.grakn.ai/docs/running-grakn/install-and-run

Bugs Fixed

  • Reiterate if disconnected inferrable atoms present.
    Due to the way query caching and reasoning works, in the case we have disconnected inferrable subqueries within the query of interest, some results might be missed if we do not reiterate. We fix that by adding an extra reiteration condition.

  • Prefixed artifact IDs of Maven packages with 'grakn-'.
    When deploying Maven JARs to Sonatype, the JARs are renamed to be artifact-id-version.jar, without the group-id. This is done in Sonatype because the JARs are organised into folders where the folder names represent the Group IDs. However, in certain build systems, e.g. Gradle, the JARs are collected under one directory, which means the JAR names are not unique enough to disambiguate itself from each other. We have now renamed the artifact ID of our Maven packages to be prefixed with grakn- to solve this problem.

  • Do not attach base attributes when infering sub attributes.
    Previously, when inferring attributes based on existing attributes, we tried to reuse the existing concepts. This leads to unconsistencies:

    • we created an implicit relation of the base, not sub type
    • we would use an inconsistent attribute index - base and sub attributes of the same value have different indices. This PR ensures if we are dealing with attribute attachments when hierarchies are involved, we explicitly create a new attribute of the specific type.
  • Update query cache behaviour on insertions and deletions.
    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.

  • Correctly materialise implicit relations.
    Previously, when querying for generic relations, if we encounter a rule which inferred an attribute, we would convert it to an implicit relations. When materialising these, we could encounter situations when the insert would fail - an implicit relation where the attribute role player is only specified by the value and type. In this PR in such cases, for materialisation we convert it back to a resource so all information is at hand.

  • Delete Concepts - sync in Janus tx cache.
    Avoid a Ghost Vertex bug that occurs when deleting a concept. This was finally found to be caused by a mismatch between what exists in the Janus TX cache and our own tx cache. Also a bugfix for querying edge relations (implicit attr ownerships) not returning the edge but the start vertex instead.

Code Refactors

  • Remove obsolete use of neqPositive.
    Remove the use of neqPositive which is obsolete after the changes introduced in #5226. The use of neqPositive in the current context leads to potential issues - if a query contains !== predicates with a value, they might be omitted if other variable predicates are present. This PR fixes that.

  • Do not flush completeness when inserting inferred concepts.
    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.

  • Update rule priority calculation to take into account type hierarchy.
    Update rule priority calculation to include type hierarchy information of the type of the head of the rule.

  • reasoner package cleanup.
    Cleanup and simplify the reasoner package.

  • Update and cleanup QueryIT tests.
    Remove redundant tests an update ones that are ignored

  • Cleanup and expand materialisation tests.
    To cleanup and expand materialisation tests so that the behaviours are explicitly defined.

  • Do no use locks when initialising system keyspace.
    Remove unused locking mechanism when initialising Grakn system keyspace.

  • Cleanup code in TransactionOLTP and ElementFactory.
    Cleanup code in TransactionOLTP and ElementFactory.
    Centralise operations on janusTransaction (i.e. addVertex(), close() and commit()) inside TransactionOLTP.

  • Split //protocol to new repo: graknlabs/protocol.
    Previously, for a Grakn Client driver to be implemented in a new language, the client repository has to depend on this (grakn-core) repository. This is a heavy-weight dependency, just to be able to depend on the //protocol package that contains the gRPC Protobuf definitions. People worked around this by copy-pasting the //protocol source code into their repository, and this is obviously not a safe and maintainable way to depend on the source code. This issue also contributed to the cyclic-dependency between Grakn Core and Client Java (issue #5272). The client drivers (e.g. client-nodejs and client-python) also suffered from very frequent dependency update from grakn-core sync-dependencies, because a new commit happens frequently in grakn-core albeit not changing any source code in //protocol.
    We have now split //protocol into a new repository of its own: graknlabs/protocol (Feel free to HIT STAR!). This will allow our open source community to depend directly onto the new repository to implement new client drivers, reduce the cause of cyclic-dependency between Grakn Core and Client Java, and significantly reduce the number of commits in client driver repositories caused by sync-dependencies from Grakn Core.
    By sitting in its own repository, the Grakn Protocol repository will be able to aggregate the gRPC Protobuf definitions for both Grakn Core and KGMS; i.e. define the RPC service for Grakn Core functionalities and also KGMS functionalities such as User Management. This would allow all client drivers to communicate with both Grakn Core and Grakn KGMS. Last but not least, the protocol can now have an independent release cycle from Grakn Core and KGMS.
    PS: To depend on graknlabs/protocol, you have several options:

    1. Depend on the repository directly, e.g. using build systems like Bazel
    2. Add graknlabs/protocol as a submodule in your repository
    3. Depend on Grakn Protocol distribution through a package manager. We will start with deploying to Maven, PyPI, and NPM, but feel free to ask us to a package manager of the language you'll be developing in!
  • Simplify attribute equivalence.
    Simplify attribute atom equivalence by using the approach previously used for relation atoms - we check for unifiability. This makes tracing the predicate bindings easier and allows to remove redundant code.

  • Do not rewrite rule body variables.
    Remove a feature that is no longer needed - rewriting variables of bodies of rules to be returned.

Don't miss a new typedb release

NewReleases is sending notifications on new releases.