Draft: potential fix issue for 455711: persist event_name on the Audit Event model
-
Please check this box if this contribution uses AI-generated content as outlined in the GitLab DCO & CLA
What does this MR do and why?
This is a more complicated fix for #455711 (closed): we add event_name
to the Audit Event model, and make sure we return it at the top level of the HTTP API. This would require running a migration on Audit Event, which might be complicated, as per this issue. (This code is also 100% based off of Sam Figueroa's comments in that issue, thx Sam!)
This may require updating various libs to make sure that event_name
is included. I'm also not sure how this will interact with the parallel_persist
code in audit_event.rb.
If GitLab folks are happy with this approach, I can dig into updating tests and find what libraries need to be updated!
Update 4 files
- /app/models/audit_event.rb
- /app/services/audit_events/build_service.rb
- /ee/lib/ee/api/entities/audit_event.rb
- /lib/gitlab/audit/auditor.rb
Edited by Thor Kell