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_sqs_queue fifo queues with no name provided do not generate valid queue name. #17005

Closed
steven-schmoll-at opened this issue Jan 7, 2021 · 2 comments · Fixed by #17164
Closed
Labels
bug Addresses a defect in current functionality. service/sqs Issues and PRs that pertain to the sqs service.
Milestone

Comments

@steven-schmoll-at
Copy link

When creating a fifo sqs queue resource without specifying a name or prefix, the generated name does not have the required .fifo suffix causing AWS to reject the queue creation.

The issue appears to be here: https://github.com/hashicorp/terraform-provider-aws/blob/master/aws/resource_aws_sqs_queue.go#L150

When using name_prefix the .fifo suffix will be appended but not when using a unique id.

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 CLI and Terraform AWS Provider Version

Terraform v0.14.3
+ provider registry.terraform.io/hashicorp/aws v3.22.0
+ provider registry.terraform.io/hashicorp/null v3.0.0
+ provider registry.terraform.io/hashicorp/time v0.6.0
+ provider registry.terraform.io/phillbaker/elasticsearch v1.5.1

Affected Resource(s)

  • aws_sqs_queue

Terraform Configuration Files

terraform {
  required_providers {
    aws = {
      source = "hashicorp/aws"
      version = "3.22"
    }
  }
}

provider "aws" {
  region = "ap-southeast-2"
}

resource "aws_sqs_queue" "test_queue" {
  fifo_queue = true
}

Debug Output

Debug Log

Expected Behavior

The queue should have been created with a name such as terraform-20210107023518303200000001.fifo

Actual Behavior

Creation was attempted with the name terraform-20210107023518303200000001 which was rejected by the AWS API.

Steps to Reproduce

Nothing fancy, just use the config above and apply

  1. terraform apply

Important Factoids

None

References

@ghost ghost added the service/sqs Issues and PRs that pertain to the sqs service. label Jan 7, 2021
@github-actions github-actions bot added the needs-triage Waiting for first response or review from a maintainer. label Jan 7, 2021
@bflad bflad added enhancement Requests to existing resources that expand the functionality or scope. and removed needs-triage Waiting for first response or review from a maintainer. labels Jan 11, 2021
@ewbankkit ewbankkit added bug Addresses a defect in current functionality. and removed enhancement Requests to existing resources that expand the functionality or scope. labels Apr 14, 2021
@github-actions github-actions bot added this to the v3.37.0 milestone Apr 15, 2021
@ghost
Copy link

ghost commented Apr 16, 2021

This has been released in version 3.37.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 May 16, 2021

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 as resolved and limited conversation to collaborators May 16, 2021
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/sqs Issues and PRs that pertain to the sqs service.
Projects
None yet
3 participants