[OpenNMS/opennms] 06d744: NMS-20107: versioned group management API and Prim...
joseanesONMS via opennms-cvs <[email protected]> Thu, 30 Jul 2026 13:47:39 -0700
| Newsgroups | gmane.network.opennms.cvs |
|---|---|
| Message-ID | <OpenNMS/opennms/push/refs/heads/jira/NMS-20107-manage-groups-primevue/[email protected]> |
Branch: refs/heads/jira/NMS-20107-manage-groups-primevue
Home: https://github.com/OpenNMS/opennms
Commit: 06d7448dd82d89cdec0fd7b547b3c3c3830cf14e
https://github.com/OpenNMS/opennms/commit/06d7448dd82d89cdec0fd7b547b3c3c3830cf14e
Author: Jose Anes <[email protected]>
Date: 2026-07-30 (Thu, 30 Jul 2026)
Changed paths:
A opennms-webapp-rest/src/main/java/org/opennms/web/rest/v2/GroupsRestService.java
A opennms-webapp-rest/src/main/java/org/opennms/web/rest/v2/api/GroupsRestApi.java
A opennms-webapp-rest/src/main/java/org/opennms/web/rest/v2/model/GroupDto.java
A opennms-webapp-rest/src/main/java/org/opennms/web/rest/v2/model/GroupRenameRequest.java
M opennms-webapp-rest/src/main/webapp/WEB-INF/menu/menu-template.json
A opennms-webapp-rest/src/test/java/org/opennms/web/rest/v2/GroupsRestServiceIT.java
M opennms-webapp/src/main/webapp/WEB-INF/applicationContext-spring-security.xml
A ui/src/components/ManageGroups/GroupEditorDialog.vue
A ui/src/components/ManageGroups/GroupRenameDialog.vue
A ui/src/components/ManageGroups/GroupsTable.vue
A ui/src/containers/ManageGroups.vue
M ui/src/main/router/index.ts
A ui/src/services/groupAdminService.ts
M ui/src/services/index.ts
A ui/src/stores/groupAdminStore.ts
A ui/src/types/groupAdmin.ts
A ui/tests/stores/groupAdminStore.test.ts
Log Message:
-----------
NMS-20107: versioned group management API and PrimeVue Manage Groups page
Adds /api/v2/groups (list/get/create/update, rename, delete), admin-only
via Spring Security rules plus in-code checks, wrapping GroupManager so
groups.xml stays the system of record. The member list order is
preserved end to end — it drives the notification escalation order —
and fields the API does not expose (default-map) survive updates.
Requests are validated up front (name and comment markup, members must
exist, duty schedule grammar with overnight ranges legal) and applied to
a detached copy, so rejected requests leave no partial state. Unlike the
legacy page, which only hid the buttons, the Admin group is protected
server-side, renames follow the on-call roles' membership-group
references, and deletes are rejected while roles still reference the
group instead of leaving dangling references.
The Manage Groups page (ui/#/admin/groups) visualizes the API: groups
table, editor with an ordered member list (move up/down), rename and
delete dialogs with the system group disabled. The menu entry now points
at the new page. 13 integration tests and 8 store tests.
Commit: 9c2503ccf0e1f0abbd2b47a991cefcfebb33327c
https://github.com/OpenNMS/opennms/commit/9c2503ccf0e1f0abbd2b47a991cefcfebb33327c
Author: Jose Anes <[email protected]>
Date: 2026-07-30 (Thu, 30 Jul 2026)
Changed paths:
M opennms-webapp-rest/src/main/java/org/opennms/web/rest/v2/GroupsRestService.java
M opennms-webapp-rest/src/test/java/org/opennms/web/rest/v2/GroupsRestServiceIT.java
M ui/src/components/ManageGroups/GroupEditorDialog.vue
A ui/src/components/ManageGroups/GroupsHelpPanel.vue
M ui/src/containers/ManageGroups.vue
Log Message:
-----------
NMS-20107: review fixes, category handling, and in-context help
Fixes from self-review. Duty schedules with begin after end are rejected
for new entries — DutySchedule.isInSchedule compares within one calendar
day, so an overnight range never matches and would silently take the
group off duty; strings already stored on the record keep round-tripping
so hand-edited files never make a group uneditable. Delete and rename go
through GroupService so the DB category authorizations are cleared and
migrated as the legacy page did (deleting a group otherwise leaked its
authorizations to a future group reusing the name). Renames re-point the
on-call roles in memory first, so the rename's single save persists
groups and roles together, with the role changes reverted on failure.
Both v2 services now serialize on a shared monitor because user
mutations cascade into GroupManager. Dot-segment names are rejected, and
clearing the comments field works (an explicit empty string clears; an
omitted key still preserves).
Adds a collapsed "?" help panel explaining what groups are for and how
to use the page, including the escalation-order and rename semantics.
Commit: 36d60b46916dce54c9e4740287cb81bd6a97a285
https://github.com/OpenNMS/opennms/commit/36d60b46916dce54c9e4740287cb81bd6a97a285
Author: Jose Anes <[email protected]>
Date: 2026-07-30 (Thu, 30 Jul 2026)
Changed paths:
M ui/src/components/ManageGroups/GroupEditorDialog.vue
M ui/src/components/ManageGroups/GroupRenameDialog.vue
M ui/src/components/ManageGroups/GroupsTable.vue
A ui/src/lib/adminValidation.ts
M ui/src/services/groupAdminService.ts
M ui/src/stores/groupAdminStore.ts
A ui/tests/components/AdminDialogs/GroupEditorDialog.test.ts
A ui/tests/lib/adminValidation.test.ts
M ui/tests/stores/groupAdminStore.test.ts
Log Message:
-----------
NMS-20107: validate group fields inline and surface API errors in the dialogs
Same treatment as the users page: group mutations return the server's error
message and the editor/rename dialogs show it inline instead of relying on a
toast hidden behind the modal; the group name and comments fields get live
client-side checks mirroring the server rules, and groups with names the
security filter cannot address in a URL path show a file-managed note in
place of row actions.
Commit: 5cf1dc9dfc9e0cbfecbf2c94f977d40013d93085
https://github.com/OpenNMS/opennms/commit/5cf1dc9dfc9e0cbfecbf2c94f977d40013d93085
Author: Jose Anes <[email protected]>
Date: 2026-07-30 (Thu, 30 Jul 2026)
Changed paths:
M opennms-webapp-rest/src/main/java/org/opennms/web/rest/v2/GroupsRestService.java
M opennms-webapp-rest/src/test/java/org/opennms/web/rest/v2/GroupsRestServiceIT.java
Log Message:
-----------
NMS-20107: grandfather stale group members on update
A hand-edited groups.xml can reference a user that no longer exists; since
the editor always sends the full member list, the unknown-user check made
such groups uneditable. Members already stored on the group now skip the
existence check, matching the duty-schedule and on-call-schedule handling;
members new to a request must still resolve to a real user.
Commit: 64a64393527df8a64b81e12eb46fad5c73fc1fe4
https://github.com/OpenNMS/opennms/commit/64a64393527df8a64b81e12eb46fad5c73fc1fe4
Author: Jose Anes <[email protected]>
Date: 2026-07-30 (Thu, 30 Jul 2026)
Changed paths:
M opennms-webapp-rest/src/main/java/org/opennms/web/rest/v2/GroupsRestService.java
M opennms-webapp-rest/src/test/java/org/opennms/web/rest/v2/GroupsRestServiceIT.java
M ui/src/components/ManageGroups/GroupEditorDialog.vue
M ui/src/lib/adminValidation.ts
M ui/tests/components/AdminDialogs/GroupEditorDialog.test.ts
M ui/tests/lib/adminValidation.test.ts
Log Message:
-----------
NMS-20107: close review findings on the groups API and editor
The name and comments regexes now scan for forbidden characters instead of
full-string matches a newline could bypass. Hand-edited comments containing
markup characters are grandfathered while unchanged — server-side and in
the editor — so such groups stay editable; changed comments are still
validated. The rename rollback no longer re-points on-call roles in memory
when the rename already persisted to groups.xml (only the DB category
migration failed), which would have diverged memory from the file; that
case now reports the partial failure explicitly.
Compare: https://github.com/OpenNMS/opennms/compare/06d7448dd82d%5E...64a64393527d
To unsubscribe from these emails, change your notification settings at https://github.com/OpenNMS/opennms/settings/notifications
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/wiki/index.php?page=MailingListFaq
opennms-cvs mailing list
To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-cvs