potiuk commented on code in PR #67988:
URL: https://github.com/apache/airflow/pull/67988#discussion_r3358465148


##########
dev/README_RELEASE_HELM_CHART.md:
##########
@@ -1169,17 +1172,27 @@ Do not add `-dev` suffix to the version.
 
 ## Remove old releases
 
-We should keep the old version a little longer than a day or at least until 
the updated
-``index.yaml`` is published. This is to avoid errors for users who haven't run 
``helm repo update``.
+ASF release policy requires that the distribution area (``dist/release``) 
holds only the
+latest release; every superseded version must be removed from ``dist/release`` 
once a new
+version is published. The removed releases are not lost -- they remain 
permanently available
+from the archive at https://archive.apache.org/dist/airflow/helm-chart/. See
+http://www.apache.org/legal/release-policy.html#when-to-archive
 
-It is probably ok if we leave last 2 versions on release svn repo too.
+Do this only *after* the updated ``index.yaml`` has been published (see the 
step above), so
+that users who have not yet run ``helm repo update`` are not left pointing at 
``dist/release``
+URLs that now 404 -- it is the published ``index.yaml`` that rewrites 
old-version URLs to the
+archive.
+
+The snippet below removes every version except the one you just released 
(``${VERSION}``):
 
 ```shell
 # http://www.apache.org/legal/release-policy.html#when-to-archive
-cd cd ${AIRFLOW_REPO_ROOT}/asf-dist/release/airflow/helm-chart
-export PREVIOUS_VERSION=1.0.0
-svn rm ${PREVIOUS_VERSION}
-svn commit -m "Remove old Helm Chart release: ${PREVIOUS_VERSION}"
+cd "${AIRFLOW_SVN_RELEASE_HELM}"
+svn update
+for old_version in $(svn ls | sed 's:/$::' | grep -vx "${VERSION}"); do
+  svn rm "${old_version}"
+done
+svn commit -m "Remove superseded Helm Chart releases, keeping only ${VERSION} 
in dist/release per ASF release policy (older releases remain available from 
https://archive.apache.org/dist/airflow/helm-chart/)"

Review Comment:
   Done — simplified to `svn commit -m "Remove superseded Helm Chart releases"` 
as suggested.
   
   ---
   Drafted-by: Claude Code (Opus 4.8); reviewed by @potiuk before posting
   



##########
dev/README_RELEASE_HELM_CHART.md:
##########
@@ -1169,17 +1172,27 @@ Do not add `-dev` suffix to the version.
 
 ## Remove old releases
 
-We should keep the old version a little longer than a day or at least until 
the updated
-``index.yaml`` is published. This is to avoid errors for users who haven't run 
``helm repo update``.
+ASF release policy requires that the distribution area (``dist/release``) 
holds only the
+latest release; every superseded version must be removed from ``dist/release`` 
once a new
+version is published. The removed releases are not lost -- they remain 
permanently available
+from the archive at https://archive.apache.org/dist/airflow/helm-chart/. See
+http://www.apache.org/legal/release-policy.html#when-to-archive
 
-It is probably ok if we leave last 2 versions on release svn repo too.
+Do this only *after* the updated ``index.yaml`` has been published (see the 
step above), so
+that users who have not yet run ``helm repo update`` are not left pointing at 
``dist/release``
+URLs that now 404 -- it is the published ``index.yaml`` that rewrites 
old-version URLs to the
+archive.
+

Review Comment:
   Agreed for the removal — reworked the paragraph to say removal needs no 
waiting (superseded versions are permanently on archive). I moved the *one* 
timing concern that does remain to where it actually applies: the **new** 
version's archive URL. Archive lags the release, so the "Update index.yaml" 
step now blocks until the new version is live on archive before the index 
references it. That keeps your "don't worry about index.yaml propagation" 
property intact — a stale index only ever contains archive URLs, which never 
404.
   
   ---
   Drafted-by: Claude Code (Opus 4.8); reviewed by @potiuk before posting
   



##########
dev/README_RELEASE_HELM_CHART.md:
##########
@@ -993,7 +993,10 @@ git clone https://github.com/apache/airflow-site.git 
airflow-site
 cd airflow-site
 curl 
https://dist.apache.org/repos/dist/dev/airflow/helm-chart/${VERSION}${VERSION_SUFFIX}/index.yaml
 -o index.yaml
 cp ${AIRFLOW_SVN_RELEASE_HELM}/${VERSION}/airflow-${VERSION}.tgz .
-helm repo index --merge ./index.yaml . --url 
"https://downloads.apache.org/airflow/helm-chart/${VERSION}";
+# Use archive.apache.org (not downloads.apache.org): downloads only keeps the 
latest
+# releases, while archive permanently retains every released version even 
after it is
+# removed from downloads.
+helm repo index --merge ./index.yaml . --url 
"https://archive.apache.org/dist/airflow/helm-chart/${VERSION}";

Review Comment:
   You're right — there is. [ASF infra 
docs](https://infra.apache.org/release-distribution.html) put it at "about a 
day" worst case (in practice usually minutes, at most a few hours). It only 
affects the **just-released** version — superseded versions have been on 
archive since their own release. So rather than point the new version at 
`downloads` (which reintroduces the Fastly-stale-cache problem we just hit), 
the step now blocks until the new `.tgz` is actually downloadable from archive 
before publishing the index entry for it. That way every URL in any served 
index — fresh or Fastly-stale — always resolves.
   
   ---
   Drafted-by: Claude Code (Opus 4.8); reviewed by @potiuk before posting
   



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