Skip to content

kueue: Add Kueue ClusterQueue views#864

Open
Utkarshpandey0001 wants to merge 1 commit into
headlamp-k8s:mainfrom
Utkarshpandey0001:kueue-clusterqueue-support
Open

kueue: Add Kueue ClusterQueue views#864
Utkarshpandey0001 wants to merge 1 commit into
headlamp-k8s:mainfrom
Utkarshpandey0001:kueue-clusterqueue-support

Conversation

@Utkarshpandey0001

Copy link
Copy Markdown
Contributor

Summary

Adds support for Kueue ClusterQueue resources in the Headlamp Kueue plugin.

Changes

  • Adds a typed ClusterQueue resource model for kueue.x-k8s.io/v1beta2
  • Adds ClusterQueue list and detail pages
  • Registers ClusterQueue sidebar entry and routes
  • Displays resource groups, referenced ResourceFlavors, workload counts, conditions, preemption, admission checks, and fair sharing details
  • Adds formatter tests and a sample ClusterQueue manifest
  • Updates the Kueue README with ClusterQueue usage notes

Testing

cd kueue
npm run tsc
npm run lint
node_modules/.bin/vitest run -c node_modules/@kinvolk/headlamp-plugin/config/vite.config.mjs
npm run build

Signed-off-by: Utkarshpandey0001 <rajutkarshpandey2003@gmail.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds ClusterQueue support to the Headlamp Kueue plugin, expanding the plugin beyond ResourceFlavor to include ClusterQueue list/detail navigation and typed modeling for kueue.x-k8s.io/v1beta2.

Changes:

  • Introduces a typed ClusterQueue resource model plus formatter utilities for rendering key spec/status fields.
  • Adds ClusterQueue list/detail pages and wires them into routes + sidebar navigation.
  • Updates tests, sample manifests, and README usage instructions for the new resource.

Reviewed changes

Copilot reviewed 10 out of 10 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
kueue/test-files/deploy/clusterqueue-team-a.yaml Adds a sample ClusterQueue manifest for local testing/demo.
kueue/src/utils/kueueRoutes.ts Adds ClusterQueue list/detail route names and paths.
kueue/src/utils/kueueApi.test.ts Extends route-path tests to cover ClusterQueue routes.
kueue/src/resources/clusterQueueFormatters.ts Adds formatter helpers for displaying ClusterQueue spec/status data.
kueue/src/resources/clusterQueue.ts Adds the typed ClusterQueue model (spec/status interfaces + computed display getters).
kueue/src/resources/clusterQueue.test.ts Adds basic formatter unit tests for ClusterQueue formatting helpers.
kueue/src/index.tsx Registers ClusterQueue sidebar entry and routes; makes ClusterQueues the default Kueue landing page.
kueue/src/components/clusterqueues/List.tsx Adds ClusterQueue list view with key columns (cohort, quotas, workload counts, status).
kueue/src/components/clusterqueues/Detail.tsx Adds ClusterQueue detail view showing formatted spec/status fields.
kueue/README.md Updates documentation to reflect ClusterQueue support and example usage.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +125 to +128
export function renderLabelSelector(selector?: LabelSelectorLike) {
if (!selector) {
return '-';
}
},
{
name: 'Conditions',
value: clusterQueue.conditionsDisplay,

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you check how Headlamp displays conditions for workloads?

There can be many conditions and I worry the UX on this would be subpar.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let me look into it once. I will get back to you in a while

- coveredResources:
- cpu
- memory
flavors:

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Displaying the flavors does not look good.

Image

As we add more flavors or resourceGroups I worry this would become difficult to parse.

@illume curious on how we should render these arrays?

@Utkarshpandey0001 Utkarshpandey0001 Jun 29, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm... can we go with a separate section that will show resource flavour. Let me do some hit and trial then i will back to you

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The status fields are also important to call out as an array.

Resource Groups, Reservations, Usage.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cc @amy

@amy

amy commented Jun 29, 2026

Copy link
Copy Markdown

Is there a way for you to render example screenshots via the PR build process? I'm having trouble figuring out how to get a local view of this.

@Utkarshpandey0001

Copy link
Copy Markdown
Contributor Author

hi @amy , i am attaching screenshots of it. Give me a moment

? [
{
name: 'Cohort',
value: clusterQueue.cohortName,

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@amy brought this up to me.

Cohorts can be a string and a reference to a Cohort object. if they are a reference to a Cohort we should have a click to take to the cohort resource.

This doesn't have to be solved here but wanted to bring it up when you take on Cohorts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants