fix(stepfunctions-tasks): Stage field not included in CallApiGatewayHttpApiEndpoint task definition#15755
Conversation
stageName is explicitly definedStage field not included in task definition when stageName is explicitly defined
|
I'm not sure if the behavior I'll be describing below is intended, but I think it's worth mentioning because it was unexpected. While playing around with the integration tests in So assuming we have setup a stage const httpApi = new apigatewayv2.HttpApi(stack, 'MyHttpApi');
httpApi.addStage('Test', {
stageName: 'test',
autoDeploy: true,
});
httpApi.addRoutes({
path: '/',
integration: new integrations.LambdaProxyIntegration({
handler: // lambda handler,
}),
});This task will run successfully, which uses the default stage: new CallApiGatewayHttpApiEndpoint(stack, 'Call APIGW', {
apiId: httpApi.apiId,
apiStack: cdk.Stack.of(httpApi),
method: HttpMethod.GET,
});On the other hand if we specified the stage name new CallApiGatewayHttpApiEndpoint(stack, 'Call APIGW Stage', {
apiId: httpApi.apiId,
apiStack: cdk.Stack.of(httpApi),
method: HttpMethod.GET,
stageName: 'test',
});To remedy this we would need to assign the apiPath: '',Is this intended or should this be considered a bug that requires fixing? |
Stage field not included in task definition when stageName is explicitly defined|
That is definitely a bug as well, need to add I took a brief tour through the module and there are a bunch of issues. In fact, I'm not sure how the state machine successfully executes given the very much incorrect ARN that is created when |
|
Thank you for contributing! Your pull request will be updated from master 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 master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
…ttpApiEndpoint task definition (aws#15755) `this.stageName` was not initialized by `props.stageName` when calling `CallApiGatewayHttpApiEndpoint`'s constructor, therefore causing the `Stage` field to not get rendered even though we specified that property. fixes aws#14242 ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
…ttpApiEndpoint task definition (aws#15755) `this.stageName` was not initialized by `props.stageName` when calling `CallApiGatewayHttpApiEndpoint`'s constructor, therefore causing the `Stage` field to not get rendered even though we specified that property. fixes aws#14242 ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
this.stageNamewas not initialized byprops.stageNamewhen callingCallApiGatewayHttpApiEndpoint's constructor, therefore causing theStagefield to not get rendered even though we specified that property.fixes #14242
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license