WIP: Add support for CI build annotations
What does this MR do?
This adds support for CI build annotations, as described in https://gitlab.com/gitlab-org/gitlab-ce/issues/51641. A more in-depth description will be added once the changes mature.
What are the relevant issue numbers?
https://gitlab.com/gitlab-org/gitlab-ce/issues/51641
TODO
-
Add mechanism for caching rendered Markdown in Redis. - This should be implemented in such a way that N+1 requests are not possible. This would be done using Redis pipelining, and raising errors if the data is not eager loaded (= N+1 is impossible).
- This somehow should reuse some of the important logic from the
CacheMarkdownField
concern. This may just require some copy-pasting for the time being. We also don't need to support multiple Markdown engines.
-
Create Sidekiq worker for processing the reports -
Schedule Sidekiq worker when the build state transitions to a finished state, like security reports do for pipelines -
Create service that takes a CI build, and parses it into a database row -
Ensure that we only process artifacts below 10MB in size
-
-
Implement basic UI, which initially would just be a separate "Annotations" tab in an MR -
Tests for the Sidekiq worker
Does this MR meet the acceptance criteria?
-
Changelog entry added, if necessary -
Documentation created/updated via this MR -
Documentation reviewed by technical writer or follow-up review issue created -
Tests added for this feature/bug -
Tested in all supported browsers -
Conforms to the code review guidelines -
Conforms to the merge request performance guidelines -
Conforms to the style guides -
Conforms to the database guides -
Link to e2e tests MR added if this MR has Requires e2e tests label. See the Test Planning Process. -
Security reports checked/validated by reviewer
Edited by Yorick Peterse