Skip to content

Commit 7edf804

Browse files
committed
make database being spinned up dependant on the workflow
1 parent 4442a06 commit 7edf804

5 files changed

Lines changed: 16 additions & 15 deletions

File tree

.github/workflows/benchmarks.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ jobs:
5757
docker run --name mock_core -d -p 5000:5000 mock_core
5858
- name: Start databases
5959
working-directory: ./sample-apps/databases
60-
run: docker compose up --build -d
60+
run: docker compose up --build -d postgres_database
6161

6262
- name: Build Application (ensures cache)
6363
working-directory: ./sample-apps/${{ matrix.app }}

.github/workflows/end2end.yml

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -39,16 +39,16 @@ jobs:
3939
strategy:
4040
matrix:
4141
app:
42-
- { name: SpringBootPostgres, test_file: end2end/spring_boot_postgres.py }
43-
- { name: SpringBootMySQL, test_file: end2end/spring_boot_mysql.py }
44-
- { name: SpringBootMSSQL, test_file: end2end/spring_boot_mssql.py }
45-
- { name: SpringWebfluxSampleApp, test_file: end2end/spring_webflux_postgres.py }
46-
- { name: SpringMVCPostgresKotlin, test_file: end2end/spring_mvc_postgres_kotlin.py }
47-
- { name: SpringMVCPostgresGroovy, test_file: end2end/spring_mvc_postgres_groovy.py }
48-
- { name: JavalinPostgres, test_file: end2end/javalin_postgres.py }
49-
- { name: JavalinMySQLKotlin, test_file: end2end/javalin_mysql_kotlin.py }
50-
- { name: SpringBoot2.7Postgres, test_file: end2end/spring_boot_2.7_postgres.py }
51-
- { name: SpringBootHyperSQL, test_file: end2end/spring_boot_hypersql.py }
42+
- { name: SpringBootPostgres, test_file: end2end/spring_boot_postgres.py, db: postgres_database }
43+
- { name: SpringBootMySQL, test_file: end2end/spring_boot_mysql.py, db: mysql_database }
44+
- { name: SpringBootMSSQL, test_file: end2end/spring_boot_mssql.py, db: mssql_database }
45+
- { name: SpringWebfluxSampleApp, test_file: end2end/spring_webflux_postgres.py, db: postgres_database }
46+
- { name: SpringMVCPostgresKotlin, test_file: end2end/spring_mvc_postgres_kotlin.py, db: postgres_database }
47+
- { name: SpringMVCPostgresGroovy, test_file: end2end/spring_mvc_postgres_groovy.py, db: postgres_database }
48+
- { name: JavalinPostgres, test_file: end2end/javalin_postgres.py, db: postgres_database }
49+
- { name: JavalinMySQLKotlin, test_file: end2end/javalin_mysql_kotlin.py, db: mysql_database }
50+
- { name: SpringBoot2.7Postgres, test_file: end2end/spring_boot_2.7_postgres.py, db: postgres_database }
51+
- { name: SpringBootHyperSQL, test_file: end2end/spring_boot_hypersql.py, db: "" }
5252
java-version: [17, 18, 19, 20, 21]
5353
distribution: ['adopt', 'corretto', 'oracle']
5454
steps:
@@ -69,10 +69,11 @@ jobs:
6969
docker build -t mock_core .
7070
docker run --name mock_core -d -p 5000:5000 mock_core
7171
- name: Start databases
72+
if: matrix.app.db != ''
7273
working-directory: ./sample-apps/databases
7374
run: |
7475
docker compose down --volumes
75-
docker compose up --build -d
76+
docker compose up --build -d ${{ matrix.app.db }}
7677
- name: Install Python dependencies
7778
run: python -m pip install -r end2end/requirements.txt
7879

.github/workflows/gradle-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ jobs:
6363
6464
- name: Start databases
6565
working-directory: ./sample-apps/databases
66-
run: docker compose up --build -d && sleep 10
66+
run: docker compose up --build -d postgres_database mysql_database mssql_database && sleep 10
6767

6868
- name: Start mock server
6969
working-directory: ./end2end/server

.github/workflows/opentel.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ jobs:
6060
working-directory: ./sample-apps/databases
6161
run: |
6262
docker compose down --volumes
63-
docker compose up --build -d
63+
docker compose up --build -d postgres_database
6464
- name: Install Python dependencies
6565
run: python -m pip install -r end2end/requirements.txt
6666
- name: Cleanup application

.github/workflows/test-ddtrace.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ jobs:
6161
working-directory: ./sample-apps/databases
6262
run: |
6363
docker compose down --volumes
64-
docker compose up --build -d
64+
docker compose up --build -d postgres_database
6565
- name: Install Python dependencies
6666
run: python -m pip install -r end2end/requirements.txt
6767
- name: Cleanup application

0 commit comments

Comments
 (0)