As a key component of Knowledge Grid, an activator allows knowledge objects to be executable against collected data.
For the information on the activator API and the usage of the activator, see KGRID Activator API
For the information on the activator configuration, see KGRID ACTIVATOR CONFIGURATION
For the information on the activator deployment, see Integrator's Guide
For development and testing purposes. See deployment for notes on how to deploy the project on a live system.
For building and running the application you need:
To get started you can simply clone this repository using git:
git clone https://github.com/kgrid/kgrid-activator.git
cd kgrid-activator
mvn clean package
export SPRING_PROFILES_ACTIVE=dev
# set SPRING_PROFILES_ACTIVE=dev (Windows)
java -jar target/kgrid-activator*.jar
This will run the activator and create an empty ./shelf in the current working directory. By default, the application
starts on port 8080.
Access the activator health endpoint at (http://localhost:8080/actuator/health). status should be up
You can load the local shelf with the example collection of KOs by setting the kgrid.shelf.manifest property at
startup to point to the manifest file for
the example-collection release on GitHub.
java -jar target/kgrid-activator*.jar --kgrid.shelf.manifest=https://github.com/kgrid-objects/example-collection/releases/download/4.1.1/manifest.json
You can also point the activator to an existing /shelf on your local system using the kgrid.shelf.cdostore.url
property at startup.
java -jar target/kgrid-activator*.jar --kgrid.shelf.cdostore.url=filesystem:file:///path/to/local/shelf
Unit and Integration tests can be executed via
mvn clean verify
Follow your provider's documentation. If you are building the latest version from main you may need to add the
oss.sonatype.org SNAPSHOT repository. For example, on Heroku by using:
MAVEN_SETTINGS_PATH=.circleci/settings.xmlThis method uses the dockerfile to build and deploy an image on heroku.
- First run
heroku container:push web -a <APPLICATION NAME>to build the docker container and push it to the heroku registry. - Then run
heroku container:release web -a <APPLICATION NAME>to have heroku deploy and start the application.
We publish a spring-boot container image of the activator on dockerhub.io. If you’d like to deploy your dockerized Spring Boot app to a resource constrained environment you may need to explicitly set JAVA_OPTS to indicate the memory constraints. (Or, on Heroku, you’ll need to use Heroku Buildpacks. This is because the Paketo buildpacks refuse to allocate heap on containers smaller than 1 GB of RAM. A free Heroku dyno has 512 MB.)