Commit Graph

15 Commits

Author SHA1 Message Date
stack72 2a07f86041 provider/aws: Support Import for `aws_elasticache_subnet_group`
```
make testacc TEST=./builtin/providers/aws
TESTARGS='-run=TestAccAWSElasticacheSubnetGroup_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v
-run=TestAccAWSElasticacheSubnetGroup_ -timeout 120m
=== RUN   TestAccAWSElasticacheSubnetGroup_importBasic
--- PASS: TestAccAWSElasticacheSubnetGroup_importBasic (46.80s)
=== RUN   TestAccAWSElasticacheSubnetGroup_basic
--- PASS: TestAccAWSElasticacheSubnetGroup_basic (48.79s)
=== RUN   TestAccAWSElasticacheSubnetGroup_update
--- PASS: TestAccAWSElasticacheSubnetGroup_update (76.81s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    172.431s
```
2016-06-23 02:12:02 +01:00
clint shryock 1624c7e27f provider/aws: Log ElasticCache subnet removal 2016-06-08 13:35:49 -05:00
stack72 2a09941f76 provider/aws: Update state on `aws_elasticache_subnet_group` not found exception
Fixes #7062

make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSElasticacheSubnetGroup'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /vendor/)
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSElasticacheSubnetGroup -timeout 120m
=== RUN   TestAccAWSElasticacheSubnetGroup_basic
--- PASS: TestAccAWSElasticacheSubnetGroup_basic (44.62s)
=== RUN   TestAccAWSElasticacheSubnetGroup_update
--- PASS: TestAccAWSElasticacheSubnetGroup_update (73.74s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	118.379s
2016-06-08 16:00:13 +02:00
Joshua Spence c193cbdc03 Add default description
Closes #6100. Set the default value for the `description` field to be "Managed by Terraform".
2016-05-23 06:46:45 +10:00
Paul Hinze 108ccf0007 builtin: Refactor resource.Retry to clarify return
Change the `RetryFunc` from a plain `error` return type to a
specialized `RetryError` which must decide whether it is
retryable or not.

Add `RetryableError` / `NonRetryableError` factory functions that
callers are meant to use to build up these errors.

This makes it eminently clear whether or not a given error is
retryable from inside the client code.

Goal here is to _not_ change any behavior, simply reflect the
existing behavior with the new, clearer, API.
2016-03-09 17:37:56 -06:00
Paul Hinze cb8f0f04b5 fix go vet warnings
```
go tool vet -all .
builtin/providers/aws/resource_aws_elasticache_security_group.go:130: arg apierr.Code in printf call is a function value, not a function call
builtin/providers/aws/resource_aws_elasticache_subnet_group.go:155: arg apierr.Code in printf call is a function value, not a function call
```
2016-02-24 09:48:32 -06:00
Trevor Pounds 0cd0ff0f8e Use built-in schema.HashString. 2016-02-07 16:29:34 -08:00
Martin Atkins 4ae3a17eab aws_elasticache_subnet_group normalizes name to lowercase.
The Elasticache API accepts a mixed-case subnet name on create, but
normalizes it to lowercase before storing it. When retrieving a subnet,
the name is treated as case-sensitive, so the lowercase version must be
used.

Given that case within subnet names is not significant, the new StateFunc
on the name attribute causes the state to reflect the lowercase version
that the API uses, and changes in case alone will not show as a diff.

Given that we must look up subnet names in lower case, we set the
instance id to be a lowercase version of the user's provided name. This
then allows a later Refresh call to succeed even if the user provided
a mixed-case name.

Previously users could work around this by just avoiding putting uppercase
letters in the name, but that is often inconvenient if e.g. the name is
being constructed from variables defined elsewhere that may already have
uppercase letters present.
2015-09-03 10:03:35 -07:00
Clint Shryock 0c2f189d08 provider/aws: Update to aws-sdk 0.9.0 rc1 2015-08-17 13:27:16 -05:00
Daisuke Fujita 562cf596dc Make elasticache_subnet_group subnet_ids essential 2015-06-28 16:13:25 +09:00
Paul Hinze b71fa3d0ae provider/aws: handle upstream aws-sdk-go repo move
`awslabs/aws-sdk-go => aws/aws-sdk-go`

Congrats to upstream on the promotion. :)
2015-06-03 13:36:57 -05:00
Clint Shryock a2717acf81 provider/aws: Allow ElastiCache Subnet Group updates
Adds update method for ElastiCache Subnet Groups, things are not all ForceNew
anymore.

- can update description
- can update subnet ids
2015-06-02 11:19:23 -05:00
Clint Shryock d06f637c74 fix typo, use awslabs/aws-sdk-go 2015-05-27 16:07:38 -05:00
Paul Hinze 31258e06c6 provider/aws: fix breakages from awserr refactor
This landed in aws-sdk-go yesterday, breaking the AWS provider in many places:

3c259c9586

Here, with much sedding, grepping, and manual massaging, we attempt to
catch Terraform up to the new `awserr.Error` interface world.
2015-05-20 06:21:23 -05:00
Tomotaka Sakuma f3d9a287e1 support aws resource ElastiCache 2015-04-26 10:53:21 +09:00