Skip to content

Commit

Permalink
Merge pull request #11 from qbicsoftware/release/1.0.0
Browse files Browse the repository at this point in the history
## 1.0.0 (2022-01-28)

* Add first working implementation to report updates based on a point in time.
* The application fails when any problems arise retrieving samples
  • Loading branch information
KochTobi authored Feb 2, 2022
2 parents 328e40d + c5c7545 commit 928b842
Show file tree
Hide file tree
Showing 59 changed files with 2,095 additions and 334 deletions.
14 changes: 14 additions & 0 deletions .github.settings.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<settings>
<servers>
<server>
<id>nexus-snapshots</id>
<username>${env.MAVEN_REPO_USERNAME}</username>
<password>${env.MAVEN_REPO_PASSWORD}</password>
</server>
<server>
<id>nexus-releases</id>
<username>${env.MAVEN_REPO_USERNAME}</username>
<password>${env.MAVEN_REPO_PASSWORD}</password>
</server>
</servers>
</settings>
2 changes: 1 addition & 1 deletion .github/workflows/build_package.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Build Maven Package

on: [push]
on: [ push ]

jobs:
build:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/changelog-update.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: "Changelog update"
on:
pull_request:
types: [opened, synchronize, reopened, ready_for_review, labeled, unlabeled]
types: [ opened, synchronize, reopened, ready_for_review, labeled, unlabeled ]

jobs:
# Enforces the update of a changelog file on every pull request
Expand Down
74 changes: 37 additions & 37 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,47 +37,47 @@ jobs:
# Learn more about CodeQL language support at https://git.io/codeql-language-support

steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Set up JDK 1.17
uses: actions/setup-java@v1
with:
java-version: 1.17
settings-path: ${{ github.workspace }}
- name: Checkout repository
uses: actions/checkout@v2
- name: Set up JDK 1.17
uses: actions/setup-java@v1
with:
java-version: 1.17
settings-path: ${{ github.workspace }}

- name: Load local Maven repository cache
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Load local Maven repository cache
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl
# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language
# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release
#- run: |
# make bootstrap
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
12 changes: 6 additions & 6 deletions .github/workflows/generate-reports.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ name: Generate reports and API documentation

on:
release:
types: [created]
types: [ created ]
push:
branches:
- development
Expand All @@ -20,10 +20,10 @@ jobs:
- name: Install git
run: sudo apt-get install git

- name: Set up JDK 1.11
- name: Set up JDK 1.17
uses: actions/setup-java@v1
with:
java-version: 1.11
java-version: 1.17
server-id: github # Value of the distributionManagement/repository/id field of the pom.xml
settings-path: ${{ github.workspace }}

Expand All @@ -44,15 +44,15 @@ jobs:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
${{ runner.os }}-maven-
- name: Maven generate reports
run: mvn --activate-profiles !development-build,!release-build --settings .github.settings.xml site

- name: Set up git
run: |
git config --global user.email "[email protected]"
git config --global user.name "JohnnyQ5"
git config --global user.email "[email protected]"
git config --global user.name "JohnnyQ5"
- name: Publish reports
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/groovy_checkstyle.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Groovy Checkstyle

on: [push]
on: [ push ]

jobs:
build:
Expand Down
40 changes: 20 additions & 20 deletions .github/workflows/nexus-publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,38 +6,38 @@ name: Nexus Package

on:
release:
types: [created]
types: [ created ]

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Set up JDK 1.17
uses: actions/setup-java@v1
with:
java-version: 1.17
server-id: github # Value of the distributionManagement/repository/id field of the pom.xml
settings-path: ${{ github.workspace }}

- name: Load local Maven repository cache
- uses: actions/checkout@v2
- name: Set up JDK 1.17
uses: actions/setup-java@v1
with:
java-version: 1.17
server-id: github # Value of the distributionManagement/repository/id field of the pom.xml
settings-path: ${{ github.workspace }}

- name: Load local Maven repository cache
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Remove snapshot tags
run: mvn versions:set -DremoveSnapshot
- name: Remove snapshot tags
run: mvn versions:set -DremoveSnapshot

- name: Build with Maven
- name: Build with Maven
run: mvn -B package --file pom.xml

- name: Publish artefact to QBiC Nexus Repository
- name: Publish artefact to QBiC Nexus Repository
run: mvn --quiet --activate-profiles !development-build,release-build --settings $GITHUB_WORKSPACE/.github.settings.xml deploy
env:
MAVEN_REPO_USERNAME: ${{ secrets.NEXUS_USERNAME }}
MAVEN_REPO_PASSWORD: ${{ secrets.NEXUS_PASSWORD }}
MAVEN_REPO_USERNAME: ${{ secrets.NEXUS_USERNAME }}
MAVEN_REPO_PASSWORD: ${{ secrets.NEXUS_PASSWORD }}
2 changes: 1 addition & 1 deletion .github/workflows/nexus-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
with:
java-version: 1.17
settings-path: ${{ github.workspace }}

- name: Load local Maven repository cache
uses: actions/cache@v2
with:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: PR to master/main branch from patch/release branch only
on:
pull_request:
branches:
- main
- main

jobs:
test:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/run_tests.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Run Maven Tests

on: [push]
on: [ push ]

jobs:
build:
Expand Down
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ hs_err_pid*

# misc
*.DS_STORE
/target/
/bin/

# IntelliJ

.idea
.idea
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Changelog

This project adheres to [Semantic Versioning](https://semver.org/).

## 1.0.0 (2022-01-28)

* Add first working implementation to report updates based on a point in time.
* The application fails when any problems arise retrieving samples


5 changes: 4 additions & 1 deletion HELP.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
# Read Me First

The following was discovered as part of building this project:

* The original package name 'life.qbic.spring-minimal-template' is invalid and this project uses 'life.qbic.springminimaltemplate' instead.
* The original package name 'life.qbic.spring-minimal-template' is invalid and this project uses '
life.qbic.springminimaltemplate' instead.

# Getting Started

### Reference Documentation

For further reference, please consider the following sections:

* [Official Apache Maven documentation](https://maven.apache.org/guides/index.html)
Expand Down
49 changes: 29 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,34 +1,43 @@
# LIMS Sample Status Reporter
# LIMS Sample Status Reporter

[![CodeQL](https://github.com/qbicsoftware/sample-status-reporter/actions/workflows/codeql-analysis.yml/badge.svg?branch=main)](https://github.com/qbicsoftware/sample-status-reporter/actions/workflows/codeql-analysis.yml)
[![Latest Release ](https://img.shields.io/github/v/release/qbicsoftware/sample-status-reporter.svg)](https://github.com/qbicsoftware/sample-status-reporter/releases)
![Groovy Language](https://img.shields.io/badge/language-groovy-blue.svg)

The LIMS Sample status reporter application is used to report changes in the status of a sample set in the LIMS environment to Sample Tracking Service.

Overview:

- [Requirements](#requirements)
- [Run the app](#run-the-app)
- [App structure](#app-structure)

# Requirements

To run this app, you need to have version 17 of a **Java JRE** or **JDK** installed (e.g. **Zulu**).
## System setup

For this application to be run the following environment variables need to be set:

| Name | Description |
|-------------------------------------|------------------------------------------------------------------------|
| `LAST_UPDATE_FILE` | A path to a persistent file. The last successful run is stored here. |
| `LIMS_PASSWORD` | The password to access the OpenBiS LIMS |
| `LIMS_SERVER_URL` | The URL to the OpenBiS LIMS API |
| `LIMS_USER` | The user to access the OpenBiS LIMS |
| `SAMPLE_TRACKING_AUTH_PASSWORD` | The password for the sample tracking user |
| `SAMPLE_TRACKING_AUTH_USER` | The username for the sample tracking service |
| `SAMPLE_TRACKING_LOCATION_ENDPOINT` | The endpoint to list all locations. This does not contain the base url |
| `SAMPLE_TRACKING_LOCATION_USER` | The sample tracking user currently using the application |
| `SAMPLE_TRACKING_URL` | The base URL for the sample tracking service |
| `USER_DB_DIALECT` | The database dialect of the user database |
| `USER_DB_DRIVER` | The database driver for the user database |
| `USER_DB_HOST` | The URL to the host of the user database containing the database name |
| `USER_DB_USER_NAME` | The database user name |
| `USER_DB_USER_PW` | The database user password |

## Run the app

Checkout the latest code from `main` and run the Maven goal `spring-boot:run`:

```
mvn spring-boot:run
mvn spring-boot:run [-Dspring-boot.run.arguments=[-hV],[-t=<timePoint>]]
-h, --help Show this help message and exit.
-t, --time-point=<timePoint>
Point in time from where to search for updates e.g. '2022-01-01T00:00:00Z'.
Defaults to the last successful run.
If never run successfully defaults to the same time yesterday.
-V, --version Print version information and exit.
```


## App structure

The preliminary app structure is outlined in this UML diagram:
![Bioinformatics Analysis Result Set ER](./docs/Spring%20Boot%20Starter%20Template%20UML.jpg)




Loading

0 comments on commit 928b842

Please sign in to comment.