Flink Forward 2025 Barcelona: The Future of AI is Real-Time
How do I enable DEBUG/TRACE logging for the Ververica Platform?
Note: This applies to Ververica Platform 2.0 and later.
appmanager
and gateway
are two components in the Ververica Platform. You can turn on DEBUG/TRACE logging either for both or for one of them if you know which one you are interested in.
There are two scenarios to turn on DEBUG/TRACE logging:
Note: This article only discusses the logging of Ververica commercial components. To enable debug logging for your Apache Flink jobs, update your Ververica Platform deployment specification.
1) Find out the Ververica Platform pod
kubectl get pods [--namespace <namespace>] \
-l system=ververica-platform -o name
2) Forward ports: appmanager (9081) and gateway (8081)
kubectl port-forward [--namespace <namespace>] \
pod/<ververica-platform-pod> 8081:8081 9081:9081
3) In another terminal, check the current log level of appmanager
appmanager
curl localhost:9081/actuator/loggers/com.dataartisans
curl localhost:9081/actuator/loggers/com.ververica
gateway
curl localhost:8081/actuator/loggers/com.dataartisans
curl localhost:8081/actuator/loggers/com.ververica
4) Set the log level to DEBUG (or TRACE)
appmanager
curl -i -X POST localhost:9081/actuator/loggers/com.dataartisans \
-H 'Content-Type: application/json' \
-d '{"configuredLevel": "DEBUG"}'
curl -i -X POST localhost:9081/actuator/loggers/com.ververica \
-H 'Content-Type: application/json' \
-d '{"configuredLevel": "DEBUG"}'
gateway
curl -i -X POST localhost:8081/actuator/loggers/com.dataartisans \
-H 'Content-Type: application/json' \
-d '{"configuredLevel": "DEBUG"}'
curl -i -X POST localhost:8081/actuator/loggers/com.ververica \
-H 'Content-Type: application/json' \
-d '{"configuredLevel": "DEBUG"}'
5) Do your test or reproduce your issue.
6) Collect the DEBUG (or TRACE) logs
appmanager
kubectl logs [--namespace namespace] <ververica-platform-pod> \
-c appmanager > appmanager.log
gateway
kubectl logs [--namespace namespace] <ververica-platform-pod> \
-c gateway > gateway.log
7) Reset the log level back
appmanager
curl -i -X POST localhost:9081/actuator/loggers/com.dataartisans \
-H 'Content-Type: application/json' \
-d '{"configuredLevel": null}'
curl -i -X POST localhost:9081/actuator/loggers/com.ververica \
-H 'Content-Type: application/json' \
-d '{"configuredLevel": null}'
gateway
curl -i -X POST localhost:8081/actuator/loggers/com.dataartisans \
-H 'Content-Type: application/json' \
-d '{"configuredLevel": null}'
curl -i -X POST localhost:8081/actuator/loggers/com.ververica \
-H 'Content-Type: application/json' \
-d '{"configuredLevel": null}'
1) Add the following into your values.yaml
:
topLevelConfig:
logging.level.com.dataartisans: DEBUG
logging.level.com.ververica: DEBUG
Warning: topLevelConfig
is at the root level of the YAML file, it is not under vvp
!
Note: This is a temporary workaround and may be changed in future versions of Ververica Platform.
2) Upgrade Ververica Platform with the new values.yaml
and the version your used before, e.g., 3.0.0
# helm 3.x
helm upgrade vvp ververica/ververica-platform \
[--namespace namespace] \
--values values.yaml
--version 3.0.0
# helm 2.x
helm upgrade ververica/ververica-platform --name vvp \
[--namespace namespace] \
--values values.yaml
--version 3.0.0
Warning: This will stop, remove, and recreate your Ververica Platform pod.
3) Collect the DEBUG logs with kubectl logs
1) Decompress the downloaded helm charts archive file, e.g., ververica-platform-2.0.4.tgz
, to a directory, e.g., ververica-platform-2.0.4/
2) Update ververica-platform-2.0.4/templates/deployment.yaml
by adding the following container environment variables to the container appmanager
and/or gateway
under env
- name: logging.level.com.dataartisans
value: DEBUG
3) Upgrade Ververica Platform with helm upgrade
and your original values.yaml
and version, e.g., 3.0.0
:
# helm 3.x
helm upgrade vvp ververica-platform-2.0.4 \
[--namespace namespace] \
--values values.yaml
--version 3.0.0
# helm 2.x
helm upgrade ververica-platform-2.0.4 --name vvp \
[--namespace namespace] \
--values values.yaml
--version 3.0.0
Warning: This will stop, remove, and recreate your Ververica Platform pod.
4) Collect the DEBUG logs with kubectl logs