Description:
While working with helm-s3, I encountered an issue where large metadata in Chart.yaml caused failures during reindexing. The issue arises because helm-s3 marshals the chart's metadata into JSON and stores it as x-amz-meta-chart-metadata in an S3 object, but S3 limits metadata to 2KB. If the metadata exceeds this limit, it gets truncated, leading to issues when reindexing charts.
S3 docs
![Uploading Screenshot 2024-09-29 at 8.46.22.png…]()
Steps to Reproduce:
- Add a long string (e.g., in the
description field) in Chart.yaml.
- Push the chart using
helm-s3.
- The chart gets uploaded, but the metadata is marshaled into
x-amz-meta-chart-metadata and truncated due to the 2KB limit.
- When running
helm s3 reindex, the metadata fails to unmarshal, causing the reindex operation to fail.
Proposal:
To avoid this issue and prevent future operations (such as reindexing) from failing, I propose that the Push command should throw an error if the metadata exceeds 2KB. This will inform users at the point of pushing the chart, allowing them to adjust the metadata size before uploading.
Benefit:
By adding this validation to the Push operation, users will be able to resolve the issue earlier, avoiding troubleshooting time and preventing failures in subsequent operations such as reindex.
Description:
While working with
helm-s3, I encountered an issue where large metadata inChart.yamlcaused failures during reindexing. The issue arises becausehelm-s3marshals the chart's metadata into JSON and stores it asx-amz-meta-chart-metadatain an S3 object, but S3 limits metadata to 2KB. If the metadata exceeds this limit, it gets truncated, leading to issues when reindexing charts.S3 docs
![Uploading Screenshot 2024-09-29 at 8.46.22.png…]()
Steps to Reproduce:
descriptionfield) inChart.yaml.helm-s3.x-amz-meta-chart-metadataand truncated due to the 2KB limit.helm s3 reindex, the metadata fails to unmarshal, causing the reindex operation to fail.Proposal:
To avoid this issue and prevent future operations (such as reindexing) from failing, I propose that the
Pushcommand should throw an error if the metadata exceeds 2KB. This will inform users at the point of pushing the chart, allowing them to adjust the metadata size before uploading.Benefit:
By adding this validation to the
Pushoperation, users will be able to resolve the issue earlier, avoiding troubleshooting time and preventing failures in subsequent operations such asreindex.