Repository navigation
[HWORKS-3579] Upgrade Kueue from 0.18.1 to 0.20.2 and move the Hopsworks Kueue models to v1beta2 - #709
[HWORKS-3579] Upgrade Kueue from 0.18.1 to 0.20.2 and move the Hopsworks Kueue models to v1beta2#709jimdowling wants to merge 16 commits into
Conversation
66fd21e to
52482e1
Compare
2aa0b81 to
22ee8dc
Compare
…ed outside the Hopsworks namespace, migrating existing queues and CRDs https://hopsworks.atlassian.net/browse/HWORKS-3565 Every release from 4.3 bundles Kueue 0.12.2 in the Hopsworks release namespace. From 5.3 Hopsworks can use a Kueue installed as its own release in kueue-system instead (hw-kueue.kueue.enabled=false), and the chart ships files/migrate-to-external.sh to move a running cluster to Kueue 0.18.1 while keeping every Kueue object. The docs add an operator page for that move: why helm upgrade alone cannot do it, the script's phases, what to prepare (snapshot, maintenance window, tools, airgapped images, admin API key), the command, what changes for queues and Hopsworks afterwards (no topologyName on flavors, parentName on Cohorts, queues managed with kubectl, Hopsworks-namespace jobs queued, the queue utilisation view failing until the backend reads Cohorts at v1beta1) and how to verify. The hw-kueue values page links to it. Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ed outside the Hopsworks namespace, migrating existing queues and CRDs https://hopsworks.atlassian.net/browse/HWORKS-3565 Clusters whose releases Flux manages. Flux reconciles a HelmRelease back to Git, so the helm upgrades in remove-bundled, install-kueue and enable-hopsworks would be reverted on a Flux-managed cluster. logicalclocks.github.io: the Kueue operator page gains a section on clusters managed by Flux (what to commit at each phase, what the script waits for, the queue export) and lists export-queues. Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ed outside the Hopsworks namespace, migrating existing queues and CRDs https://hopsworks.atlassian.net/browse/HWORKS-3565 Step-by-step instructions for clusters managed by Flux. logicalclocks.github.io: the Flux section of the Kueue operator page becomes a runbook for --gitops: what to have before starting (Flux 2.3 or later, Git access, the Helm release name and namespace, where the HelmRelease values live, a terminal that survives a dropped connection), then one step per change to commit, with the command, the HelmRelease YAML, the flux reconcile command that applies it at once and what the script waits for, then where the queue manifests go (a Kustomization depending on the Kueue one) and how to resume after a timeout. Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
22ee8dc to
16c9c30
Compare
…ed outside the Hopsworks namespace, migrating existing queues and CRDs https://hopsworks.atlassian.net/browse/HWORKS-3565 Review comments on logicalclocks/hopsworks-helm#2599. logicalclocks.github.io: the Kueue operator page runs the migration script with bash in every command, because helm package stores it without the execute bit and a direct call fails with permission denied. Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rks Kueue models to v1beta2 https://hopsworks.atlassian.net/browse/HWORKS-3579 Kueue 0.20.2 is the latest release and stops serving kueue.x-k8s.io/v1beta1, which every Hopsworks Kueue model still used. Kueue 0.18.1 serves both v1beta1 and v1beta2, so the backend moves to v1beta2 first and runs on 0.18.1 and 0.20.2, then the external Kueue installed by HWORKS-3565 is upgraded to 0.20.2 and the bundled one in hw-kueue moves to 0.20.2 as well. Tested on the Proxmox cluster jim-kueue-ui (snurran, 4 GPUs), migrated to 0.18.1 by HWORKS-3565: the upgrade kept all 106 queue objects and verify passed, and the loadtests gave 31 passed, 1 skipped on 0.20.2 (one Ray MNIST run failed in its training script and passed when rerun). logicalclocks.github.io: the Kueue operator page says 5.3 bundles Kueue 0.20.2 and that a cluster on the bundled 0.12 moves to the external Kueue when it upgrades. It adds the upgrade-kueue phase, the managedFields reset, the path for a cluster already on 0.18.1, the mirrors an airgapped cluster needs, the 0.19 and 0.20 default changes, and the prerequisite check for both modes. The queue utilisation gap is gone. Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rks Kueue models to v1beta2 https://hopsworks.atlassian.net/browse/HWORKS-3579 Spark jobs on Kueue. Kueue never managed Hopsworks Spark jobs: they run as Spark Operator SparkApplications, which Kueue admits only through its SparkApplication integration, alpha since 0.17 and off by default (SparkApplicationIntegration gate, sparkoperator.k8s.io/sparkapplication commented out of the default frameworks). The integration reserves quota for the driver plus spec.executor.instances and refuses dynamicAllocation.enabled unless the job is elastic, and even an elastic job leaves the executors its driver adds uncharged. So the integration is turned on and, while Kueue is on, Spark jobs run with static executors only. logicalclocks.github.io: the Kueue details page gains a Spark jobs section (static executors only, error 130082, defaults, jobs saved before Kueue, notebooks unaffected) and its examples move to kueue.x-k8s.io/v1beta2 (cohortName, no topologyName on the default flavor). The scheduler page, the Spark and PySpark job guides and the Kueue operator page say Spark jobs are queued with static executors. Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rks Kueue models to v1beta2 https://hopsworks.atlassian.net/browse/HWORKS-3579 Spark jobs reach Kueue. With the SparkApplication integration on, a test run still showed no Spark Workload: the backend gave Spark jobs no queue, so their SparkApplications carried no queue-name label and Kueue ignored them. With a queue, Kueue admitted the job and then could not start it: unsuspending sets the driver and executor pod templates, and the Spark Operator 2.5.1 webhook refused that with "pod template feature requires Spark version 3.0.0 or higher", because it compares spec.sparkVersion as semver and ranks an invalid one below every valid one, and Hopsworks writes 4.1.3.0. On jim-kueue-ui, Kueue 0.20.2 with the integration on, the Kueue, Spark job, default job configuration, rerun and job failure loadtests gave 14 passed, and Kueue admitted 9 SparkApplication Workloads into ClusterQueue other. logicalclocks.github.io: the Kueue details page says Spark jobs go to the project's default queue unless they select another, and that a Spark job saved without a queue gets the default when it starts. Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rks Kueue models to v1beta2 https://hopsworks.atlassian.net/browse/HWORKS-3579 Fixes from a Codex review of the change set (nine findings and one suspicion, each checked against the code before it was fixed). logicalclocks.github.io: the Kueue operator page says the managedFields cleanup drops only old entries, that the 0.20.2 chart comes from the upstream OCI registry (--kueue-target-repo), and which flags point an airgapped cluster at its mirrors. Reviewed-by: OpenAI Codex (codex-plugin-cc 1.0.6) <codex@openai.com> Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rks Kueue models to v1beta2 https://hopsworks.atlassian.net/browse/HWORKS-3579 Rebased on HWORKS-3565 with its Flux runbook. logicalclocks.github.io: the Flux runbook on the Kueue operator page gains Step 5, upgrade-kueue: the script applies the 0.20.2 CRDs and rewrites the Kueue HelmRelease for 0.20.2 (chart from the upstream OCI registry, Spark settings, a post-render patch that keeps the chart's templated CRDs out of the release), the operator replaces the file committed in Step 3, and the script waits for the controller to run 0.20.2. Verification and the queue export become Step 6. Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
16c9c30 to
9cdd58b
Compare
…rks Kueue models to v1beta2 https://hopsworks.atlassian.net/browse/HWORKS-3579 Kueue 0.20.3. The upgrade-kueue entry states that it waits for the Hopsworks release to finish deploying, keeps release kueue's own values and refuses a manager configuration that is not v1beta2. Reviewed-by: OpenAI Codex (codex-plugin-cc 1.0.6) <codex@openai.com> Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Move the upgrade note into Please add a
|
| - **Jobs in the Hopsworks namespace are queued.** | ||
| Kueue 0.18 ignores the namespace it runs in, which is now `kueue-system`, so Kueue-labelled jobs in the Hopsworks namespace are queued. |
There was a problem hiding this comment.
Please drop this bullet. It is not a change an operator sees. Hopsworks creates its Kueue-queued system jobs in the project namespaces, not the Hopsworks namespace: zipping, git, library installs and image builds, and DLT schema fetches (hopsworks-ee KubeSystemJobManger.java:178,185, KubeDockerUtils.java:1712, NoSqlSourceSchemaController.java:317). Before 0.18, Kueue also managed batch Jobs in its own namespace, so the bundled 0.12 queued these jobs too. Kueue 0.18 excluding its own namespace (CHANGELOG-0.18.md:661-673) therefore changes nothing for Hopsworks, with either the bundled or the external Kueue.
The same claim, in its bundled form ("system jobs are not queued with the bundled Kueue"), is in hopsworks-helm#2602's UPGRADE.md and specification.md. That PR has a comment asking for it to be removed too, so please don't carry it into the 5.3 upgrade section either.
Upstream published the Helm upgrade guide here (HWORKS-3580) and moved the Kafka 4 notes under a new Upgrades section of the admin nav. Kueue outside the Hopsworks namespace moves into that section, and the upgrade guide's 5.2.x to 5.3.x section gets an entry for it that links the runbook, replacing the UPGRADE.md section the chart no longer ships. Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rks Kueue models to v1beta2 https://hopsworks.atlassian.net/browse/HWORKS-3579 The 5.3 chart no longer ships migrate-to-external.sh: a cluster on the bundled Kueue 0.12 moves to the external Kueue 0.18.1 on Hopsworks 5.1, upgrades Hopsworks to 5.3, then upgrades Kueue to 0.20.3 with the 5.1 script's upgrade-kueue phase. docs: kueue_external.md runs the move in those three steps, with the latest 5.1 chart, and the Flux steps follow the same order. all no longer includes upgrade-kueue, which refuses a Hopsworks release older than 5.3. The --kueue-image option for the upstream images is listed. The upgrade guide's Kueue entry says where the script comes from. Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rks Kueue models to v1beta2 https://hopsworks.atlassian.net/browse/HWORKS-3579 The Kueue 0.20 changes ship in a 5.2.x patch release as well as in 5.3. docs: kueue_external.md and the upgrade guide's Kueue entry name the target as a Hopsworks release that bundles Kueue 0.20, a 5.2.x patch release or 5.3, in place of 5.3, and upgrade-kueue's refusal as a chart that bundles an older Kueue. Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rks Kueue models to v1beta2 https://hopsworks.atlassian.net/browse/HWORKS-3579 A 5.1 cluster stays on Kueue 0.18; the step to Kueue 0.20.3 ships with the Hopsworks release that bundles it. docs: kueue_external.md names two scripts. The 5.1 chart's migrate-to-external.sh moves a cluster to Kueue 0.18.1 on 5.1, and the new chart's upgrade-kueue.sh, run after the Hopsworks upgrade, takes it to 0.20.3. The upgrade-kueue phase row gives way to a description of upgrade-kueue.sh and its refusals; the Flux Step 5 runs it with --gitops and commits the HelmRelease it writes to ./kueue-upgrade. Signed-off-by: Jim Dowling <jim@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
https://hopsworks.atlassian.net/browse/HWORKS-3579
Stacked on #708 (HWORKS-3565): until it merges this PR also shows its commit.
Summary
docs/setup_installation/admin/kueue_external.md:v1beta2, so a cluster on the bundled 0.12 moves to the external Kueue when it upgrades (it was optional).upgrade-kueuephase, themanagedFieldsreset, and the two-phase path for a cluster already on 0.18.1.--kueue-repotakesoci://.markdownlint-cli2 passes.
Spark jobs on Kueue
Kueue never managed Hopsworks Spark jobs: they run as Spark Operator
SparkApplications, which Kueue admits only through its SparkApplication integration (alpha since 0.17, off by default). That integration reserves quota for the driver plusspec.executor.instancesand refusesdynamicAllocation.enabledunless the job is elastic, and even then the executors the driver adds are not charged. This PR set therefore:SparkApplicationIntegrationgate plus thesparkoperator.k8s.io/sparkapplicationframework) inmigrate-to-external.sh, the bundled hw-kueue values and terraform'sinstall_kueue.sh(logicalclocks/terraform#178);spec.sparkVersionas semver (4.1.3, not4.1.3.0): the Spark Operator 2.5.1 webhook ranks an invalid version below 3.0.0 and refused the pod templates Kueue sets when it resumes an admitted job, which left every Spark job suspended.Spark jobs saved before this release have dynamic allocation on (the old default) and are refused on a Kueue cluster until they are switched to static executors; UPGRADE.md and the docs say so.
Spark testing on
jim-kueue-ui(Kueue 0.20.2, integration on, backend from this branch):test_kueue_queues.py,test_spark_job_execution.py,test_default_job_configuration.py,test_execution_rerun.pyandtest_job_failure_handling.pygave 14 passed. A watcher on the cluster recorded 9 Workloads owned by SparkApplications, all admitted to ClusterQueueother.Related PRs
🤖 Generated with Claude Code