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

provider/aws: Exposed aws_api_gateway_deployment.created_date attribute #9534

Merged
merged 1 commit into from
Nov 14, 2016

Conversation

Ninir
Copy link
Contributor

@Ninir Ninir commented Oct 23, 2016

Description

This allows to get the API GW deployment created_date when using the aws_api_gateway_deployment resource.

Relevant Terraform version

Checked against: Terraform v0.7.8-dev (7cb2e69+CHANGES)

@kwilczynski
Copy link
Contributor

@Ninir hi there! Thank you so much for the contribution!

Allow me to ask - what is your use case so that you wish to expose creation date? I am not entirely sure why use it might have.

Thank you in advance!

@Ninir
Copy link
Contributor Author

Ninir commented Nov 2, 2016

Hi @kwilczynski,

This is only for information purposes!
Found it could be useful to provide as much data as the sdk / API allows us to have.

Regarding a use-case, I am planning to add another PR which will expose the last_deployment data (saw an attribute for this), and accordingly, the number of deployments.
This would give some data we have in the aws console, and not yet in Terraform! :)

Do you see any blocking-stuff to this?

@Ninir Ninir force-pushed the aws_apigw_deployment_date branch from 2451833 to 9ef6589 Compare November 2, 2016 21:50
@stack72
Copy link
Contributor

stack72 commented Nov 14, 2016

Hi @Ninir

Thanks for the work here - unfortunately the tests fail :(

% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSAPIGatewayDeployment_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/14 10:05:31 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSAPIGatewayDeployment_ -timeout 120m
=== RUN   TestAccAWSAPIGatewayDeployment_basic
--- FAIL: TestAccAWSAPIGatewayDeployment_basic (24.91s)
    testing.go:265: Step 0 error: Check failed: Check 5/5 error: aws_api_gateway_deployment.test: Attribute 'created_date' expected to be set
FAIL
exit status 1
FAIL    github.com/hashicorp/terraform/builtin/providers/aws    24.933s
make: *** [testacc] Error 1

Please can you take a look?

Thanks

Paul

@stack72 stack72 added the waiting-response An issue/pull request is waiting for a response from the community label Nov 14, 2016
@Ninir Ninir force-pushed the aws_apigw_deployment_date branch from 9ef6589 to 6fb63f2 Compare November 14, 2016 10:21
@Ninir
Copy link
Contributor Author

Ninir commented Nov 14, 2016

@stack72 Updated the code.

$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSAPIGatewayDeployment_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/14 11:18:23 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSAPIGatewayDeployment_ -timeout 120m
=== RUN   TestAccAWSAPIGatewayDeployment_basic
--- PASS: TestAccAWSAPIGatewayDeployment_basic (12.31s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    12.339s

It is weird it was passing without the last change (reading after creating) 😅

@stack72
Copy link
Contributor

stack72 commented Nov 14, 2016

This looks better now @Ninir :) Thanks!

% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSAPIGatewayDeployment_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/11/14 12:10:46 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSAPIGatewayDeployment_ -timeout 120m
=== RUN   TestAccAWSAPIGatewayDeployment_basic
--- PASS: TestAccAWSAPIGatewayDeployment_basic (33.66s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    33.678s

@stack72 stack72 merged commit ecb2b74 into hashicorp:master Nov 14, 2016
@Ninir Ninir deleted the aws_apigw_deployment_date branch March 20, 2017 18:13
@ghost
Copy link

ghost commented Apr 15, 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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked and limited conversation to collaborators Apr 15, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement provider/aws waiting-response An issue/pull request is waiting for a response from the community
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants