-
Notifications
You must be signed in to change notification settings - Fork 4k
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
(apigateway): support for minimumCompressionSize #22926
Comments
Thanks for the request. Assuming there's no barrier to adding this prop to the SpecRestApi, this should be pretty simple to add to our SpecRestApi props, and then passing it in here
Before we support this, you can use escape hatches to make use of the property: const specRestApi = new SpecRestApi(...);
(specRestApi.node.defaultChild as CfnRestApi).addPropertyOverride('MinimumCompressionSize', x); I am marking this issue as p2, which means that we are unable to work on this immediately. We use +1s to help prioritize our work, and are happy to revaluate this issue based on community feedback. You can reach out to the cdk.dev community on Slack to solicit support for reprioritization. Check out our contributing guide if you're interested in contributing yourself - there's a low chance the team will be able to address this soon but we'd be happy to review a PR 🙂 |
Hi @drissamri Are you interested to pick up with the PR against this issue? I would be happy to help you get started. Feel free to reach out to me on cdk.dev slack. |
I would like to take up this issue and contribute the fix. Please let me know if you can assign it. :) |
The linked PR looks like it was closed due to inactivity. Is this something I can pick up and finish off? |
Looks like the issue is yours for the taking @atchla! Go ahead 🙂 |
This PR adds minCompressionSize to SpecRestApi, which allows compression on api's payload. Within SpecRestApi ``` minComppresssionSize: Size``` is the additional prop added to SpecRestApiProps to support minCompressionSize which takes class Size, the value of how much the payload needs to be compressed. This PR also adds minCompressionSize to RestApi which supports Size class e.g ``` minComppresssionSize: Size``` and deprecates minimumCompressionSize which has number as a type. For example, ```ts const api = new apigw.RestApi(stack, 'RestApi', { minCompressionSize: Size.bytes(1024), }); ``` compression for the payload would be 1024 bytes which is equivalent to 1 kibibyte. Closes #22926. ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
|
I had some things come up and didn't have enough bandwidth to take this task any more. Thanks for finishing it out @pattasai ! |
This PR adds minCompressionSize to SpecRestApi, which allows compression on api's payload. Within SpecRestApi ``` minComppresssionSize: Size``` is the additional prop added to SpecRestApiProps to support minCompressionSize which takes class Size, the value of how much the payload needs to be compressed. This PR also adds minCompressionSize to RestApi which supports Size class e.g ``` minComppresssionSize: Size``` and deprecates minimumCompressionSize which has number as a type. For example, ```ts const api = new apigw.RestApi(stack, 'RestApi', { minCompressionSize: Size.bytes(1024), }); ``` compression for the payload would be 1024 bytes which is equivalent to 1 kibibyte. Closes aws#22926. ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
Describe the feature
SpecRestApi doesn't support minimumCompressionSize, while RestApi does
Use Case
We generate our API's based off a Open API specification and would like to use compression on our APIs
Proposed Solution
No response
Other Information
No response
Acknowledgements
CDK version used
2.50
Environment details (OS name and version, etc.)
OSX
The text was updated successfully, but these errors were encountered: