Skip to content

Refactoring audit events for project deletion

Hitesh Raghuvanshi requested to merge 374105-refactor-project-audit-3 into master

What does this MR do and why?

Refactors project services to use Gitlab::Audit::Auditor for creating audit events.

  • Adds new audit event types under ee/config/audit_events/types.
  • Adds default options for audit context author + target

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

  1. Setup external audit event streaming destination for a group by following steps here. Please note the group must have at least Ultimate licence.
  2. All the audit events related to group will be sent to the endpoint added above.
  3. Perform following actions for the projects of the group and check the respective audit events on the remote destination is the event_type is coming for each one or not:
    1. Mark a project for deletion.
    2. Delete a project.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #374105 (closed)

Edited by Hitesh Raghuvanshi

Merge request reports