Unit 3 Cloud Pipelines Notes
S3 as a Data Inbox
Learn how Amazon S3 acts as the front door of a data pipeline — where files land, how they are organized, and how the rest of the system knows they have arrived.
Learning Objectives
- Explain what Amazon S3 is and why businesses use cloud storage instead of local drives or email
- Describe what an S3 bucket is and how folders inside it organize pipeline data
- Create your own S3 bucket, build a folder structure, and upload a real file
- Explain why separating raw, cleaned, and archived data matters in a real business workflow
- Trace how a file uploaded to S3 connects to Lambda and Databricks to start the pipeline automatically
Amazon S3 stands for Simple Storage Service. It is a cloud-based storage system — meaning your files live on Amazon’s servers, accessible from anywhere in the world, rather than on a physical hard drive sitting in your office.
Imagine your business rents a post office box. Every day, suppliers, partners, and customers drop packages into it. You do not need to be there when the packages arrive — they accumulate safely, and you collect them when ready. Amazon S3 is that post office box for data. Files arrive from any source, are stored securely, and wait there until the pipeline is ready to process them.
S3 is format-agnostic — it can store any type of file. In data pipelines, the most common arrivals are:
| Method | The Problem at Scale | How S3 Solves It |
|---|---|---|
| Email attachments | Files get buried in inboxes. There is no reliable trigger when a file arrives. Version control is impossible. | S3 stores files in a defined location. Lambda can detect every single upload automatically — nothing gets missed. |
| Shared network drive | Access is limited to people inside the office network. No automatic triggers exist. Storage does not scale easily. | S3 is accessible from anywhere. It scales to billions of files. Every upload can trigger a downstream workflow. |
| Local hard drive | If the computer fails, the data is gone. Only one person can access it at a time. No automation is possible. | S3 is redundant — Amazon stores copies across multiple locations. Many systems can read the same file simultaneously. |
S3 is not just storage — it is the entry point to automation. The moment a file lands in S3, the pipeline can respond. This is what makes cloud storage fundamentally different from a shared folder on a server: it is designed to be the trigger for action, not just a passive place to keep files.
Picture a large filing cabinet in an office. The cabinet itself is the bucket — it is the main container that holds everything. Inside the cabinet are labelled drawers: one for incoming documents, one for processed records, one for archived files. Each drawer has a clear purpose so that anyone who opens the cabinet knows exactly where to look. An S3 bucket works identically — the bucket is the cabinet, and the folders are the labelled drawers.
A bucket is the top-level container in S3. Every file you store in S3 lives inside a bucket. Each bucket has a globally unique name — no two buckets anywhere in the world can share the same name. Think of it like a website domain: only one person can own datasosi-pipeline-demo at a time.
Inside a bucket, folders organize files by their stage in the pipeline. The industry-standard structure used in real business pipelines looks like this:
The raw folder is read-only in a well-designed pipeline. Databricks reads from it, but never writes back to it. Outputs always go to the cleaned or output folder. Think of the raw folder as the original receipt — you might make a photocopy and annotate it, but you never write on the original.
This is a hands-on unit — everything is done through the AWS console, which is a visual interface, not a coding environment. Follow these steps in order. Each one builds on the previous.
You just rented a filing cabinet in Amazon’s warehouse. It has your unique label on it. Amazon handles the physical storage, security, and maintenance. You manage what goes inside it. This is the core value of cloud infrastructure — you get enterprise-grade storage without buying or managing any hardware.
Open your Databricks notebook and run the following cell. This simulates a pipeline receiving notification that a new file has arrived in S3:
print(“New file ready for processing:”, file_name)
file_name = “sales_data.csv” stores the name of the arriving file in a variable. In a real automated pipeline, this value would not be typed manually — Lambda would pass the actual file name to Databricks the moment the upload was detected. For now, you are simulating that handoff: a file has arrived, Databricks knows its name, and processing is ready to begin. You are not reading the file yet — that comes in Unit 5.
S3 is not just a storage service — it is the connective tissue of the pipeline. Every other component either deposits files into it, reads files from it, or watches it for activity. Understanding S3 is understanding how data enters the automated world.
S3 is like the baggage claim belt at an airport. Bags (files) arrive from many different flights (sources) and land in one organized place. Sensors detect each bag as it arrives (Lambda trigger). Handlers collect the right bags and route them to the correct destination (Databricks processing). The traveller at the end just picks up their bag — clean, ready, no manual sorting required.
By completing this unit, you have created the first physical component of your pipeline: a real S3 bucket with a proper folder structure, containing an actual file. In Unit 5, Databricks will reach into this bucket and read that file. Every unit from here forward builds on the foundation you have just put in place.
Knowledge Check
Five questions covering the key concepts from Unit 3. Select the best answer for each question.
1. What is an Amazon S3 bucket?
2. Why should raw files never be overwritten in a pipeline?
3. In the standard pipeline folder structure, what is the purpose of the archive/ folder?
4. Why is cloud storage like S3 preferable to emailing files for a business data pipeline?
5. What does the optional Databricks code cell in this unit simulate?
Unit 3 Summary
What you covered in this unit
A cloud storage service that acts as the entry point of the pipeline — a secure, scalable inbox where all incoming data files land.
A bucket is the top-level container. Folders inside it — raw/, cleaned/, archive/ — organize files by their stage in the pipeline workflow.
Raw files are never overwritten. Outputs always go to cleaned/ or archive/. Preserving the original means any error can be corrected by rerunning.
When a file lands in S3, Lambda can detect the upload and start Databricks automatically. S3 is not just storage — it is the event that starts the pipeline.