[PR #2370] [MERGED] Add batch delete for groups and users #15040

Closed
opened 2026-08-05 03:06:51 -04:00 by saavagebueno · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/netbirdio/netbird/pull/2370
Author: @bcmmbaga
Created: 8/1/2024
Status: Merged
Merged: 8/8/2024
Merged by: @bcmmbaga

Base: mainHead: bulk-delete-users-groups


📝 Commits (8)

  • 18c1be2 Refactor user deletion logic and introduce batch delete
  • 35aa6ca Prevent self-deletion for users
  • d88edf4 Add delete multiple groups
  • 14b21fa Refactor group deletion with validation
  • 0fdc763 Fix tests
  • 14641b4 Add bulk delete functions for Users and Groups in account manager interface and mocks
  • a4fcff6 Add tests for DeleteGroups method in group management
  • d485911 Add tests for DeleteUsers method in users management

📊 Changes

6 files changed (+564 additions, -115 deletions)

View changed files

📝 management/server/account.go (+2 -0)
📝 management/server/group.go (+141 -76)
📝 management/server/group_test.go (+140 -5)
📝 management/server/mock_server/account_mock.go (+18 -0)
📝 management/server/user.go (+112 -34)
📝 management/server/user_test.go (+151 -0)

📄 Description

Describe your changes

Checklist

  • Is it a bug fix
  • Is a typo/documentation fix
  • Is a feature enhancement
  • It is a refactor
  • Created tests that fail without the change (if possible)
  • Extended the README / documentation, if necessary

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/netbirdio/netbird/pull/2370 **Author:** [@bcmmbaga](https://github.com/bcmmbaga) **Created:** 8/1/2024 **Status:** ✅ Merged **Merged:** 8/8/2024 **Merged by:** [@bcmmbaga](https://github.com/bcmmbaga) **Base:** `main` ← **Head:** `bulk-delete-users-groups` --- ### 📝 Commits (8) - [`18c1be2`](https://github.com/netbirdio/netbird/commit/18c1be23af04a7dbee6236e58357985813cddae3) Refactor user deletion logic and introduce batch delete - [`35aa6ca`](https://github.com/netbirdio/netbird/commit/35aa6ca45459e251d2270104bee00e18359cf784) Prevent self-deletion for users - [`d88edf4`](https://github.com/netbirdio/netbird/commit/d88edf438567749c41d6556f54475f32e3cf7190) Add delete multiple groups - [`14b21fa`](https://github.com/netbirdio/netbird/commit/14b21faba4b80d1ad60793ff5a4ea58dabb103b4) Refactor group deletion with validation - [`0fdc763`](https://github.com/netbirdio/netbird/commit/0fdc763a9dd4831328ff372f5be604efc56cec71) Fix tests - [`14641b4`](https://github.com/netbirdio/netbird/commit/14641b4a758fd02cd2020ccbc2be32aacaf46e17) Add bulk delete functions for Users and Groups in account manager interface and mocks - [`a4fcff6`](https://github.com/netbirdio/netbird/commit/a4fcff6f3ffb68d0b1dbbc9b9b20599646c5a425) Add tests for DeleteGroups method in group management - [`d485911`](https://github.com/netbirdio/netbird/commit/d4859117e5cd78ec0c0c29a609e2b423b36154f6) Add tests for DeleteUsers method in users management ### 📊 Changes **6 files changed** (+564 additions, -115 deletions) <details> <summary>View changed files</summary> 📝 `management/server/account.go` (+2 -0) 📝 `management/server/group.go` (+141 -76) 📝 `management/server/group_test.go` (+140 -5) 📝 `management/server/mock_server/account_mock.go` (+18 -0) 📝 `management/server/user.go` (+112 -34) 📝 `management/server/user_test.go` (+151 -0) </details> ### 📄 Description ## Describe your changes ## Issue ticket number and link ### Checklist - [ ] Is it a bug fix - [ ] Is a typo/documentation fix - [x] Is a feature enhancement - [ ] It is a refactor - [ ] Created tests that fail without the change (if possible) - [ ] Extended the README / documentation, if necessary --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
saavagebueno added the pull-request label 2026-08-05 03:06:51 -04:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: DYNR/netbird#15040