Mathijs Schoorl
11/05/2021, 9:47 AMAnna Geller
11/05/2021, 10:24 AMRunNamespacedJob
task doesn’t collect its logs to the backend. For that you would have to leverage ReadNamespacedPodLogs
task. So it’s not an issue with the UI but rather with this task.
I have to examples to better explain what I mean:
#1 This flow https://github.com/anna-geller/packaging-prefect-flows/blob/master/flows_task_library/s3_kubernetes_run_RunNamespacedJob.py doesn’t collect any logs. It only triggers the pod and finishes.
#2 This flow creates the K8s job, then list pods that are available to find the pod that we’ve just spun up, gets the pod name from the list, and finally gets and prints the logs from this pod: https://github.com/anna-geller/packaging-prefect-flows/blob/master/flows_task_library/s3_kubernetes_run_RunNamespacedJob_and_get_logs.pyMathijs Schoorl
11/05/2021, 10:27 AMAnna Geller
11/05/2021, 11:16 AMMathijs Schoorl
11/05/2021, 11:31 AM