Miretpl commented on code in PR #68074:
URL: https://github.com/apache/airflow/pull/68074#discussion_r3407871141


##########
chart/tests/helm_tests/airflow_aux/test_migrate_database_job.py:
##########
@@ -279,6 +279,77 @@ def test_should_set_correct_helm_hooks_weight(self):
         annotations = jmespath.search("metadata.annotations", docs[0])
         assert annotations["helm.sh/hook-weight"] == "1"
 
+    def test_default_hooks_run_post_install_pre_upgrade(self):
+        # post-install: the chart's bundled postgres is created as a regular
+        # release resource, so the job needs the DB to exist before it runs.
+        # pre-upgrade: the reconciler must run *before* helm rolls the new
+        # image, so on a downgrade it can exec ``airflow db downgrade`` in the
+        # still-running OLD api-server pod (the OLD image still ships the
+        # reverse alembic scripts; the new one does not).
+        # Tracked in https://github.com/apache/airflow/issues/68072.

Review Comment:
   ```suggestion
           # still-running OLD api-server pod.
   ```
   I think that this should be clear for anyone working with Airflow and Helm 
and tracking issue is rather not needed as everyone can see blame for the code 
and what, when and where was introduced.



-- 
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]

Reply via email to