Repository navigation
Gateway E2E verification: add full-stack smoke test + CI workflow - #72
devin-ai-integration[bot] wants to merge 3 commits into
Conversation
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
…+ restart on-failure; dedupe CI runs
|
Hi there, friendly reminder: this pull request hasn't had any activity in over 7 days (last activity: 2026-06-26). If it's still in progress, please push an update or leave a note on where it stands. If it's no longer needed, please close it. Thanks! |
|
Hi, friendly reminder: this pull request hasn't had any activity in over 7 days (last activity: 2026-10-14). If it's still in progress, please push an update or leave a note on where it stands. If it's no longer needed, please close it. Thanks! |
|
Closed by the weekly post-workshop lab reset. The reference solution for this exercise is #73. |
Summary
Final integration step: verify the YARP API gateway routes end-to-end across all five carved-out services, add the repo's first CI gate, and fix a docker-compose cold-start race surfaced by CI. Routing/auth themselves were correct — no gateway (
appsettings.json/Program.cs) changes were needed.End-to-end results (through gateway
http://localhost:5000)GET /healthzGET /GET /(cross-service JWT)POST /api/identity/connect/token(password grant, form-encoded) → 200 withaccess_token.Gateway changes needed
None. All routes (
/api/identity,/api/customers,/api/orders,/api/products,/api/notifications) with theirPathRemovePrefixtransforms and clusters (ports 5001–5005) already resolve correctly. TheNotification.API.csprojSharedreference is already correct (..\..\..\Shared); all six projects build clean in Release.Compose fix (cold-start race — found by CI, fixed in
src/docker-compose.yml)The first CI E2E run failed: services call
EnsureCreated()on boot and threw an unhandledNpgsql ... Connection refusedwhen Postgres wasn't ready yet, then exited with no restart policy — so the gateway could never reach them. It passed locally only because the Postgres image was warm. Fix (no service code touched):postgres(pg_isready) andrabbitmq(rabbitmq-diagnostics ping).depends_onboth withcondition: service_healthyand getsrestart: on-failure, eliminating the startup race deterministically.What's added
scripts/e2e-smoke.sh— self-contained, idempotent full-stack smoke test:docker compose -f src/docker-compose.yml up --build -dtrap cleanup EXIT) and exits non-zero on any failed assertion.github/workflows/ci.yml— runs on push (main/master) + every PR, with aconcurrencygroup to cancel superseded runs. Two jobs:build: sets up the .NET SDK fromsrc/global.json(10.0.100) anddotnet build -c ReleaseforApiGateway.csproj+ each*.API.csproje2e: (needsbuild) runsscripts/e2e-smoke.shon the Docker-enabled runner — the real validation gate, exercising the gateway end-to-end, not just compiling.How to run
Validation
scripts/e2e-smoke.shpasses locally (output above). All six projects build clean in Release.ci.ymlanddocker-compose.ymlvalidated as well-formed YAML /docker compose config.Link to Devin session: https://partner-workshops.devinenterprise.com/sessions/63e1c6d04192425f9bfbc15d0951fc9d
Requested by: @mbatchelor81