kaxil commented on a change in pull request #20573:
URL: https://github.com/apache/airflow/pull/20573#discussion_r776800462
##########
File path: airflow/providers/cncf/kubernetes/operators/kubernetes_pod.py
##########
@@ -573,6 +573,15 @@ def build_pod_request_obj(self, context=None):
)
return pod
+ def dry_run(self) -> None:
+ """
+ Prints out the pod definition that would be created by this operator.
+ Does not include labels specific to the task instance (since there
isn't
+ one in a dry_run) and excludes all empty elements.
+ """
+ pod = self.build_pod_request_obj()
Review comment:
Do you think we should use `pod_mutation_hook` on the POD object:
https://github.com/apache/airflow/blob/e07e8319465ea4598791b6b61b5fe7c46f159f86/airflow/settings.py#L184-L196
https://github.com/apache/airflow/blob/e07e8319465ea4598791b6b61b5fe7c46f159f86/airflow/providers/cncf/kubernetes/utils/pod_launcher.py#L102-L104
or show an original one, and the one with the changes from pod_mutation_hook
🤷 -- I have no strong opinion on this but just wanted to open it up for
discussion
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]