Get Started Free
course: Apache Flink® 101

Docker Setup for the Hands-on Exercises

10 min
David Anderson

David Anderson

Principal Software Practice Lead

Docker Setup for the Hands-on Exercises

The hands-on exercises for this course are available in two variants: those that can be done using Confluent Cloud, and those that can be done with open source Apache Flink and Apache Kafka running in Docker.

To get started with Docker, follow the instructions below. For Confluent Cloud, see the instructions here.

With Docker running, execute the following steps to launch Flink and Kafka clusters:

git clone https://github.com/confluentinc/learn-apache-flink-101-exercises.git
cd learn-apache-flink-101-exercises
docker compose up --build -d

Then you can use

docker compose run sql-client

to start the Flink SQL Client CLI, yielding this prompt:

Flink SQL>

Note: If you see this warning

WARNING: Unknown module: jdk.compiler specified to --add-exports

you can safely ignore it.

At any time you can use the help; command to get help from the SQL CLI.

When you're done, you can exit Flink SQL with quit;.

How to shut down Docker

When you want to shut down the Flink and Kafka clusters, you can do that with

docker compose down -v

which will stop all of the containers and remove the volume used for checkpointing.

But you may want to leave everything running for now, as you can use this same setup in the other exercises.

Resources

Do you have questions or comments? Join us in the #confluent-developer community Slack channel to engage in discussions with the creators of this content.

Be the first to get updates and new content

We will only share developer content and updates, including notifications when new content is added. We will never send you sales emails. 🙂 By subscribing, you understand we will process your personal information in accordance with our Privacy Statement.