Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

validate package size doesn't exceed limit #380

Merged
merged 3 commits into from Sep 2, 2021

Conversation

Integralist
Copy link
Collaborator

Fixes #362

@Integralist Integralist added the enhancement New feature or request label Sep 2, 2021
@Integralist Integralist requested review from a team, triblondon and kailan and removed request for a team September 2, 2021 10:39
Comment on lines +345 to +350
if pkgSize > PackageSizeLimit {
return pkgName, pkgPath, errors.RemediationError{
Inner: fmt.Errorf("package size is too large (%d bytes)", pkgSize),
Remediation: errors.PackageSizeRemediation,
}
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, I like the remediation pointing to the resource limits page 👍

Copy link
Member

@kailan kailan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great 👍

@Integralist Integralist merged commit da59098 into main Sep 2, 2021
@Integralist Integralist deleted the integralist/package-size-error branch September 2, 2021 12:58
// current package size limit.
var PackageSizeRemediation = strings.Join([]string{
"Please check our Compute@Edge resource limits:",
"https://docs.fastly.com/products/compute-at-edge-billing-and-resource-limits#resource-limits",
Copy link
Contributor

@triblondon triblondon Sep 2, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @triblondon. Once that content is available there we should update the code to reference the new location.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

JS C@E publish error "ERROR: the Fastly API returned 503 Service Unavailable: ."
4 participants