Skip to content

Move resource management to dedicated Manage Jenkins subpage and modernize UI#1035

Open
adityajalkhare wants to merge 8 commits into
jenkinsci:masterfrom
adityajalkhare:feature/ui-redesign
Open

Move resource management to dedicated Manage Jenkins subpage and modernize UI#1035
adityajalkhare wants to merge 8 commits into
jenkinsci:masterfrom
adityajalkhare:feature/ui-redesign

Conversation

@adityajalkhare
Copy link
Copy Markdown

@adityajalkhare adityajalkhare commented May 16, 2026

What changed

Lockable Resources now has its own page under Manage Jenkins, replacing
the old Global Configuration form for resource management. The UI is rebuilt
using native Jenkins components, dropping the data-tables-api dependency.

For users

Before: Resources were added/edited in Manage Jenkins > System inside a
long repeatable form mixed with other system settings. The overview page at
/lockable-resources/ used DataTables and Bootstrap, which broke under
Jenkins experimental UI flags.

After:

  • Dedicated management page - Go to Manage Jenkins > Lockable Resources
    (under the Configuration category). All resource operations live here now.
  • Add, edit, and delete resources directly from the overview page using
    the "Add Resource" button and per-row edit/delete actions. No need to visit
    Global Configuration to manage resources.
  • Filtering - Click the filter icon in the top bar. On the Resources tab,
    filter by name, label, or status (free/reserved/locked/queued). On Labels
    and Queue tabs, use text search.
  • Pagination - Tables show 10/25/50/100/All rows with your preference
    saved in the browser.
  • Works with all UI flags - Compatible with new-dashboard-page,
    new-build-page, new-job-page, and new-manage-jenkins experimental flags.
  • Global Configuration still shows the two system-wide behavior toggles
    (Allow empty or null values and Allow ephemeral resources) with a link
    to the new management page.
  • Bookmarks still work - The old URL /lockable-resources/ continues to
    serve the page (now at /manage/lockable-resources/).

Screenshots/Demo

New Experimental UI -

Screen.Recording.2026-05-19.at.11.49.57.PM.mov

Existing Stable UI -

Screen.Recording.2026-05-19.at.11.52.20.PM.mov

Fixes

Changes by area

Backend (LockableResourcesRootAction.java)

  • Changed from RootAction to ManagementLink under Category.CONFIGURATION
  • Added doCreateResource (form + JSON), doEditResource (JSON),
    doDeleteResource endpoints with proper HTTP status codes
  • Resource properties (key-value pairs) supported in create/edit

Frontend

  • Removed data-tables-api dependency from pom.xml
  • Replaced DataTables with native jenkins-table sortable
  • Capsule-style tab bar (Resources / Labels / Queue)
  • Client-side pagination with localStorage persistence
  • Filter/search popover adapting per tab
  • Add/Edit/Delete dialogs using Jenkins dialog.modal and dialog.confirm
  • Resource properties shown as pills, editable via dynamic rows
  • Single event delegation listener for all button handlers

Global Config (config.jelly)

  • Removed the resource repeatable form
  • Kept only the two behavior checkboxes
  • Added notice linking to the new management page

Tests

  • ManagementLinkTest (7 tests): registration, category, URL, icon,
    permissions
  • ResourceManagementTest (21 tests): CRUD, duplicate/404/423 handling,
    JSON API, permission checks, page structure

Testing

  • 28 new tests covering all new endpoints and page structure
  • All existing tests pass (412 total)
  • Manually verified with all experimental flags enabled:
    new-build-page, new-dashboard-page, new-job-page,
    new-manage-jenkins

Checklist

  • Automated tests added or existing tests cover the change
  • PR title is a clear, imperative-mood changelog entry
  • Breaking changes or upgrade steps are documented below

Upgrade guidelines

N/A

Aditya Jalkhare added 2 commits May 17, 2026 03:36
…rnize UI

Fixes jenkinsci#1021, fixes jenkinsci#964, fixes jenkinsci#1018

- Convert LockableResourcesRootAction from RootAction to ManagementLink
  under Manage Jenkins > Configuration category
- Use settings-subpage layout with Jenkins-native app-bar and tabs
- Remove data-tables-api dependency; use native jenkins-table sortable
- Add client-side pagination with localStorage persistence
- Add resource CRUD (create, edit, delete) via JSON API endpoints
- Add filter/search: structured filter for resources tab (name, label,
  status), text search for labels and queue tabs
- Add resource property management (key-value pairs) in add/edit dialogs
- Simplify Global Config page to only retain the two behavior toggles
  (allowEmptyOrNullValues, allowEphemeralResources) with a notice
  linking to the new management page
- Replace Bootstrap tab markup with capsule-style tab bar matching
  Jenkins Dashboard design
- Use event delegation for all button handlers
- Add ManagementLinkTest and ResourceManagementTest (28 tests)
@adityajalkhare adityajalkhare marked this pull request as ready for review May 16, 2026 22:31
@adityajalkhare adityajalkhare requested a review from a team as a code owner May 16, 2026 22:31
@adityajalkhare adityajalkhare marked this pull request as draft May 16, 2026 22:43
@adityajalkhare adityajalkhare marked this pull request as ready for review May 16, 2026 22:43
@adityajalkhare adityajalkhare marked this pull request as draft May 16, 2026 22:50
@adityajalkhare adityajalkhare marked this pull request as ready for review May 16, 2026 22:50
@adityajalkhare
Copy link
Copy Markdown
Author

The test that failed, LockStepWithRestartTest.lockOrderRestart, seems to me it's a known flaky test.

@adityajalkhare adityajalkhare marked this pull request as draft May 17, 2026 16:38
@adityajalkhare adityajalkhare marked this pull request as ready for review May 17, 2026 16:38
@adityajalkhare
Copy link
Copy Markdown
Author

@mPokornyETM @MarkEWaite please review

@adityajalkhare
Copy link
Copy Markdown
Author

Added video demos

@meeusen
Copy link
Copy Markdown
Contributor

meeusen commented May 20, 2026

I like the new layout, it looks good, and adding/changing resources from within the table is nice.

Some things I noticed:

  • I can only access the lockable resources through the manage Jenkins page, I don't see it in the "menu with the three horizontal lines" anymore? Our regular users would need to use the URL directly?
  • personally, I like the previous search button, that searched for everything in the table, and where the search text is remembered on page reload/reservation (using >100 resources). I'd use it to see resources on my name, and after unreserving one, I'd still see the others on my name. Same for filtering on a resource name and reserving it.
  • there is no possibility to order the resources anymore in the configuration (unless using CasC)?

@adityajalkhare
Copy link
Copy Markdown
Author

@meeusen

there is no possibility to order the resources anymore in the configuration (unless using CasC)?

The old config was done using a repeatable form which allowed drag and drop to reorder resources.

The current config, using table, allows view-only sorting using column headers.

So - as per my understanding, without any hacks or massive workarounds, we cannot reorder the persisted XML using UI.

1. Add back the sidebar entry using `LockableResourcesSidebarLink.java`
2. Add the search along with advanced filters with reload on persist
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.

Move lockable resources configuration to separate section Strange UI situation Redesigned dashboard: Lockable Resources page

2 participants