Westport Horizon LLC
Data engineering project

Simple Data
Environment

A complete analytics platform in the cloud. Every day, it collects data, cleans it and makes it ready for business reports. It runs automatically and costs about $1–2 per month.

Example business: a fictional coffee and bakery chain with 49 stores in 36 cities across 8 European countries (3 to 10 stores per country) and about 1,200 orders a day, plus real exchange rates and real weather data.
1
CollectGet new data from three sources
2
StoreKeep a raw copy in a cloud data lake
3
Clean and modelMake tested, report-ready tables
4
ReportShow KPIs and trends in Power BI
3
data sources: one generated, two real public APIs
3
data layers: raw, clean, report-ready
50
automatic data tests on each run
89
business measures in the Power BI model
≈ $1–2
cloud cost per month. All other tools are free
Westport Horizon LLC|Simple Data Environment1 / 5
Architecture

How the parts connect

Data moves from left to right. It is stored only once, in Amazon S3. All tools read the same files through one catalog and one SQL engine.

SOURCES COLLECT REPORT Store sales Mock data generator Exchange rates Frankfurter API (ECB) Weather Open-Meteo API dlt Python loader AWS cloud · eu-west-1 Amazon S3 data lake · Parquet files in Apache Iceberg tables Bronze raw data Silver cleaned Gold report-ready dbt dbt AWS Glue Data Catalog Lists each table and its location Amazon Athena SQL engine, runs only on demand Power BI Reports and KPIs AUTOMATION GitHub Actions Runs the pipeline daily and tests each code change Terraform Creates all AWS resources from code
1Open formats. Parquet and Iceberg are open standards. Many tools can read the data, so there is no vendor lock-in.
2No servers. Athena starts only when a query runs. There is no cluster to maintain or pay for.
3Fast reports. Power BI imports the gold tables. A click in a report does not send a query to the cloud.
Westport Horizon LLC|Simple Data Environment2 / 5
Tech stack

One tool for each job

Each tool is a well-known industry standard. All parts are defined as code and kept in git, so each change is easy to review and repeat.

Collect
dlt (data load tool)

Gets new data from each source and loads it into the lake. It remembers the last load, so each run gets only new data.

Python 3.12REST APIs
Store
Amazon S3 + Apache Iceberg

Low-cost cloud storage. Iceberg adds database features to plain files: safe updates, version history and schema changes.

Parquetzstd
Query
Amazon Athena + AWS Glue

Runs SQL directly on the files in S3. Glue keeps the list of tables. You pay only for the data that each query reads.

Trino SQLserverless
Transform
dbt Core

Turns raw data into clean tables with SQL. It adds tests, documentation and a lineage graph of all tables.

dbt-athenaSQL
Report
Power BI Desktop

Dashboards for revenue, margin, customers and trends. The model and report are stored as text files in git.

DAX.pbipODBC
Automate
GitHub Actions

Starts the pipeline each day and checks each code change. Jobs that touch data run on AWS in Ireland. There is no separate scheduling server.

cronCI/CDOIDC
Infrastructure
Terraform

Defines all cloud resources as code: storage, catalog, SQL engine, access rights and cost alerts.

AWS IAMIaC
Code quality
uv, ruff, sqlfluff, pytest

Checks the Python and SQL code before each change goes live. The same checks run on the developer PC and in CI.

pre-commitlinttests
Westport Horizon LLC|Simple Data Environment3 / 5
Data flow

From raw data to business answers

Three quality layers (medallion design)
Bronze
Raw copy

Data exactly as it arrives. Nothing is changed or deleted, so the full history stays available.

written by dlt
Silver
Clean

Correct data types and no duplicates. Each run merges only the new data. Changes to customers and prices are kept as history.

built by dbt
Gold
Report-ready

A star schema for reports. Sales are in local currency and in euro, at the exchange rate of that day.

built by dbt
What the Power BI report shows
Overview pageRevenue, orders, average order value, margin and active customers. Revenue by day, week or month with a rolling average, per country and product category. Every chart has a custom tooltip.
Trends pageBollinger bands show days, weeks or months with unusual revenue. Lists show the 5 products that grow fastest and the 5 that fall fastest.
Gold layer: star schema
Date one row per day Customer with change history Product category and price Store country and currency Sales one row per order line fct_sales

Facts (what happened) link to dimensions (who, what, where, when). A second fact table joins daily weather to the sales of each store.

The daily run · starts at 05:30 UTC, no manual work
1
Sign inTemporary AWS access, no stored keys. Runs in Ireland
2
CollectNew sales, rates and weather into bronze
3
CleanApply deletion requests, merge new data into silver
4
ModelRebuild the gold star schema
5
Test50 data tests and freshness checks
6
DocumentRebuild the data documentation
Westport Horizon LLC|Simple Data Environment4 / 5
Operations

Tested, secure and low cost

Tested
50 data tests on each run
  • Tests check keys, links between tables, value ranges and order totals.
  • Each code change gets a full test build in temporary databases. The live data does not change.
  • An alert shows when a source stops sending new data.
  • Style checks for Python, SQL, Terraform and the Power BI report run on each change.
Secure
0 stored keys in automation
  • The pipeline signs in to AWS with short-lived tokens (OIDC).
  • Each role gets only the access that it needs. Reports can read only the gold layer.
  • Storage is private and encrypted. Data is processed only in the EU (Ireland).
  • Analysts can't see customer names or emails, and a customer can be erased on request.
  • Each tool and person has a separate identity. A lost key affects only one role.
Low cost
$1–2 per month
  • A query stops automatically if it would read more than 1 GB.
  • Temporary files are deleted after 7 days. Tables are compacted each week.
  • An email alert comes before the monthly budget is used.
  • Reports use imported data. A click in a report adds no query cost.
Serverless, not a clusterNothing to run or patch. Cost follows use.
Incremental loadsEach run reads only new data. Runs stay fast.
Everything as codeCloud setup, SQL and reports are all in git.
Easy to growAdd a source or a report without a change to the design.
Westport Horizon LLC|Simple Data Environment5 / 5
Appendix · Tool guide

Language, loading and storage

Programming language
Python

Python is a general-purpose programming language. Guido van Rossum released the first version in 1991. Its code is short and easy to read, so it is a common first language and a common language for experts.

Python is the most popular language for data work. A very large set of free libraries covers data loading, analysis, machine learning and automation. Most data tools have a Python interface.

Python Software Foundationopen source
Data loading
dlt (data load tool)

dlt is an open-source Python library that moves data from a source to a destination. Sources can be REST APIs, databases or files. Destinations can be data warehouses, databases or data lakes.

dlt reads the incoming data and creates the table structure automatically. It changes nested JSON into flat tables, adapts when new fields appear, and can load only the data that is new since the last run.

dltHubApache 2.0
Cloud storage
Amazon S3

Amazon Simple Storage Service (S3) is the object storage service of Amazon Web Services. It started in 2006 and was one of the first AWS services. Files are stored as objects in containers called buckets.

S3 is designed for very high durability, and there is no limit on the total size of the data. You pay for the gigabytes that you store and for the requests. Many data lakes on AWS use S3 as their storage layer.

AWSmanaged service
File format
Apache Parquet

Parquet is an open file format for tables of data. It started in 2013 as a joint project of Twitter and Cloudera and is now part of the Apache Software Foundation.

Parquet stores data column by column, not row by row. A query can read only the columns that it needs, and similar values compress well. Files are much smaller than CSV, and almost all data tools can read them.

Apache Software FoundationApache 2.0
Westport Horizon LLC|Simple Data EnvironmentAppendix A1
Appendix · Tool guide

Tables, catalog, query and transform

Table format
Apache Iceberg

Iceberg is an open table format for very large data sets. Netflix created it and gave it to the Apache Software Foundation in 2018. It keeps track of which data files make up a table, and of each version of the table.

Iceberg gives plain files in a data lake the features of a database table: safe updates and deletes, schema changes, and "time travel" to read older versions. Many engines can use the same table, for example Spark, Trino, Flink, Snowflake and Athena.

Apache Software FoundationApache 2.0
Metadata catalog
AWS Glue Data Catalog

The Glue Data Catalog is a central list of the data sets in an AWS account. For each table it stores the name, the columns and their data types, and the place where the files are kept.

The catalog is part of AWS Glue, which also offers serverless data-processing jobs. Many AWS services, such as Athena, EMR and Redshift Spectrum, use the same catalog, so all of them see the same tables.

AWSmanaged service
SQL query engine
Amazon Athena

Athena is a serverless service that runs SQL queries directly on files in Amazon S3. It started in 2016 and is based on the open-source engines Presto and Trino.

There are no servers to set up or keep running. Athena starts when a query arrives and stops when the query is done. The price depends on the amount of data that each query reads, so compressed columnar files make queries cheaper.

AWSserverless
Data transformation
dbt Core

dbt (data build tool) is an open-source tool that transforms data that is already in a warehouse or lake. Each data model is a SQL SELECT statement. dbt builds the models in the correct order, as tables or views.

dbt brings software practices to SQL work: version control, automatic tests, documentation and a lineage graph that shows how tables depend on each other. dbt Labs makes it and also sells a hosted version, dbt Cloud.

dbt LabsApache 2.0
Westport Horizon LLC|Simple Data EnvironmentAppendix A2
Appendix · Tool guide

Reporting, automation and infrastructure

Business intelligence
Power BI Desktop

Power BI is the business intelligence platform of Microsoft. Power BI Desktop is the free Windows application for building reports. It connects to many data sources, prepares the data with Power Query and calculates measures with the DAX formula language.

Reports can be shared through the Power BI Service in the cloud, which needs a paid licence for most sharing. A newer project format saves the model and the report as text files, so they can be kept in version control.

Microsoftfree desktop app
Automation and CI/CD
GitHub Actions

GitHub Actions is the automation service built into GitHub. A workflow is a YAML file in the repository. It runs when an event happens, for example a push, a pull request or a fixed time schedule.

Jobs run on virtual machines with Linux, Windows or macOS that GitHub hosts, or on your own machines. A large marketplace offers ready-made steps. Teams use it to test, build and deploy code, and to run scheduled tasks.

GitHubhosted runners
Infrastructure as code
Terraform

Terraform is a tool for infrastructure as code. HashiCorp released it in 2014. You describe servers, storage, networks and access rights in text files, and Terraform creates or changes them to match.

Before each change, "terraform plan" shows exactly what will be added, changed or removed. Providers connect Terraform to AWS, Azure, Google Cloud and hundreds of other services. OpenTofu is an open-source fork of Terraform.

HashiCorpHCLBSL 1.1
Python package manager
uv

uv is a package and project manager for Python, written in Rust by the company Astral. It was released in 2024. It is often 10 to 100 times faster than pip.

One tool replaces several older ones: it installs packages, creates virtual environments, installs Python versions and writes a lock file. The lock file makes sure that every computer gets exactly the same package versions.

AstralMIT / Apache 2.0
Westport Horizon LLC|Simple Data EnvironmentAppendix A3
Appendix · Tool guide

Code quality and testing

Python linter and formatter
Ruff

Ruff is a linter and code formatter for Python, also from Astral and also written in Rust. A linter finds possible bugs and style problems. A formatter rewrites the code into one consistent layout.

Ruff has more than 800 rules and replaces older tools such as Flake8, isort and Black. It is so fast that it can check a large project in less than a second, so it is easy to run on each save.

AstralMIT
SQL linter and formatter
SQLFluff

SQLFluff is an open-source linter and formatter for SQL, written in Python. It finds style problems and errors in SQL code and can fix many of them automatically.

It supports many SQL dialects, for example Postgres, Snowflake, BigQuery and Trino. It also understands templated SQL, such as Jinja in dbt models, so teams can keep one SQL style across a whole project.

community projectMIT
Test framework
pytest

pytest is the most widely used test framework for Python. A test is a normal Python function with plain "assert" statements. pytest finds the tests, runs them and shows clear reports when a test fails.

Fixtures give tests the data and resources that they need, and parametrization runs one test with many inputs. More than a thousand plugins add features such as coverage reports and parallel runs.

pytest-devMIT
Git hook manager
pre-commit

pre-commit is a framework that runs checks automatically before each git commit. The checks are listed in one configuration file in the repository. If a check fails, the commit stops until the problem is fixed.

pre-commit installs each check in its own isolated environment and supports tools in many languages. Every developer runs the same checks, and the same configuration can also run in CI.

pre-commit projectMIT
Westport Horizon LLC|Simple Data EnvironmentAppendix A4
1 / 5