-
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
feat(apigatewayv2): AWS type websocket api integration in http api #28718
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The pull request linter has failed. See the aws-cdk-automation comment below for failure reasons. If you believe this pull request should receive an exemption, please comment and provide a justification.
A comment requesting an exemption should contain the text Exemption Request
. Additionally, if clarification is needed add Clarification Request
to a comment.
✅ Updated pull request passes all PRLinter validations. Dismissing previous PRLinter review.
I'd love to see a facilitator to configure the permission of the Websockets to invoke the service. |
I'm curious how that would be possible. For lambda integration, it's clear that this would be a connection between http api and lambda function so we can easily add a lambda permission to allow api to invoke lambda. For AWS integration, depending on the AWS service you want to integrate, the IAM role/policy varies. I couldn't think of a way to configure the permission automatically. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
packages/aws-cdk-lib/aws-apigatewayv2-integrations/lib/websocket/aws.ts
Outdated
Show resolved
Hide resolved
packages/aws-cdk-lib/aws-apigatewayv2-integrations/lib/websocket/aws.ts
Outdated
Show resolved
Hide resolved
packages/aws-cdk-lib/aws-apigatewayv2/lib/websocket/integration.ts
Outdated
Show resolved
Hide resolved
packages/aws-cdk-lib/aws-apigatewayv2-integrations/lib/websocket/aws.ts
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Few more comments @GavinZZ
packages/aws-cdk-lib/aws-apigatewayv2-integrations/lib/websocket/aws.ts
Outdated
Show resolved
Hide resolved
packages/aws-cdk-lib/aws-apigatewayv2/lib/websocket/integration.ts
Outdated
Show resolved
Hide resolved
packages/aws-cdk-lib/aws-apigatewayv2/lib/websocket/integration.ts
Outdated
Show resolved
Hide resolved
Thanks @kaizencc for the reviews. I've addressed all the feedbacks. Feel free to give it another pass at your convenience. |
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
Hi @GavinZZ and @kaizencc, I was testing the code this evening and I'm noticing RequestParameters is not being added to the websocket integration. After reviewing the code, the WebSocketRouteIntegrationConfig within packages/aws-cdk-lib/aws-apigatewayv2-integrations/lib/websocket/aws.ts appears to be missing the requestParameters bind. I believe if "requestParameters: this.props.requestParameters" was added to the bind, it would resolve the issue. |
@georgechristman thanks for the find, I have added it and waiting for a review. @kaizencc #28859 |
has this been released to some version yet? |
I think I was able to resolve FayezX's issue. #28905 |
Currently, Amazon.CDK.AWS.Apigatewayv2 lacks support for AWS option as the IntegrationType for WebSocket Apigateway.
Added the capability that allows user to create a WebSocket Apigateway that calls directly other AWS services without a Lambda function middleware.
Closes #27164.
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license