WIP: New CI Job live-trace architecture (CE)
What does this MR do?
- This is implemented on top of this proposal.
- This is implemented as minimal as possible.
-
Gitlab::Ci::Trace::ChunkedFile::ChunkedIOis an abstract layer for manipulating chunked files. It's compatible with ruby'sIOclass. -
Gitlab::Ci::Trace::ChunkedFile::ChunkedIO::LiveTraceis for manipulating live-trace concerned operations. It usesChunkStore::RedisandChunkStore::Databasefor storing pieces of traces which sent from gitlab-runners. -
Gitlab::Ci::Trace::ChunkedFile::ChunkStoreis for storing chunks -
Gitlab::Ci::Trace::ChunkedFile::ChunkStore::Redisis for writing/appending piece of chunks -
Gitlab::Ci::Trace::ChunkedFile::ChunkStore::Databaseis for stashing complete chunks fromChunkStore::Redis - The buffer size of each store is 128 kb.
- This is to be deployed to staging server and check the impact to the system.
- This is easy to extend for another solution, for example, Redis+ObjectStorage combo.
TODOs
-
Each write/archive operation should be wrapped by Sidekiq for scaling horizontally
Are there points in the code the reviewer needs to double check?
- Is there any performance regressions?
- What if Redis is not responded?
- What if Postgres is not responded?
- Can we archive the complete trace without data loss?
Why was this MR needed?
This is necessary for ~"Cloud Native" compatible gitlab.
Screenshots (if relevant)
Does this MR meet the acceptance criteria?
-
Changelog entry added, if necessary -
Tests added for this feature/bug - Review
-
Has been reviewed by Backend -
Has been reviewed by Database
-
-
End-to-end tests pass ( package-qamanual pipeline job)
What are the relevant issue numbers?
Edited by Shinya Maeda