# schneidenbach/master-dot-dev-codex-course-live architecture

> Architecture diagram of the GitHub repository schneidenbach/master-dot-dev-codex-course-live, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-22). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/schneidenbach/master-dot-dev-codex-course-live
- Repository: https://github.com/schneidenbach/master-dot-dev-codex-course-live

## Overview

This repository is a staged full-stack live-auction demo: each numbered part extends the previous vertical slice, culminating in checkout and cross-stack tracing. A typical user browses auctions, creates one or bids, receives live updates, then sees auction-close and winner-checkout outcomes. The graph emphasizes the final architecture while preserving the documented progression and major capabilities. Some service wiring is supported only by the README or worker excerpts; the graph avoids inferring unshown internal API details.

Main entry points: [`part-8-cross-stack-debugging/server/src/app.ts`](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/app.ts) (Fastify API), [`part-8-cross-stack-debugging/web/src/App.tsx`](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/web/src/App.tsx) (Web application), [`part-8-cross-stack-debugging/server/src/notification-worker.ts`](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/notification-worker.ts) (Notification worker), [`part-8-cross-stack-debugging/server/src/close-worker.ts`](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/close-worker.ts) (Auction close worker)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_client["Auction experience"]
  node_web["Web application<br/>[App.tsx]"]
  node_catalog["Auction catalog<br/>[catalog.ts]"]
  node_bidform["Auction actions<br/>[BidForm.tsx]"]
  node_liveclient["Live auction client<br/>[liveAuction.ts]"]
  node_outcomeui["Outcome notices"]
end

subgraph group_api["Auction API and state"]
  node_api["Fastify API<br/>[app.ts]"]
  node_postgres[("PostgreSQL")]
  node_realtime["Realtime gateway<br/>[realtime.ts]"]
  node_redis[("Redis pub/sub")]
end

subgraph group_async["Close and notifications"]
  node_closeworker["Auction close worker<br/>[close-worker.ts]"]
  node_closeservice["Close processing<br/>[auctionClose.ts]"]
  node_publisher["Outbox publisher<br/>[outboxPublisher.ts]"]
  node_notifyworker["Notification worker"]
  node_delivery["Outcome delivery"]
end

subgraph group_integrations["External services"]
  node_rabbit["RabbitMQ"]
  node_payments["Payment integration<br/>[payments.ts]"]
  node_stripe["Mock Stripe service<br/>[app.ts]"]
  node_telemetry["OpenTelemetry tracing<br/>[tracing.ts]"]
end

node_buyer(("Auction user"))

node_buyer -->|"uses"| node_web
node_web -->|"loads listings"| node_catalog
node_web -->|"renders actions"| node_bidform
node_web -->|"requests auctions"| node_api
node_bidform -.->|"submits bids"| node_api
node_api -->|"reads and writes"| node_postgres
node_api -.->|"publishes updates"| node_realtime
node_realtime -.->|"fans out"| node_redis
node_redis -.->|"broadcasts bids"| node_liveclient
node_liveclient -.->|"updates view"| node_web
node_closeworker -->|"processes close"| node_closeservice
node_closeworker -.->|"checks auctions"| node_postgres
node_closeworker -->|"publishes events"| node_publisher
node_publisher -.->|"sends events"| node_rabbit
node_rabbit -->|"dispatches event"| node_notifyworker
node_notifyworker -->|"delivers outcome"| node_delivery
node_delivery -.->|"reads outcome"| node_postgres
node_notifyworker -->|"emits notice"| node_redis
node_redis -.->|"notifies winner"| node_outcomeui
node_api -->|"handles checkout"| node_payments
node_payments -.->|"creates session"| node_stripe
node_api -->|"records traces"| node_telemetry
node_notifyworker -->|"traces delivery"| node_telemetry

click node_web "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/web/src/App.tsx"
click node_catalog "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/web/src/catalog.ts"
click node_bidform "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/web/src/components/BidForm.tsx"
click node_liveclient "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/web/src/liveAuction.ts"
click node_outcomeui "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/web/src/outcomeNotifications.ts"
click node_api "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/app.ts"
click node_realtime "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/realtime.ts"
click node_closeworker "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/close-worker.ts"
click node_closeservice "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/auctionClose.ts"
click node_publisher "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/outboxPublisher.ts"
click node_notifyworker "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/notification-worker.ts"
click node_delivery "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/notificationDelivery.ts"
click node_payments "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/payments.ts"
click node_stripe "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/stripe-service/src/app.ts"
click node_telemetry "https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/tracing.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_web,node_catalog,node_bidform,node_liveclient,node_outcomeui,node_buyer toneBlue
class node_api,node_postgres,node_realtime,node_redis toneAmber
class node_closeworker,node_closeservice,node_publisher,node_notifyworker,node_delivery toneMint
class node_rabbit,node_payments,node_stripe,node_telemetry toneRose
```

## Components

### Auction experience

- [Web application](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/web/src/App.tsx): `part-8-cross-stack-debugging/web/src/App.tsx`
- [Auction catalog](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/web/src/catalog.ts): `part-8-cross-stack-debugging/web/src/catalog.ts`
- [Auction actions](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/web/src/components/BidForm.tsx): `part-8-cross-stack-debugging/web/src/components/BidForm.tsx`
- [Live auction client](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/web/src/liveAuction.ts): `part-8-cross-stack-debugging/web/src/liveAuction.ts`
- [Outcome notices](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/web/src/outcomeNotifications.ts): `part-8-cross-stack-debugging/web/src/outcomeNotifications.ts`

### Auction API and state

- [Fastify API](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/app.ts): `part-8-cross-stack-debugging/server/src/app.ts`
- **PostgreSQL**
- [Realtime gateway](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/realtime.ts): `part-8-cross-stack-debugging/server/src/realtime.ts`
- **Redis pub/sub**

### Close and notifications

- [Auction close worker](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/close-worker.ts): `part-8-cross-stack-debugging/server/src/close-worker.ts`
- [Close processing](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/auctionClose.ts): `part-8-cross-stack-debugging/server/src/auctionClose.ts`
- [Outbox publisher](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/outboxPublisher.ts): `part-8-cross-stack-debugging/server/src/outboxPublisher.ts`
- [Notification worker](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/notification-worker.ts): `part-8-cross-stack-debugging/server/src/notification-worker.ts`
- [Outcome delivery](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/notificationDelivery.ts): `part-8-cross-stack-debugging/server/src/notificationDelivery.ts`

### External services

- **RabbitMQ**
- [Payment integration](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/payments.ts): `part-8-cross-stack-debugging/server/src/payments.ts`
- [Mock Stripe service](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/stripe-service/src/app.ts): `stripe-service/src/app.ts`
- [OpenTelemetry tracing](https://github.com/schneidenbach/master-dot-dev-codex-course-live/blob/master/part-8-cross-stack-debugging/server/src/tracing.ts): `part-8-cross-stack-debugging/server/src/tracing.ts`

### Other components

- **Auction user**

## Connections

- Auction user → Web application: uses (evidence: `README.md`)
- Web application → Auction catalog: loads listings (evidence: `part-8-cross-stack-debugging/web/src/App.tsx`)
- Web application → Auction actions: renders actions (evidence: `part-8-cross-stack-debugging/web/src/App.tsx`)
- Web application → Fastify API: requests auctions (evidence: `README.md`)
- Auction actions → Fastify API: submits bids (evidence: `README.md`)
- Fastify API → PostgreSQL: reads and writes (evidence: `part-8-cross-stack-debugging/server/src/app.ts`)
- Fastify API → Realtime gateway: publishes updates (evidence: `part-8-cross-stack-debugging/server/src/app.ts`)
- Realtime gateway → Redis pub/sub: fans out (evidence: `README.md`)
- Redis pub/sub → Live auction client: broadcasts bids (evidence: `README.md`)
- Live auction client → Web application: updates view (evidence: `README.md`)
- Auction close worker → Close processing: processes close (evidence: `part-8-cross-stack-debugging/server/src/close-worker.ts`)
- Auction close worker → PostgreSQL: checks auctions (evidence: `README.md`)
- Auction close worker → Outbox publisher: publishes events (evidence: `part-8-cross-stack-debugging/server/src/close-worker.ts`)
- Outbox publisher → RabbitMQ: sends events (evidence: `README.md`)
- RabbitMQ → Notification worker: dispatches event (evidence: `part-8-cross-stack-debugging/server/src/notification-worker.ts`)
- Notification worker → Outcome delivery: delivers outcome (evidence: `part-8-cross-stack-debugging/server/src/notification-worker.ts`)
- Outcome delivery → PostgreSQL: reads outcome (evidence: `README.md`)
- Notification worker → Redis pub/sub: emits notice (evidence: `part-8-cross-stack-debugging/server/src/notification-worker.ts`)
- Redis pub/sub → Outcome notices: notifies winner (evidence: `README.md`)
- Fastify API → Payment integration: handles checkout (evidence: `part-8-cross-stack-debugging/server/src/app.ts`)
- Payment integration → Mock Stripe service: creates session (evidence: `README.md`)
- Fastify API → OpenTelemetry tracing: records traces (evidence: `part-8-cross-stack-debugging/server/src/app.ts`)
- Notification worker → OpenTelemetry tracing: traces delivery (evidence: `part-8-cross-stack-debugging/server/src/notification-worker.ts`)
