Public | Automated Build

Last pushed: 3 months ago
Short Description
Blazegraph
Full Description

Supported tags and respective Dockerfile links

What is Blazegraph?

Blazegraph™ is a standards-based, high-performance, scalable, open-source graph database. Written entirely in Java, the platform supports Blueprints and RDF/SPARQL 1.1 family of specifications, including Query, Update, Basic Federated Query, and Service Description.

For more information and related downloads for Blazegraph Server, please visit www.blazegraph.com.

How to use this image

Start a blazegraph server instance

Starting a Blazegraph instance is simple:

$ docker run --name some-blazegraph -d conjecto/blazegraph:tag

... where some-blazegraph is the name you want to assign to your container, tag is the tag specifying the Blazegraph version you want. See the list above for relevant tags.

Connect to Blazegraph from an application in another Docker container

This image exposes the standard Blazegraph port (9999), so container linking makes the Blazegraph instance available to other application containers. Start your application container like this in order to link it to the Blazegraph container:

$ docker run --name some-app --link some-blazegraph:blazegraph -d application-that-uses-blazegraph

... via docker stack deploy or docker-compose

Example stack.yml for blazegraph:

version: '3.1'

services:

    db:
        image: conjecto/blazegraph
        environment:
            JAVA_XMS: 512m
            JAVA_XMX: 1g

Run docker stack deploy -c stack.yml conjecto/blazegraph (or docker-compose -f stack.yml up), wait for it to initialize completely, and visit http://swarm-ip:9999, http://localhost:9999, or http://host-ip:9999 (as appropriate).

Container shell access and viewing Blazegraph logs

The docker exec command allows you to run commands inside a Docker container. The following command line will give you a bash shell inside your blazegraph container:

$ docker exec -it some-blazegraph bash

The Blazegraph Server log is available through Docker's container log:

$ docker logs some-blazegraph

Using a custom Blazegraph configuration file

The Blazegraph startup configuration is specified in the file /etc/blazegraph/override.xml. Settings in this file will augment and/or override default settings of blazegraph. If you want to use a customized Blazegraph configuration, you can create your alternative configuration file in a directory on the host machine and then mount that directory location as /etc/blazegraph/override.xml inside the blazegraph container.

If /my/custom/override.xml is the path and name of your custom configuration file, you can start your blazegraph container like this :

$ docker run --name some-blazegraph -v /my/custom/override.xml:/etc/blazegraph/override.xml -d conjecto/blazegraph:tag

Mount Blazegraph journal to a local drive

Blazegraph journal can be map on a local volume using the following command :

$ docker run --name some-blazegraph -v ./var/blazegraph:/var/lib/blazegraph -d conjecto/blazegraph:tag

Environment Variables

When you start the blazegraph image, you can adjust the configuration of the Blazegraph instance by passing one or more environment variables on the docker run command line. Do note that none of the variables below will have any effect if you start the container with a data directory that already contains a database: any pre-existing database will always be left untouched on container startup.

JAVA_XMS

This variable is optional and allows you to specify specifies the initial memory allocation pool for the Java Virtual Machine (JVM). Default is set to 512Mio.

JAVA_XMX

This variable is optional and allows you to specify the maximum memory allocation pool for the Java Virtual Machine (JVM). Default is set to 1Gio.

Initializing a fresh instance

When a container is started for the first time, a new kb namespace will be created and initialized with the provided configuration variables.
Furthermore, it will load RWStore.properties found in /docker-entrypoint-initdb.d/someNamespace to configure the namespace and import RDF files
present in /docker-entrypoint-initdb.d/someNamespace/data/ . Files will be executed in alphabetical order.

Example stack.yml for blazegraph:

version: '3.1'

services:

    db:
        image: conjecto/blazegraph
        environment:
            JAVA_XMS: 512m
            JAVA_XMX: 1g
        volumes:
            - /var/blazegraph:/var/lib/blazegraph
            - ./docker-entrypoint-initdb.d:/docker-entrypoint-initdb.d
        ports:
            - "9999:9999"

Credits for this readme

A huge part of this readme is largely inspired by mysql docker readme

Docker Pull Command
Owner
conjecto
Source Repository