This project is archived. Its data is read-only.
Refactor `_artifactcache` folder
## Background [//]: # (Provide a background or the root/source that justifies this task or action.) As it stands, the `_artifactcache` folder contains all the CAS logic, but #440 proposes using a remote `SourceCache` that is CAS based. The `CASCache` class implements a lot of the remote logic, with `CASRemote` being more of a data structure containing GRPC stubs and such. I propose to refactor the `_artifactcache` folder making it a `_cas` folder, moving `ArtifactCache` into a buildstream root module, and separating out remote and local CAS logic. This will make it easier to add the `SourceCache`, reusing the remote logic while writing out in a separate format. ## Task description [//]: # (Short summary of the action to be executed) * [ ] Rename the `_artifactcache` folder to `_cas` and move `artifactcache.py` to `_artifactcache.py` in the buildstream root, changing relevant imports. * [ ] Move `CASRemote` into it's own file and change relevant imports. * [ ] Move remote logic from `CASCache` into `CASRemote`, updating `ArtifactCache` to work with new changes. ## Acceptance Criteria [//]: # (Acceptance criteria should follow the S.M.A.R.T. principle https://en.wikipedia.org/wiki/SMART_criteria ) Behavior should remain exactly the same with refactored `_cas` folder. ---- This when done will allow work to start on #440
issue