morningman opened a new pull request, #4081:
URL: https://github.com/apache/doris-website/pull/4081

   ## What
   
   Separate maintained releases from archived ones on `/download`, at the 
request of the ASF security team.
   
   Until now every version from 0.13.0 to 4.1.3 sat in the same dropdown with 
an identical affordance. The only hint was one buried sentence, which had 
itself gone stale — it named v1.2 / v1.1 / v0.x as archival, while 3.1, 3.0, 
2.1 and 2.0 had since stopped receiving fixes too.
   
   Maintained releases now hold the page. Archived ones stay reachable, behind 
a plain statement of what archived means, in a zone with no brand green in it.
   
   ## How
   
   One constant drives the split:
   
   ```ts
   export const ACTIVE_CORE_BRANCHES: string[] = ['4.1', '4.0'];
   
   export const ACTIVE_TOOL_LINES: Record<ToolsEnum, string[]> = {
       [ToolsEnum.Kafka]: ['26', '25'],
       [ToolsEnum.Flink]: ['26'],
       [ToolsEnum.Spark]: ['26'],
       [ToolsEnum.StreamLoader]: ['1.0.3'],
       [ToolsEnum.Operator]: ['26'],
   };
   ```
   
   `ACTIVE_VERSIONS`, `ARCHIVED_VERSIONS`, `ACTIVE_TOOL_VERSIONS`, 
`ARCHIVED_TOOL_VERSIONS` and `ACTIVE_HEADS` are all derived from those two, so 
promoting or retiring a branch is a one-line edit. This matches the published 
policy in `community/release-and-verify/release-versioning`: the project 
maintains the two most recent minor branches, labelled Latest and Stable.
   
   **Nothing is deleted from `ALL_VERSIONS` or `TOOL_VERSIONS`.** Archiving is 
removal from the maintained lists, so clusters still running an older branch 
keep a working download path, and the archive picker reads straight from the 
same data.
   
   ## Page changes
   
   - The quick download card keeps its existing segmented **Version / 
Architecture / Tarball** layout and offers the head of each maintained branch. 
A third branch adds one more segment rather than breaking the layout — verified 
by temporarily setting `ACTIVE_CORE_BRANCHES` to three entries.
   - **Doris Releases** and **Doris Ecosystem** list maintained versions only.
   - A new **Archived Releases** section carries a single Project / Version / 
Architecture / Tarball picker covering all 91 archived releases, plus links to 
the upgrade guide, the ASF security reporting page, and 
`archive.apache.org/dist/doris`.
   - The quick card gained `KEYS` and verification links, which [ASF 
download-page policy](https://infra.apache.org/release-download-pages) asks for 
and the page did not have.
   
   ## Notable removals
   
   `DORIS_VERSIONS` and `VersionEnum` are gone. `DORIS_VERSIONS` duplicated 
data that already lives in `ALL_VERSIONS` and had drifted: it still offered 
3.1.4, 3.0.8 and 2.1.11 as quick downloads — exactly the versions being demoted 
here. The quick card now reads `ACTIVE_HEADS` and `findCoreRelease()` instead. 
`VersionEnum.Earlier = '3.1.4'` was the same class of hazard.
   
   ## Reuse over reimplementation
   
   The archive reuses the existing core and tool download forms in a new `bare` 
mode rather than reimplementing link building, so the Flink and Spark 
cascaders, the Streamloader architecture picker, the Operator `docker pull` 
command and the pre-1.2.3 no-architecture path all keep working unchanged. Both 
new props (`bare`, `tone`) are optional and default to current behaviour.
   
   ## Why the add-release skill is in the same PR
   
   It was coupled to the removed structures, and its validator did not just 
fail — **it lost coverage**. The `DORIS_VERSIONS` lookup threw, which skipped 
the entire block containing the nine binary filename checks, the source 
filename version, the source directory and the ordering checks. It would have 
reported 27 PASS / 2 FAIL while silently dropping ~20 real artifact checks.
   
   The validator now checks the branch model, and catches the new failure mode: 
a release that opens a branch never added to `ACTIVE_CORE_BRANCHES` ships a 
version that never appears on the page, with no build error. It also verifies 
the release is the newest patch of its branch, since `ACTIVE_HEADS` takes the 
first child.
   
   A latent bug in its array extractor is fixed too — it matched the first 
occurrence of an identifier, so a doc comment merely naming a constant could 
make it extract the wrong array.
   
   `SKILL.md` gains two sections covering branch promotion/retirement and tool 
lines. It calls out the easiest trap: Streamloader's entry is an exact version, 
so shipping 1.0.4 without editing `ACTIVE_TOOL_LINES` leaves the new release 
archived on arrival.
   
   ## Verification
   
   Against a local dev server:
   
   | Check | Result |
   | --- | --- |
   | Maintained branches offered | `["4.1","4.0"]` |
   | Archive branches offered | `["3.1","3.0","2.1","2.0","1.2","1.1","0.x"]` |
   | Kafka / Flink / Spark / Streamloader / Operator maintained versions | 
`26.0.0, 25.0.0` / `26.1.1, 26.0.0` / `26.0.0` / `1.0.3` / `26.0.1, 26.0.0` |
   | Pre-1.2.3 releases (0.x) | only Project + Version shown, existing 
`showArch` guard intact |
   | Brand-green elements inside the archive zone | none |
   | Filename resolution (4.0.8 + ARM64 + Source) | 
`apache-doris-4.0.8-src.tar.gz` |
   | Release-note link tracks the version picker | 
`/releases/v4.1/release-4.1.3` → `/releases/v4.0/release-4.0.5` |
   | Page errors | none |
   | Horizontal scroll at 390px | none (`scrollWidth == 390`) |
   | Internal links | all 8 resolve |
   | `tsc` | same 179 pre-existing errors as before the change, 0 introduced |
   | `node --test .../validate-release.test.mjs` | 6 tests, 6 pass |
   | Validator against 4.1.3, incl. the twelve-artifact URL matrix | 65 checks 
passed |
   
   ## Out of scope, worth flagging separately
   
   Core binaries, `.asc` and `.sha512` are served from 
`apache-doris-releases.oss-accelerate.aliyuncs.com`, and source tarballs 
deep-link `dist.apache.org`. ASF policy expects signatures, checksums and KEYS 
to come from the Apache distribution directory, and says not to link 
`dist.apache.org` directly. Not changed here, but if the security team is 
already looking at this page it is likely the next question.
   
   The page is English-only: `i18n/zh-CN/code.json` holds only three theme keys 
and the existing `<Translate>` ids have no zh-CN messages. New copy follows 
that convention rather than introducing a half-wired i18n layer.
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)
   
   https://claude.ai/code/session_01V9C9dPvMXAqhb93sVbeyAN
   


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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to