Processing Streams with Glue Streaming ETL
This lesson explains Glue streaming jobs, which use the same Spark engine and catalogue as batch jobs, for teams that want Spark-based transformations on Kinesis or Kafka data with code close to their batch jobs.
Learning outcomes
After completing this lesson, you will be able to:
- Describe how Glue streaming jobs process micro-batches.
- Choose between Glue streaming, Flink, Lambda and Firehose.
- Explain the cost of continuously running streaming jobs.
How Glue streaming jobs work
Glue streaming jobs use Apache Spark Structured Streaming to process data continuously. They read from Amazon Kinesis Data Streams, Amazon MSK or self-managed Apache Kafka, and process the data in micro-batches: small batches of the most recent records, processed at a regular interval set by the window size.
Checkpoints stored in Amazon S3 record each job's progress, so a restarted job resumes where it stopped without losing or reprocessing data. Jobs can deserialise records using schemas from the AWS Glue Schema Registry, and they write to S3, Apache Iceberg tables, databases and other streams. For low-volume streams, small G.025X workers keep the cost of a continuously running job down.
The following diagram shows a batch job and a streaming job sharing the same transformation code.

Glue streaming
Choosing a streaming service
Glue streaming ETL is one of four ways to process streams, and the requirement decides which fits. Glue streaming runs Spark Structured Streaming in micro-batches, which suits Spark transformations that reuse logic from batch jobs. Firehose with a Lambda transformation handles simple per-record changes and delivery to S3 or Redshift with the least effort. Managed Service for Apache Flink is for complex stateful processing, such as event-time windows, joins and late data. Lambda consumers are the cheapest option for per-record processing at low volume. The following table summarises the choice.
| Requirement | Choose |
|---|---|
| Spark transformations on streams, reusing batch logic | Glue streaming ETL |
| Simple transformation and delivery to S3 or Redshift | Firehose with a Lambda transformation |
| Complex stateful processing with event-time windows | Managed Service for Apache Flink |
| Per-record processing with low cost at low volume | Lambda consumers |
Which stream processor?
Cost considerations
Streaming jobs run continuously, so their workers are billed all the time, unlike batch jobs that stop when they finish. A streaming job that processes a few records a minute can therefore cost far more over a month than a batch job handling the same data.
Costs are controlled in three ways. Workers are right-sized, using small G.025X workers for low-volume streams. Auto scaling adds and removes workers with the volume of data. And the latency requirement is checked honestly: if results are needed within minutes rather than seconds, longer micro-batch windows, or a batch job that runs every few minutes and then stops, may meet the requirement at a fraction of the cost.
Streaming cost
A team already transforms clickstream files in a nightly PySpark Glue job. The business now wants the same transformations applied within a few minutes of events arriving on a Kinesis stream, and the team wants to reuse its code.
A Glue streaming job reads the Kinesis stream, applies the existing transformation functions to each micro-batch, and writes to the same Iceberg table, with checkpoints in S3. Flink would require rewriting the logic, and Firehose could not apply the Spark transformations.
How does a Glue streaming job resume after a restart?
Show answer
From its checkpoints in S3, which record how far it had processed the stream.
Exam Tips
Remember for the exam
- Glue streaming jobs use Spark Structured Streaming on Kinesis or Kafka.
- Checkpoints in S3 let streaming jobs resume after a restart.
- Glue streaming for Spark-based stream ETL; Firehose for simple delivery; Flink for complex stateful streams.
- Streaming jobs run continuously and are billed all the time.
- Use G.025X workers for low-volume streaming jobs.