Show list of stream audit event types in UI
What does this MR do and why?
Relates to #413581 (closed)
This MR displays available audit event types coming from backend (HAML injected) in a GlCollapsibleListbox in the event filtering section of a streaming destination.
Before, each event type had to be created via the API and could only be unchecked via the UI later.
Some notes:
- The list of events is quite long, in next iterations, the listbox will handle grouping by category and searching.
- The event types don't have any label supplied, so it was decided that we would use sentence case;
"add_gpg_key"
becomes"Add gpg key"
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
Before | After |
---|---|
![]() |
![]() |
How to set up and validate locally
Make sure you have an EE license
- Go to any group
- Go to "Secure" > "Audit events"
- Click "Streams" tab
- Create a new streaming destination by clicking "Add streaming destination"
- Provide a "Destination URL"
- Validate you see the "Filter by stream event" accordion and click it
- Validate you see a dropdown with a placeholder "Select events", click it
- Validate you can see a long list of event types and these are selectable
- Validate that if you select some it updates the text of the dropdown button with a comma-separated list of the event type names
- Validate that clicking "Unselect all", actually unselects all event types
- Validate that clicking "Select all" selects all event types (button is only shown if no event types are selected)
- Select some event types and click "Add"
- Validate that the editor is closed and a new streaming destination is added
- Validate that if you edit that new destination and go to event type dropdown the same events are selected from before.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Merge request reports
Activity
changed milestone to %16.1
assigned to @lorenzvanherwaarden
added backend label
3 Warnings This merge request is quite big (647 lines changed), please consider splitting it into multiple merge requests. a84839a3: Commits that change 30 or more lines across at least 3 files should describe these changes in the commit body. For more information, take a look at our Commit message guidelines. This merge request changed files with disabled eslint rules. Please consider fixing them. 1 Message This merge request adds or changes documentation files. A review from the Technical Writing team before you merge is recommended. Reviews can happen after you merge. Documentation review
The following files require a review from a technical writer:
-
doc/administration/audit_event_streaming.md
(Link to current live version)
The review does not need to block merging this merge request. See the:
-
Metadata for the
*.md
files that you've changed. The first few lines of each*.md
file identify the stage and group most closely associated with your docs change. - The Technical Writer assigned for that stage and group.
- Documentation workflows for information on when to assign a merge request for review.
Disabled eslint rules
The following files have disabled
eslint
rules. Please consider fixing them:ee/app/assets/javascripts/audit_events/constants.js
Run the following command for more details
node_modules/.bin/eslint --report-unused-disable-directives --no-inline-config \ 'ee/app/assets/javascripts/audit_events/constants.js'
Reviewer roulette
Changes that require review have been detected!
Please refer to the table below for assigning reviewers and maintainers suggested by Danger in the specified category:
Category Reviewer Maintainer backend Tarun Vellishetty (
@tvellishetty
) (UTC+5.5, 3.5 hours ahead of@lorenzvanherwaarden
)Peter Leitzen (
@splattael
) (UTC+2, same timezone as@lorenzvanherwaarden
)frontend Tomas Vik (
@viktomas
) (UTC+2, same timezone as@lorenzvanherwaarden
)Coung Ngo (
@cngo
) (UTC+1, 1 hour behind@lorenzvanherwaarden
)UX Libor Vanc (
@lvanc
) (UTC-10, 12 hours behind@lorenzvanherwaarden
)Maintainer review is optional for UX groupcompliance Reviewer review is optional for groupcompliance Aaron Huntsman (
@ahuntsman
) (UTC-5, 7 hours behind@lorenzvanherwaarden
)To spread load more evenly across eligible reviewers, Danger has picked a candidate for each review slot, based on their timezone. Feel free to override these selections if you think someone else would be better-suited or use the GitLab Review Workload Dashboard to find other available reviewers.
To read more on how to use the reviewer roulette, please take a look at the Engineering workflow and code review guidelines. Please consider assigning a reviewer or maintainer who is a domain expert in the area of the merge request.
Once you've decided who will review this merge request, assign them as a reviewer! Danger does not automatically notify them for you.
If needed, you can retry the
danger-review
job that generated this comment.Generated by
Danger-
Bundle size analysis [beta]
This compares changes in bundle size for entry points between the commits 1c141f6e and dbc33b3d
Special assetsEntrypoint / Name Size before Size after Diff Diff in percent average 4.12 MB 4.12 MB - 0.0 % mainChunk 3 MB 3 MB - 0.0 % Significant Growth: 3Expand
Entrypoint / Name Size before Size after Diff Diff in percent pages.admin.audit_logs 851.78 KB 879.71 KB +27.93 KB 3.3 % pages.groups.audit_events 862.17 KB 890.1 KB +27.93 KB 3.2 % pages.projects.audit_events 934.5 KB 962.43 KB +27.93 KB 3.0 %
Your MR has at least one entrypoint growing significantly (more > 1 KB or 2%). If you write new or extend existing features, this is expected and there is nothing to worry about.
Please consider pinging someone from the FE Foundations (
@leipert
,@markrian
,@ohoral
or@pgascouvaillancourt
) for review, if you are unsure about the size increase.Note: We do not have exact data for 1c141f6e. So we have used data from: 50662b89.
The intended commit has no webpack pipeline, so we chose the last commit with one before it.Please look at the full report for more details
Read more about how this report works.
Generated by
DangerAllure report
allure-report-publisher
generated test report!e2e-test-on-gdk:
test report for dbc33b3dexpand test summary
+-----------------------------------------------------------------------+ | suites summary | +------------------+--------+--------+---------+-------+-------+--------+ | | passed | failed | skipped | flaky | total | result | +------------------+--------+--------+---------+-------+-------+--------+ | Data Stores | 2 | 0 | 0 | 1 | 2 | ❗ | | Govern | 2 | 0 | 0 | 0 | 2 | ✅ | | Framework sanity | 0 | 0 | 1 | 0 | 1 | ➖ | | Create | 8 | 0 | 1 | 0 | 9 | ✅ | | Plan | 4 | 0 | 0 | 0 | 4 | ✅ | | Manage | 1 | 0 | 0 | 0 | 1 | ✅ | | Monitor | 4 | 0 | 0 | 0 | 4 | ✅ | +------------------+--------+--------+---------+-------+-------+--------+ | Total | 21 | 0 | 2 | 1 | 23 | ❗ | +------------------+--------+--------+---------+-------+-------+--------+
e2e-review-qa:
test report for dbc33b3dexpand test summary
+-----------------------------------------------------------------------+ | suites summary | +------------------+--------+--------+---------+-------+-------+--------+ | | passed | failed | skipped | flaky | total | result | +------------------+--------+--------+---------+-------+-------+--------+ | Monitor | 4 | 0 | 0 | 0 | 4 | ✅ | | Create | 8 | 0 | 1 | 0 | 9 | ✅ | | Plan | 3 | 0 | 1 | 0 | 4 | ✅ | | Data Stores | 2 | 0 | 0 | 1 | 2 | ❗ | | Framework sanity | 0 | 0 | 1 | 0 | 1 | ➖ | | Govern | 2 | 0 | 0 | 0 | 2 | ✅ | | Manage | 1 | 0 | 0 | 0 | 1 | ✅ | +------------------+--------+--------+---------+-------+-------+--------+ | Total | 20 | 0 | 3 | 1 | 23 | ❗ | +------------------+--------+--------+---------+-------+-------+--------+
e2e-package-and-test:
test report for dbc33b3dexpand test summary
+-----------------------------------------------------------------------+ | suites summary | +------------------+--------+--------+---------+-------+-------+--------+ | | passed | failed | skipped | flaky | total | result | +------------------+--------+--------+---------+-------+-------+--------+ | Create | 687 | 1 | 117 | 5 | 805 | ❌ | | Govern | 245 | 0 | 10 | 5 | 255 | ❗ | | Plan | 390 | 0 | 3 | 0 | 393 | ✅ | | Verify | 250 | 0 | 25 | 0 | 275 | ✅ | | Package | 268 | 0 | 49 | 228 | 317 | ❗ | | Manage | 207 | 18 | 17 | 29 | 242 | ❌ | | Fulfillment | 12 | 0 | 125 | 0 | 137 | ✅ | | Monitor | 52 | 0 | 11 | 0 | 63 | ✅ | | Data Stores | 185 | 0 | 3 | 0 | 188 | ✅ | | Analytics | 11 | 0 | 0 | 0 | 11 | ✅ | | Configure | 1 | 0 | 15 | 0 | 16 | ✅ | | Release | 30 | 0 | 0 | 0 | 30 | ✅ | | Framework sanity | 0 | 0 | 7 | 0 | 7 | ➖ | | Secure | 10 | 0 | 45 | 0 | 55 | ✅ | | Growth | 0 | 0 | 10 | 0 | 10 | ➖ | | Systems | 19 | 0 | 0 | 0 | 19 | ✅ | | GitLab Metrics | 2 | 0 | 1 | 0 | 3 | ✅ | | ModelOps | 0 | 0 | 5 | 0 | 5 | ➖ | +------------------+--------+--------+---------+-------+-------+--------+ | Total | 2369 | 19 | 443 | 267 | 2831 | ❌ | +------------------+--------+--------+---------+-------+-------+--------+
added 1 commit
- 68644877 - Add tests to stream_filters_spec for listbox
added 2 commits
mentioned in merge request !123093 (closed)
- Resolved by Stan Hu
- Resolved by Stan Hu
- Resolved by Stan Hu
- Resolved by Stan Hu
removed workflowin dev label
marked the checklist item I have evaluated the MR acceptance checklist for this MR. as completed
- Resolved by Stan Hu
@sming-gitlab can you do the initial frontend review?
Thanks
requested review from @sming-gitlab
- Resolved by Evan Read
@eread could you review the documentation update?
Edited by Lorenz van Herwaarden
requested review from @eread
- Resolved by Stan Hu
@wandering_person Could you do the initial backend review? I cherry-picked this from @nrosandich.
requested review from @wandering_person
- Resolved by Lorenz van Herwaarden
requested review from @cam.x
- Resolved by Lorenz van Herwaarden
@hraghuvanshi it seems this MR need a groupcompliance review too. Can you help with this?
requested review from @hraghuvanshi
- Resolved by Lorenz van Herwaarden
added Technical Writing docsfeature labels
removed review request for @eread
- Resolved by Lorenz van Herwaarden
- Resolved by Lorenz van Herwaarden
- Resolved by Lorenz van Herwaarden
removed review request for @sming-gitlab
@sming-gitlab
, thanks for approving this merge request.This is the first time the merge request is approved. To ensure full test coverage, a new pipeline will be started shortly.
For more info, please refer to the following links:
added pipeline:mr-approved label
removed review request for @hraghuvanshi
added 202 commits
-
95cd0286...5d1bf198 - 198 commits from branch
master
- 5866bd36 - Show fixed list of audit events in listbox
- fe0ac43b - Inject audit event definitions to page
- 8a229893 - Use GlCollapsibleListbox instead of GlFormCheckboxTree
- 7fe4748d - Update audit event streaming documentation
Toggle commit list-
95cd0286...5d1bf198 - 198 commits from branch