Skip to content

Remove subtransaction in Security::ProcessScanResultPolicyWorker

What does this MR do and why?

Addresses #396743 (closed)

This MR removes the usage of safe_find_or_create_by! for SoftwareLicense when it is created through License approval policies as it creates a subtransaction from Security::ProcessScanResultPolicyWorker. We don't need to do it in a transaction as we already have exclusive leave on the worker so there won't be a race condition.

MR acceptance checklist

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

Edited by Sashi Kumar Kumaresan

Merge request reports