Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/HHS/ASPR-ms-gcm-taskit into…
Browse files Browse the repository at this point in the history
… dev
  • Loading branch information
bischoffz committed Apr 15, 2024
2 parents 081420b + 2b283cd commit 2c44d59
Show file tree
Hide file tree
Showing 4 changed files with 57 additions and 63 deletions.
15 changes: 13 additions & 2 deletions .github/workflows/dev_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,35 +34,46 @@ jobs:
echo "gcm_version=v$(mvn help:evaluate -Dexpression=gcm.version -q -DforceStdout --file pom.xml)" >> "$GITHUB_ENV"
- name: Checkout Taskit
if: ${{ endsWith(env.taskit_version, 'SNAPSHOT') }}
uses: actions/checkout@v4
with:
repository: HHS/ASPR-ms-taskit
path: taskit
ref: ${{ (endsWith(env.taskit_version, 'SNAPSHOT') && 'dev') || env.taskit_version }}
ref: dev

- name: Checkout GCM
# if: ${{ endsWith(env.gcm_version, 'SNAPSHOT') }}
uses: actions/checkout@v4
with:
repository: HHS/ASPR-8
path: gcm
ref: ${{ (endsWith(env.gcm_version, 'SNAPSHOT') && 'dev') || env.gcm_version }}

- name: Get Util Version
# if: ${{ endsWith(env.gcm_version, 'SNAPSHOT') }}
run: |
echo "util_version=v$(mvn help:evaluate -Dexpression=util.version -q -DforceStdout --file gcm/pom.xml)" >> "$GITHUB_ENV"
- name: Checkout Util
if: ${{ endsWith(env.util_version, 'SNAPSHOT') }}
uses: actions/checkout@v4
with:
repository: HHS/ASPR-ms-util
path: util
ref: ${{ (endsWith(env.util_version, 'SNAPSHOT') && 'dev') || env.util_version }}
ref: dev

- name: Build Util
if: ${{ endsWith(env.util_version, 'SNAPSHOT') }}
run: mvn clean install -DskipTests --file util/pom.xml

- name: Build GCM
# if: ${{ endsWith(env.gcm_version, 'SNAPSHOT') }}
run: mvn clean install -DskipTests --file gcm/simulation/pom.xml

- name: Build Taskit
if: ${{ endsWith(env.taskit_version, 'SNAPSHOT') }}
run: mvn clean install -DskipTests --file taskit/pom.xml

- name: Build GCM Taskit
run: mvn clean install --file pom.xml

Expand Down
32 changes: 5 additions & 27 deletions .github/workflows/release_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@ name: GCM Taskit Release Build

on:
push:
tags:
- 'v*'
paths-ignore:
- 'README.md'
- 'LICENSE'
branches: ["main"]

jobs:
Expand All @@ -31,39 +32,17 @@ jobs:

- name: Get Taskit and GCM Versions
run: |
echo "taskit_version=v$(mvn help:evaluate -Dexpression=taskit.version -q -DforceStdout --file pom.xml)" >> "$GITHUB_ENV"
echo "gcm_version=v$(mvn help:evaluate -Dexpression=gcm.version -q -DforceStdout --file pom.xml)" >> "$GITHUB_ENV"
- name: Checkout Taskit
uses: actions/checkout@v4
with:
repository: HHS/ASPR-ms-taskit
path: taskit
ref: ${{ (endsWith(env.taskit_version, 'SNAPSHOT') && 'dev') || env.taskit_version }}
- name: Checkout GCM
uses: actions/checkout@v4
with:
repository: HHS/ASPR-8
path: gcm
ref: ${{ (endsWith(env.gcm_version, 'SNAPSHOT') && 'dev') || env.gcm_version }}

- name: Get Util Version
run: |
echo "util_version=v$(mvn help:evaluate -Dexpression=util.version -q -DforceStdout --file gcm/pom.xml)" >> "$GITHUB_ENV"
ref: ${{ env.gcm_version }}

- name: Checkout Util
uses: actions/checkout@v4
with:
repository: HHS/ASPR-ms-util
path: util
ref: ${{ (endsWith(env.util_version, 'SNAPSHOT') && 'dev') || env.util_version }}

- name: Build Util
run: mvn clean install -DskipTests --file util/pom.xml
- name: Build GCM
run: mvn clean install -DskipTests --file gcm/simulation/pom.xml
- name: Build Taskit
run: mvn clean install -DskipTests --file taskit/pom.xml
- name: Build GCM Taskit
run: mvn clean install -Prelease --file pom.xml

Expand All @@ -73,8 +52,7 @@ jobs:
- name: Make Release
uses: ncipollo/release-action@v1
with:
artifacts: "protobuf/target/protobuf-${{ env.version }}*.jar"
prerelease: ${{ endsWith(env.version, '-SNAPSHOT') || contains(env.version, '-RC') }}
artifacts: "protobuf/target/protobuf-${{ env.version }}*"
name: "v${{ env.version }}"
tag: "v${{ env.version }}"
generateReleaseNotes: true
Expand Down
30 changes: 4 additions & 26 deletions .github/workflows/release_pr_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ on:
branches: [ "main" ]

jobs:
main-build:
release-pr-build:
runs-on: ubuntu-latest
permissions:
contents: write
Expand All @@ -27,40 +27,18 @@ jobs:
java-version: '17'
distribution: 'temurin'

- name: Get Taskit and GCM Versions
- name: Get GCM Version
run: |
echo "taskit_version=v$(mvn help:evaluate -Dexpression=taskit.version -q -DforceStdout --file pom.xml)" >> "$GITHUB_ENV"
echo "gcm_version=v$(mvn help:evaluate -Dexpression=gcm.version -q -DforceStdout --file pom.xml)" >> "$GITHUB_ENV"
- name: Checkout Taskit
uses: actions/checkout@v4
with:
repository: HHS/ASPR-ms-taskit
path: taskit
ref: ${{ (endsWith(env.taskit_version, 'SNAPSHOT') && 'dev') || env.taskit_version }}
- name: Checkout GCM
uses: actions/checkout@v4
with:
repository: HHS/ASPR-8
path: gcm
ref: ${{ (endsWith(env.gcm_version, 'SNAPSHOT') && 'dev') || env.gcm_version }}
ref: ${{ env.gcm_version }}

- name: Get Util Version
run: |
echo "util_version=v$(mvn help:evaluate -Dexpression=util.version -q -DforceStdout --file gcm/pom.xml)" >> "$GITHUB_ENV"
- name: Checkout Util
uses: actions/checkout@v4
with:
repository: HHS/ASPR-ms-util
path: util
ref: ${{ (endsWith(env.util_version, 'SNAPSHOT') && 'dev') || env.util_version }}

- name: Build Util
run: mvn clean install -DskipTests --file util/pom.xml
- name: Build GCM
run: mvn clean install -DskipTests --file gcm/simulation/pom.xml
- name: Build Taskit
run: mvn clean install -DskipTests --file taskit/pom.xml
- name: Build GCM Taskit
run: mvn clean install -Prelease --file pom.xml
43 changes: 35 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,26 +7,53 @@
# Translation And Serialization Toolkit (Taskit) for the General Computational Model (GCM)
An implementation of [Taskit](https://github.com/HHS/ASPR-ms-taskit) for use with [GCM](https://github.com/HHS/ASPR-8).

Currently there is only 1 supported serialzation format, and that is protobuf. Other formats such as binary will follow in the future.

## License
Distributed under the GPLv3 License. See [LICENSE](LICENSE) for more information.

Please read the [HHS vulnerability discloure](https://www.hhs.gov/vulnerability-disclosure-policy/index.html).

## Overview
The only implementation of Taskit for GCM currently is Protobuf
This taskit implementation is built as follows:

### Plugins
Each GCM plugin has it's PluginData and most support and testsupport classes are implemented and support serilization.

Note that Plugins themselves do not support serialization, but their respective PluginDatas do.

These are split into Translators and use a dependency mechanism that is the same as the plugin dependency within GCM.

## Requirements
### Nucleus
Not all classes in Nucleus support serialization.
Just the following classes support serialization
- Planner
- SimulationState
- ExperimentParameterData
- Dimension

## Building from Source

### Requirements
- Maven 3.8.x
- Java 17
- Favorite IDE for Java development
- Modeling Util located [here](https://github.com/HHS/ASPR-ms-util)
- GCM located [here](https://github.com/HHS/ASPR8)
- Taskit located [here](https://github.com/HHS/ASPR-ms-taskit)

## Building
To build, navigate into the root directory and run the command ```mvn clean install```
*NOTE that both Taskit and Modeling Util are in maven central, so there is no need to clone and build those repos

### Building
To build this project:
- Clone the repo
- open a command line terminal
- navigate to the root folder of this project
- run the command: `mvn clean install`

## Documentation
Documentation has yet to be created. In the interim, the code is mostly commented and the javadocs do provide good detail with regards to method and class expectations.

## License
Distributed under the GPLv3 License. See [LICENSE](LICENSE) for more information.


<!-- MARKDOWN LINKS & IMAGES -->
[contributors-shield]: https://img.shields.io/github/contributors/HHS/ASPR-ms-gcm-taskit
[contributors-url]: https://github.com/HHS/ASPR-ms-gcm-taskit/graphs/contributors
Expand Down

0 comments on commit 2c44d59

Please sign in to comment.