Skip to main content

How to run Apache Flink Locally

Apache Flink is a powerful stream-processing engine. It can also run Apache Beam pipelines and templates using the Flink Runner. This short guide walks you through setting up Flink on your laptop in just a few steps.

Use wget to download the latest Flink 1.19 release (Scala 2.12 build):

wget https://dlcdn.apache.org/flink/flink-1.19.3/flink-1.19.3-bin-scala_2.12.tgz

Step 2: Extract the Archive​

Unpack the downloaded archive:

tar -xzf flink-1.19.3-bin-scala_2.12.tgz

Navigate into the extracted directory and start a local cluster:

cd flink-1.19.3

# Start the cluster
./bin/start-cluster.sh

Step 4: Verify the Cluster​

Once started, open the Flink Web UI in your browser:

πŸ‘‰ http://localhost:8081/

If the UI loads, your local Flink cluster is up and running! πŸŽ‰
Next, try running some LangBeam templates on your Flink cluster πŸ˜ƒ

Step 5: Stop the Cluster​

When you’re done, stop the cluster to free up resources:

./bin/stop-cluster.sh