[Design Management] Remove requirement for Git LFS
This issue was created from a discussion #212570 (comment 313875193).
Problem
Design Management has a requirement that the project has Git LFS enabled. Git LFS is used to store large files externally from the repository. This reduces the size of the repository. With Git LFS enabled, depending on the instance's configuration design files are either stored locally on disk, or in a cloud service. The file that is committed to the Git repository is a very small LFS Pointer file that allows the server to fetch the actual design file from its actual storage.
We're discovering that this requirement for Git LFS is a hurdle for adoption. It adds an extra step to enabling using Design Management.
Proposal
Drop the requirement for Design Management that a project has Git LFS enabled.
users on the right tier, as the remaining requirement would be the license everyone (as Design Management is moving to FOSS).
Considerations
We'd need to adjust a couple of places in our backend services:
-
SaveDesignsService
UsesBlob
s to determine if the design file has changed since the last upload. It is currently written with the assumption that we can fetch a lot of GitBlob
s because theBlob#data
is very small in size due to being LFS Pointer files. IfBlob#data
were to sometimes be the full design file, we may need to consider how to determine if the file hasn't changed without loading the data of the design file - possibly we would want to migrate into theAction
model a hash of the file in order to check without fetching the full design files (perhaps the same as what is generated for an LFS pointer inGitlab::Git::LfsPointerFile#sha256
). -
GenerateImageVersionsService
Assumes that all files can be found throughLfsObjectUploader
and therefore beCarrierwave::SanitizedFile
s. This class would need to be adjusted to work with files that are not backed byLfsObjectUploader
.
Note that SaveDesignsService
and our controllers already can work with non-LFS files.
Related issues
This page may contain information related to upcoming products, features and functionality. It is important to note that the information presented is for informational purposes only, so please do not rely on the information for purchasing or planning purposes. Just like with all projects, the items mentioned on the page are subject to change or delay, and the development, release, and timing of any products, features, or functionality remain at the sole discretion of GitLab Inc.