Skip to content

Multiplebindings

Multiplebindings #78

Workflow file for this run

# This is the main CI workflow it verify that SEPA builds and it conformates to the defined tests
name: CI
on:
# Triggers the workflow on push or pull request events but only for the master branch
push:
branches: [ master ]
tags:
- "v*"
pull_request:
branches: [ master ]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up JDK 13
uses: actions/setup-java@v2
with:
java-version: '13'
distribution: 'adopt'
cache: maven
- name: Build with Maven
run: mvn --batch-mode --update-snapshots compile
test:
runs-on: ubuntu-latest
needs: build
services:
blazegraph:
image: nawer/blazegraph:2.1.5
ports:
- 9999:9999
steps:
- uses: actions/checkout@v2
- name: Set up JDK 13
uses: actions/setup-java@v2
with:
java-version: '13'
distribution: 'adopt'
cache: maven
- name: wait for blazegraph
uses: nev7n/wait_for_response@v1
with:
url: 'http://localhost:9999/blazegraph/namespace/kb/sparql'
responseCode: 200
timeout: 20000
interval: 500
- name: package engine and launch
run: |
mvn package
cd engine/target
mv endpoints/endpoint-blazegraph.jpar endpoint.jpar
echo launching engine with this configuration
echo SPARQL ENDPOINT
cat endpoint.jpar
echo ENGINE PROPERTIES
cat engine.jpar
echo LOG4J
cat log4j2.xml
java -Dlog4j.configurationFile=./log4j2.xml -jar engine-1.0.0-SNAPSHOT.jar -engine engine.jpar -endpoint endpoint.jpar > log.txt &
shell: bash
- name: wait for SEPA engine
uses: nev7n/wait_for_response@v1
with:
url: 'http://localhost:8000/echo'
responseCode: 200
timeout: 20000
interval: 500
- name: verify
run: mvn verify -e
- name: Archive code coverage results
uses: actions/upload-artifact@v2
with:
name: engine-log
path: engine/target/log.txt
publish:
runs-on: ubuntu-latest
if: github.event_name == 'push' && contains(github.ref, 'refs/tags/')
needs:
- build
- test
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v2
with:
java-version: '13'
distribution: 'adopt'
cache: maven
- name: Publish package
run: mvn clean deploy -Dmaven.test.skip=true -Drevision=${{github.ref_name}} -DrepositoryId=github
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}