Make S3 Multipart Upload MaxParts Limit and PartSize Configurable in Workhorse
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
When uploading large files (e.g., >65GB) via GitLab (LFS, CI artifacts, etc.) to S3-compatible storage, uploads fail with the error:
TotalPartsExceeded: exceeded total allowed configured MaxUploadParts (10000)
This occurs because GitLab Workhorse hardcodes two critical values:
- **MaxUploadParts**: A hardcoded limit of
10,000parts (source). - **DefaultUploadPartSize**: Default part size used for multipart calculations (often defaulting to 5-15MB).
While S3 allows increasing MaxUploadParts (e.g., to 20,000+), Workhorse’s internal check rejects the upload before it reaches S3, rendering S3-side configurations ineffective.
Impact:
- Breaks large file uploads: Files >~50GB (with default part sizes) cannot be uploaded.
- Scalability issue: Hinders use cases requiring very large files (ML datasets, media assets, backups).
Proposed Solution:
Make both parameters configurable in GitLab:
- **maxUploadParts**: Add a new setting (e.g.,
object_store['multipart_upload_max_parts']) to override the default10,000limit. - **
part_size: Already exists (multipart_upload_part_size), but should be documented prominently** for large uploads.
Why this matters:
- Aligns with S3’s configurable
MaxUploadParts. - Future-proofs GitLab for increasingly common large-data workflows.
- Avoids silent failures where S3 settings appear sufficient but are bypassed by Workhorse.
Steps to Reproduce:
- Configure GitLab with S3 storage.
- Attempt to upload a file >65GB (e.g., via LFS).
- Observe
TotalPartsExceedederror despite S3 allowing >10,000 parts.
GitLab Version:
[Specify your version, e.g., 16.11.0]
References:
- Error observed:
"exceeded total allowed configured MaxUploadParts (10000)" - AWS S3
MaxUploadPartsdocs: link
Key points this issue covers:
- Problem Clarity: Identifies the hardcoded
maxUploadsPartsas the root cause. - Impact: Explains real-world limitations (65GB files failing).
- Solution Focus: Requests configurability, not just a higher default.
- Credibility: References Workhorse code and S3 best practices.
- Reproducibility: Clear steps for the GitLab team to validate.
Where to submit:
- GitLab Workhorse Repository: gitlab-org/gitlab-workhorse
- GitLab Main Repository (if Workhorse changes require coordination): gitlab-org/gitlab
Pro tip:
- Include logs: Attach your error log snippet showing
UploadIdand the 10000 error. - Mention your use case: E.g., “We store large AI datasets via GitLab LFS and hit this weekly.”
- Link related issues: Search for similar reports and reference them.