Parallelism
To enable parallel task execution, configure multiple Flink TaskManagers to point to a single JobManager.
The basic configuration pattern for Docker Compose is:
jobmanager:
image: here-anonymizer:latest
environment:
# ...
- |
FLINK_PROPERTIES=
jobmanager.rpc.address: jobmanager
parallelism.default: 3
taskmanager:
image: here-anonymizer:latest
# ...
scale: 3Example
-
From the application directory, build the
here-anonymizer:latestimage:docker build -t here-anonymizer:latest . -
Run the example:
cd ./deployments/docker/parallelism/ docker-compose up -d -
Inspect the Flink console at http://localhost:8081:
- Check the
Running Jobs -> HERE Anonymizerand verify that the second block of operators is described asParallelism: 3. - Check
TaskManagersand verify if you can see three TaskManagers.
- Check the
-
Run this command to stop the example:
docker-compose down
Updated 25 days ago