# sfroee/cloud-sample-spaceflight architecture

> Architecture diagram of the GitHub repository sfroee/cloud-sample-spaceflight, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-13). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sfroee/cloud-sample-spaceflight
- Repository: https://github.com/sfroee/cloud-sample-spaceflight

## Overview

This repository is a SAP Core Data Services model for a space-itinerary company, with flight and space domain definitions, service definitions, and bundled table data. The likely user-facing workflow is booking or querying flight and space information through the services backed by those models. The README identifies the project as a base data model, but the CDS sources were not sampled, so service-to-model and data-loading relationships are shown as unverified rather than asserted as direct calls.

Main entry points: [`db/flight-model.cds`](https://github.com/sfroee/cloud-sample-spaceflight/blob/master/db/flight-model.cds) (Flight Model), [`srv/booking-service.cds`](https://github.com/sfroee/cloud-sample-spaceflight/blob/master/srv/booking-service.cds) (Booking Service), [`db/space-model.cds`](https://github.com/sfroee/cloud-sample-spaceflight/blob/master/db/space-model.cds) (Space Model), [`srv/flight-service.cds`](https://github.com/sfroee/cloud-sample-spaceflight/blob/master/srv/flight-service.cds) (Flight Service)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_services["CDS Services"]
  node_booking["Booking Service"]
  node_flight_service["Flight Service<br/>[flight-service.cds]"]
  node_annotations["Fiori Annotations"]
end

subgraph group_models["Domain Models"]
  node_flight_model["Flight Model<br/>[flight-model.cds]"]
  node_space_model["Space Model<br/>[space-model.cds]"]
  node_common_model["Shared Model<br/>[common.cds]"]
end

subgraph group_seed["Seed Data"]
  node_flight_data["Flight Seed Data"]
  node_space_data["Space Seed Data"]
end

node_consumer(("Application Consumer"))

node_consumer -.->|"uses"| node_booking
node_consumer -.->|"uses"| node_flight_service
node_booking -.->|"uses model"| node_flight_model
node_booking -.->|"uses model"| node_space_model
node_flight_service -.->|"uses model"| node_flight_model
node_flight_model -.->|"extends"| node_common_model
node_space_model -.->|"extends"| node_common_model
node_flight_data -.->|"seeds"| node_flight_model
node_space_data -.->|"seeds"| node_space_model

click node_booking "https://github.com/sfroee/cloud-sample-spaceflight/blob/master/srv/booking-service.cds"
click node_flight_service "https://github.com/sfroee/cloud-sample-spaceflight/blob/master/srv/flight-service.cds"
click node_annotations "https://github.com/sfroee/cloud-sample-spaceflight/blob/master/srv/fiori-annotations.cds"
click node_flight_model "https://github.com/sfroee/cloud-sample-spaceflight/blob/master/db/flight-model.cds"
click node_space_model "https://github.com/sfroee/cloud-sample-spaceflight/blob/master/db/space-model.cds"
click node_common_model "https://github.com/sfroee/cloud-sample-spaceflight/blob/master/db/common.cds"
click node_flight_data "https://github.com/sfroee/cloud-sample-spaceflight/tree/master/db/src/csv"
click node_space_data "https://github.com/sfroee/cloud-sample-spaceflight/tree/master/db/src/csv"

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_booking,node_flight_service,node_annotations toneBlue
class node_flight_model,node_space_model,node_common_model toneAmber
class node_flight_data,node_space_data toneMint
class node_consumer toneIndigo
```

## Components

### CDS Services

- [Booking Service](https://github.com/sfroee/cloud-sample-spaceflight/blob/master/srv/booking-service.cds): `srv/booking-service.cds`
- [Flight Service](https://github.com/sfroee/cloud-sample-spaceflight/blob/master/srv/flight-service.cds): `srv/flight-service.cds`
- [Fiori Annotations](https://github.com/sfroee/cloud-sample-spaceflight/blob/master/srv/fiori-annotations.cds): `srv/fiori-annotations.cds`

### Domain Models

- [Flight Model](https://github.com/sfroee/cloud-sample-spaceflight/blob/master/db/flight-model.cds): `db/flight-model.cds`
- [Space Model](https://github.com/sfroee/cloud-sample-spaceflight/blob/master/db/space-model.cds): `db/space-model.cds`
- [Shared Model](https://github.com/sfroee/cloud-sample-spaceflight/blob/master/db/common.cds): `db/common.cds`

### Seed Data

- [Flight Seed Data](https://github.com/sfroee/cloud-sample-spaceflight/tree/master/db/src/csv): `db/src/csv`
- [Space Seed Data](https://github.com/sfroee/cloud-sample-spaceflight/tree/master/db/src/csv): `db/src/csv`

### Other components

- **Application Consumer**

## Connections

- Application Consumer → Booking Service: uses
- Application Consumer → Flight Service: uses
- Booking Service → Flight Model: uses model
- Booking Service → Space Model: uses model
- Flight Service → Flight Model: uses model
- Flight Model → Shared Model: extends
- Space Model → Shared Model: extends
- Flight Seed Data → Flight Model: seeds
- Space Seed Data → Space Model: seeds
