Skip to content

Github Importer: Add Cache to Pull Request Reviews importer

What does this MR do?

Github Importer: Add Cache to Pull Request Reviews importer

Github importer have a mechanism to re-schedule an Importer job if it gets throttled. But, repositories with large number of pull requests, were in a throttling loop for the Pull Request Reviews Importer.

In other words, when re-scheduled, the job was re-starting importing reviews to all imported Pull Requests, regardless if already imported or not, causing another throttling.

To fix this, already imported Pull Requests ids are being cached and skipped, this way, when the job re-start, we don't do requests related to already imported Pull Requests.

The same is applied to the Pull Request MergedBy importer.

Related to: #329552 (closed)

Screenshots (strongly suggested)

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:

  • Label as security and @ mention @gitlab-com/gl-security/appsec
  • The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • Security reports checked/validated by a reviewer from the AppSec team
Edited by Kassio Borges

Merge request reports