zmuxuny opened a new pull request, #5029:
URL: https://github.com/apache/rocketmq-dashboard/pull/5029

   ### Which Issue(s) This PR Fixes
   
   - Fixes #5028
   
   ### Brief Description
   
   The backend test job runs database-backed Spring integration tests but 
starts no MySQL service. On a fresh runner, 17 tests fail while loading the 
application context. Add a MySQL 8.0 service (the version used by 
`deploy/docker-compose.yml`), wait for TCP readiness, and initialize it from 
the repository's authoritative `db/schema.sql` before `mvn test`.
   
   The job uses the application's normal datasource defaults. It does not set a 
global datasource override, so tests explicitly using the `dev` profile still 
run against H2. This is independent of the Docker Action startup change in 
#5020 and the backend packaging license gate.
   
   ### How Did You Test This Change?
   
   - [CI run 
35838525708](https://github.com/apache/rocketmq-dashboard/actions/runs/35838525708),
 before this change: backend job reported **3,194 tests, 17 errors** from the 
missing MySQL datasource.
   - Started a fresh local `mysql:8.0` container, initialized 
`server/src/main/resources/db/schema.sql` using the workflow's `docker exec -e 
MYSQL_PWD` command, and ran the nine affected integration test classes: **17 
passed, 0 failures/errors**.
   - Ran the full backend suite against that MySQL service with no datasource 
environment override: **3,194 tests, 0 assertion failures, 1 error**. The 
remaining error was an intermittent H2 metadata 
`ConcurrentModificationException` in 
`ResourceOwnershipGuardTest.migrationConcurrentStartupIsIdempotentTest`; the 
isolated rerun passed. The MySQL context errors were gone.
   - Parsed the workflow YAML and checked the MySQL job structure; `git diff 
--check` passed.
   
   ### Checklist
   
   - [x] One coherent CI environment fix
   - [x] Commit subject follows Conventional Commits
   - [x] No application code, UI text, or new source files
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to