Fix batch loader for CI project includes
What does this MR do and why?
We should not use a global changeable method inside a batch-loader block.
The mistake was to use project
inside can_access_local_content?
and sha
. So, it was "cached" for other includes.
In this MR, we are using "project" as the for
parameter of batch-loaders. One downside of this is that we still have N+1 queries
for projects.
In this MR, we are also changing the tests to cover this case. Including a new E2E test.
These changes are behind the FF ci_batch_project_includes_context
(#392746 (closed)).
Related to #382751 (closed) #395699 (closed) #395369 (closed)
Introduced in: !112570 (merged)
Screenshots or screen recordings
The reproduction steps are in the tests.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.