forked from opentripplanner/OpenTripPlanner
-
Notifications
You must be signed in to change notification settings - Fork 0
72 lines (60 loc) · 2.26 KB
/
performance-test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
name: Performance test
on:
push:
branches:
- dev-2.x
jobs:
perf-test:
if: github.repository_owner == 'opentripplanner'
runs-on: performance-test
steps:
- uses: actions/[email protected]
with:
fetch-depth: 0
- name: Set up JDK 17
uses: actions/setup-java@v1
with:
java-version: 17
- name: Set up Maven
uses: stCarolas/[email protected]
with:
maven-version: 3.8.2
- name: Cache local Maven repository
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Cache graph input files
uses: actions/cache@v2
with:
path: |
graph/*.osm.pbf
graph/*.zip
key: graph
- name: Build jar
run: mvn -DskipTests --batch-mode package -P prettierSkip
- name: Download OSM & Netex data
run: |
mkdir -p graph
wget https://download.geofabrik.de/europe/norway-210101.osm.pbf -O graph/norway.osm.pbf --no-clobber -q --show-progress --progress=bar:force || true
wget https://leonard.io/otp/rb_norway-aggregated-netex-2021-12-11.zip -O graph/rb_norway-aggregated-netex.zip --no-clobber -q --show-progress --progress=bar:force || true
- name: Build Norway graph
run: |
cp test/ci-performance-test/build-config.json graph/build-config.json
cp target/otp-*-SNAPSHOT-shaded.jar otp.jar
java -Xmx32G -jar otp.jar --build --save graph
- name: Copy graph, run speed test
env:
PERFORMANCE_INFLUX_DB_PASSWORD: ${{ secrets.PERFORMANCE_INFLUX_DB_PASSWORD }}
MEASUREMENT_ENVIRONMENT: CI
run: |
mv graph/graph.obj test/ci-performance-test/
mvn exec:java -Dexec.mainClass="org.opentripplanner.transit.raptor.speed_test.SpeedTest" -Dexec.classpathScope=test -Dexec.args="--dir=test/ci-performance-test/ -p md -n 4 -i 3 -0"
- name: Archive travel results file
uses: actions/upload-artifact@v2
with:
name: travelSearch-results.csv
path: |
test/ci-performance-test/travelSearch-results.csv