Although the OCI does not specify strict manifest size limitations, also see spec v1.1 releases, it does suggest at least a 4MiB image manifest size limit. Many clients and registries enforce their own size limits. As such, at some point in time packfiles in the artifact are "merged" to accommodate the manifest size limitation.
Solutions:
- On push, if the fetched existing manifest size is within some amount before the 4MiB limit, merge packfiles to accommodate the limitation.
- Try to push the manifest, and if we get a
413 Payload Too Large response, then begin the merge and retry.
Both solutions may be necessary, in case registries do not adhere to the suggested 4MiB.
Note:
When merging packfiles, it may be best to merge more than necessary such that a re-merge is not necessary on the next N number of pushes; e.g. if the manifest is above 90% of 4MiB, then merge packfiles until 60% of 4MiB.
Although the OCI does not specify strict manifest size limitations, also see spec v1.1 releases, it does suggest at least a 4MiB image manifest size limit. Many clients and registries enforce their own size limits. As such, at some point in time packfiles in the artifact are "merged" to accommodate the manifest size limitation.
Solutions:
413 Payload Too Largeresponse, then begin the merge and retry.Both solutions may be necessary, in case registries do not adhere to the suggested 4MiB.
Note:
When merging packfiles, it may be best to merge more than necessary such that a re-merge is not necessary on the next N number of pushes; e.g. if the manifest is above 90% of 4MiB, then merge packfiles until 60% of 4MiB.