Skip to content

Update issues in ES when project visibility settings change

What does this MR do?

Related to #273234 (closed)

This change will add hooks to update issue data in the Elasticsearch index issues_access_level (on the associated project's project_feature) changes are made. The assumption being that issues_access_level will change if required when the project visibility level is modified.

These changes are handled in a new worker ElasticAssociationIndexerWorker. Doing the work in a worker will ensure that projects with a large amount of issues can be processed in batches.

I pulled code from ProcessInitialBookkeepingService back up into the ProcessBookkeepingService so that it can used by the ProcessInitialBookkeepingService and ElasticAssociationIndexerWorker to maintain the project's associated data in Elasticsearch.

Note: Although the MRs which add the permissions data to the issue documents are not merged, this MR can be merged prior without impacting that work. This will result in more update requests issued to Elasticsearch when project permission settings are changed (but that will be happening anyways as a part of splitting issues documents to a new index)

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 Terri Chu

Merge request reports