You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@opennlp.apache.org by kr...@apache.org on 2026/10/04 09:02:26 UTC
(opennlp) branch fix/ci-cache-models updated: Cache downloaded test models in CI
This is an automated email from the ASF dual-hosted git repository.
krickert pushed a commit to branch fix/ci-cache-models
in repository https://gitbox.apache.org/repos/asf/opennlp.git
The following commit(s) were added to refs/heads/fix/ci-cache-models by this push:
new cdb8de324 Cache downloaded test models in CI
cdb8de324 is described below
commit cdb8de32443b0774affd23c11474852c6c0d7dd7
Author: Kristian Rickert <kr...@apache.org>
AuthorDate: Sun Oct 4 05:02:21 2026 -0400
Cache downloaded test models in CI
Every CI run downloaded the test models again, so a reset connection to
the model host failed the build. The models now go to a folder that is
kept in the GitHub Actions cache.
Assisted-by: Claude Code 2.1.289
Co-authored-by: Kristian Rickert <kr...@apache.org>
Co-authored-by: Claude <no...@anthropic.com>
Reviewed-by: Kristian Rickert <kr...@apache.org>
Signed-off-by: Kristian Rickert <kr...@apache.org>
---
.github/workflows/maven.yml | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml
index 02fbd0eff..1677c0bec 100644
--- a/.github/workflows/maven.yml
+++ b/.github/workflows/maven.yml
@@ -62,13 +62,19 @@ jobs:
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
+ # Test models are downloaded once and reused, so the build does not depend on the
+ # model host on every run. Change the key when the tests move to other models.
+ - uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
+ with:
+ path: ~/.opennlp-ci
+ key: ${{ runner.os }}-opennlp-models-ud-1.3
- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@de7274f081f381c8f8158605e0321c36c376e2e6 # v6.0.1
with:
distribution: temurin
java-version: ${{ matrix.java }}
- name: Build with Maven
- run: mvn -V clean test verify --show-version --batch-mode --no-transfer-progress -Pjacoco -Pci
+ run: mvn -V clean test verify --show-version --batch-mode --no-transfer-progress -Pjacoco -Pci "-Dopennlp.download.home=$HOME/.opennlp-ci"
- name: Jacoco
run: mvn jacoco:report
# The binary distribution is pure-Java and platform-independent, so we build it