Question and use cases
Edge routing, API composition, jobs, orchestration, defaults, and resources form distinct layers.
Use this stack to choose a deployment host and prevent domain policy from drifting into hosting projects.
Use the diagram during design review, incident diagnosis, code walkthroughs, and onboarding. It intentionally omits classes and projects unrelated to the focused question, so read it together with the source entry point and related topic pages.
This page covers only the named responsibilities and relationships; consult the relevant module documentation for capabilities not shown here.
Reading path
- Step 1: Start at Gateway for edge routing and policy.
- Step 2: Separate API request composition from JobHost background execution.
- Step 3: Read AppHost and ServiceDefaults as orchestration and shared runtime defaults, not business layers.
Do not skip arrow direction, numbering, or group titles: they express dependency or time direction, execution order, and responsibility boundaries. If the diagram differs from current source or accepted architecture decisions, correct the generated catalog immediately.
Legend and notation
| Visual element | Meaning | What it does not imply |
|---|---|---|
| Coral focus | The decision point or primary path emphasized by this view | That the element is always more important or privileged |
| Blue boundary | An external system, protocol edge, or explicit boundary | That it must be an independently deployed service |
| Muted connector | A dependency, call, transition, or data flow as named by its label | Synchronous, same-transaction, or exactly-once behavior |
| Group frame | A responsibility, layer, or lifecycle phase | A team or physical-machine boundary |
This is a LAYER STACK diagram. Use that form to understand the layout, then test your interpretation against the source facts below.
Key relationships and design meaning
Relationship 1
Source fact: Gateway applies edge policy and reverse proxying; API owns application composition.
Architectural meaning: Edge policy remains deployable and observable independently from application composition.
Review action: Does the capability need request handling, scheduled execution, or only orchestration?
Relationship 2
Source fact: JobHost executes scheduled work in explicit tenant and audit scopes.
Architectural meaning: Background work uses an explicit execution host, making tenant, retry, scheduling, and shutdown semantics reviewable.
Review action: Is tenant and audit scope explicit in background work?
Relationship 3
Source fact: AppHost provides Aspire orchestration while ServiceDefaults supplies shared telemetry and health behavior.
Architectural meaning: Orchestration and shared defaults reduce host duplication without becoming a place for domain branching.
Review action: Has business policy leaked into Gateway or ServiceDefaults?
Design review questions
Answer each question when reviewing or implementing a related change. If code, tests, or an ADR cannot support the answer, do not decide from the diagram alone.
- Does the capability need request handling, scheduled execution, or only orchestration?
- Is tenant and audit scope explicit in background work?
- Has business policy leaked into Gateway or ServiceDefaults?
How to use the answers
- Identify the single owner of the capability or rule.
- Confirm that dependency, call, or event direction does not reverse ownership.
- Capture the conclusion with an automated test or repeatable command.
Boundaries and common mistakes
Boundary 1
The layers represent runtime responsibility, not a request that always traverses every host.
- Do not infer: A connector in the diagram does not mean every implementation uses synchronous calls, a shared transaction, or shared data ownership.
- Review requirement: Is tenant and audit scope explicit in background work?
Boundary 2
Business policy must remain in modules rather than drift into Gateway or ServiceDefaults.
- Do not infer: A connector in the diagram does not mean every implementation uses synchronous calls, a shared transaction, or shared data ownership.
- Review requirement: Has business policy leaked into Gateway or ServiceDefaults?
Source verification and regeneration
The primary verification entry point is src/Hosts project inventory. Inspect it and its direct references before regenerating diagram assets and pages.
# Regenerate bilingual SVG, standalone HTML, and documentation pagesnpm run diagrams
# Check locale pairs, references, safety attributes, accessibility, and canvas boundsnpm run verify:diagrams# Confirm that generation changed only the intended diagrams and pagesgit diff -- scripts/diagrams diagram-sources public/diagrams src/content/docs
# Verify internal links, MDX structure, and professional depth gatesnpm run verify:docsnpm run audit:docs-depthChange-completion checklist
- Responsibilities, order, states, and relationships match current source.
- Every new element helps answer this page’s question instead of turning the diagram into an inventory.
- Arrows have explicit direction and semantics without implying nonexistent synchronous or transactional guarantees.
- Chinese and English titles, labels, facts, and boundaries remain semantically equivalent.
- The diagram remains readable on narrow screens, in fullscreen, and while zoomed, with no overlap or overflow.
- Relevant architecture tests, integration tests, or verification commands have run.
- If a long-lived constraint changed, its ADR or architecture documentation is updated.