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

aws_apigatewayv2_stage fails with Execution logs are not supported on protocolType HTTP when running on patched aws_provider version 2.65.0 #13801

Closed
reyescameron17 opened this issue Jun 17, 2020 · 5 comments · Fixed by #13809
Assignees
Labels
bug Addresses a defect in current functionality. service/apigatewayv2 Issues and PRs that pertain to the apigatewayv2 service.
Milestone

Comments

@reyescameron17
Copy link

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Terraform Version

13:49:30  + /var/lib/jenkins/tools/org.jenkinsci.plugins.terraform.TerraformInstallation/terraform-12/terraform version
13:49:30  Terraform v0.12.25
13:49:31  + provider.archive v1.3.0
13:49:31  + provider.aws v2.65.0

Affected Resource(s)

  • aws_apigatewayv2_stage

Terraform Configuration Files

resource "aws_apigatewayv2_stage" "some_name" {
  api_id = aws_apigatewayv2_api.some_name.id
  name   = some_name

  auto_deploy   = true
  deployment_id = aws_apigatewayv2_deployment.some_name.id

  route_settings {
    route_key = aws_apigatewayv2_route.some_name.route_key
  }
}

Expected Behavior

A stage should have been successfully created for an HTTP API gateway

Actual Behavior

Terraform fails with following error:

13:49:34  �[1m�[31mError: �[0m�[0m�[1merror creating API Gateway v2 stage: BadRequestException: Execution logs are not supported on protocolType HTTP�[0m

Steps to Reproduce

  1. terraform apply This causes the error

References

Related to:
#12893

@ghost ghost added the service/apigatewayv2 Issues and PRs that pertain to the apigatewayv2 service. label Jun 17, 2020
@github-actions github-actions bot added the needs-triage Waiting for first response or review from a maintainer. label Jun 17, 2020
@reyescameron17
Copy link
Author

I should note, this is for an HTTP API, not websocketAPI. Missed that in the description above.

@ewbankkit ewbankkit added bug Addresses a defect in current functionality. and removed needs-triage Waiting for first response or review from a maintainer. labels Jun 17, 2020
@ewbankkit
Copy link
Contributor

The same error is returned if a default_route_settings block is specified in a configuration.

@ewbankkit
Copy link
Contributor

ewbankkit commented Jun 17, 2020

2020/06/17 15:30:44 [DEBUG] [aws-sdk-go] DEBUG: Request ApiGatewayV2/CreateStage Details:
---[ REQUEST POST-SIGN ]-----------------------------
POST /v2/apis/uzwxrtkd0a/stages HTTP/1.1
Host: apigateway.us-west-2.amazonaws.com
User-Agent: aws-sdk-go/1.32.3 (go1.13.3; linux; amd64) APN/1.0 HashiCorp/1.0 Terraform/0.12.7-sdk (+https://www.terraform.io)
Content-Length: 210
Authorization: AWS4-HMAC-SHA256 Credential=xxxxxxxxxxxxxxxxxxxx/20200617/us-west-2/apigateway/aws4_request, SignedHeaders=content-length;content-type;host;x-amz-date, Signature=**REDACTED**
Content-Type: application/json
X-Amz-Date: 20200617T193044Z
Accept-Encoding: gzip

{"autoDeploy":false,"defaultRouteSettings":{"dataTraceEnabled":true,"detailedMetricsEnabled":true,"throttlingBurstLimit":2222,"throttlingRateLimit":8888},"stageName":"tf-acc-test-1837163068078603425","tags":{}}
-----------------------------------------------------
2020/06/17 15:30:44 [DEBUG] [aws-sdk-go] DEBUG: Response ApiGatewayV2/CreateStage Details:
---[ RESPONSE ]--------------------------------------
HTTP/1.1 400 Bad Request
Connection: close
Content-Length: 73
Content-Type: application/json
Date: Wed, 17 Jun 2020 19:30:45 GMT
X-Amz-Apigw-Id: OSZX3HVNPHcF60g=
X-Amzn-Errortype: BadRequestException
X-Amzn-Requestid: 68840eed-ee7a-411f-9aaa-5e806ef1bd81
X-Amzn-Trace-Id: Root=1-5eea6f65-c3fc108fe6c579b6f2113e4b


-----------------------------------------------------
2020/06/17 15:30:44 [DEBUG] [aws-sdk-go] {
  "message" : "Execution logs are not supported on protocolType HTTP"
}
2020/06/17 15:30:44 [DEBUG] [aws-sdk-go] DEBUG: Validate Response ApiGatewayV2/CreateStage failed, attempt 0/25, error BadRequestException: Execution logs are not supported on protocolType HTTP

The error message is misleading - data_trace_enabled is not valid for HTTP APIs.

@ghost
Copy link

ghost commented Jul 31, 2020

This has been released in version 3.0.0 of the Terraform AWS provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template for triage. Thanks!

@ghost
Copy link

ghost commented Aug 23, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks!

@ghost ghost locked and limited conversation to collaborators Aug 23, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Addresses a defect in current functionality. service/apigatewayv2 Issues and PRs that pertain to the apigatewayv2 service.
Projects
None yet
3 participants