Skip to content

QubitPi/aristotle

Repository files navigation

GitHub workflow status Last commit Discord License Badge

SonarCloud

Bugs Vulnerabilities Security Rating

Coverage Code Smells Maintainability Rating

Lines of Code Duplicated Lines (%) Reliability Rating Technical Debt

Aristotle is a Java library that lets you set up GraphQL webservice with minimal effort. Aristotle is meant to be specialized on querying knowledge graph data.

心海

Aristotle has first-class support for Neo4j and Memgraph databases for graph data storage back-ends, but Aristotle's flexible pipeline-style architecture can handle nearly any back-end for data storage, such as ArangoDB.

Quick Start

Aristotle comes with a pre-configured example application to help you get started and serve as a jumping-off-point for building your own web service using Aristotle.

Features

Storage Abstraction

One of the design principles of Aristotle is to abstract lower layers of storage away from the administrators and applications. Data is exposed and managed as a graph of objects through GraphQL API. They do not have to perform lower-level storage functions like constructing and managing logical volumes to utilize disk capacity or setting RAID levels to deal with disk failure.

Programmatic Data Management

Aristotle provides programmatic interfaces to allow applications to manipulate data. At the base level, this includes create, read, and delete (CRUD) functions for basic read, write and delete operations. The API implementations are GraphQL-based, allowing the use of many standard HTTP calls.

Documentation

More information about Aristotle can be found here

Binaries (How to Get It) GitHub Workflow Status

Binaries for Aristotle are stored in GitHub Packages. To install the packages from there, edit the pom.xml file to include the package as a dependency. Dependency information for each Aristotle sub-module can be found at their corresponding package page. For example:

<dependency>
    <groupId>com.qubitpi.aristotle</groupId>
    <artifactId>aristotle-core</artifactId>
    <version>x.y.z</version>
</dependency>

Next, include the following snippet in the project's POM

<project>
    ...

    <repositories>
        <repository>
            <id>download-from-github-qubitpi</id>
            <name>Download QubitPi's GitHub Packages</name>
            <releases>
                <enabled>true</enabled>
            </releases>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
            <url>https://maven.pkg.github.com/QubitPi/aristotle</url>
        </repository>
    </repositories>
</project>

Lastly, we would need an access token to install Aristotle packages. Aristotle uses a personal access token (PAT), with packages:read scope, to authenticate to GitHub Packages. Your project can authenticate to GitHub Packages with Apache Maven by editing your ~/.m2/settings.xml file to include the personal access token:

<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
          xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0
                      http://maven.apache.org/xsd/settings-1.0.0.xsd">

    <activeProfiles>
        <activeProfile>download-from-github-qubitpi</activeProfile>
    </activeProfiles>

    <profiles>
        <profile>
            <id>download-from-github-qubitpi</id>
            <repositories>
                <repository>
                    <id>download-from-github-qubitpi</id>
                    <url>https://maven.pkg.github.com/qubitpi/aristotle</url>
                    <snapshots>
                        <enabled>false</enabled>
                    </snapshots>
                </repository>
            </repositories>
        </profile>
    </profiles>

    <servers>
        <server>
            <id>download-from-github-qubitpi</id>
            <username>anybody</username>
            <!-- https://stackoverflow.com/a/64443958/14312712 -->
            <password>a personal access token with at least packages:read scope</password>
        </server>
    </servers>
</settings>

License

The use and distribution terms for Aristotle are covered by the Apache License, Version 2.0.