Skip to content

Commit

Permalink
Upgrade terraform-provider-aws to v5.82.1 (#4957)
Browse files Browse the repository at this point in the history
  • Loading branch information
flostadler authored Dec 20, 2024
1 parent f9da959 commit 8517f88
Show file tree
Hide file tree
Showing 311 changed files with 24,506 additions and 1,110 deletions.
1 change: 1 addition & 0 deletions examples/examples_py_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,7 @@ func TestRegress2534(t *testing.T) {
}

func TestRegress4457(t *testing.T) {
t.Skipf("TODO[pulumi/pulumi-aws#4958]")
ptest := pulumiTest(t, filepath.Join("test-programs", "regress-4457"))
upResult := ptest.Up(t)
autoGroupArn := upResult.Outputs["autoGroupArn"].Value.(string)
Expand Down
13 changes: 13 additions & 0 deletions examples/examples_yaml_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,10 @@ func TestSecretVersionUpgrade(t *testing.T) {
testProviderUpgrade(t, filepath.Join("test-programs", "secretversion"), nil)
}

func TestElasticacheReplicationGroupUpgrade(t *testing.T) {
testProviderUpgrade(t, filepath.Join("test-programs", "elasticache-replication-group"), nil)
}

func TestRdsParameterGroupUnclearDiff(t *testing.T) {
t.Parallel()
if testing.Short() {
Expand Down Expand Up @@ -1930,3 +1934,12 @@ func TestSourceCodeHashImportedLambdaChecksCleanly(t *testing.T) {
}
}]`)
}

func TestElasticacheReplicationGroup(t *testing.T) {
t.Parallel()

ptest := pulumiTest(t, filepath.Join("test-programs", "elasticache-replication-group"), opttest.SkipInstall())
upResult := ptest.Up(t)
replicationGroupArn := upResult.Outputs["replicationGroupArn"].Value.(string)
assert.NotEmpty(t, replicationGroupArn)
}
87 changes: 45 additions & 42 deletions examples/go.mod

Large diffs are not rendered by default.

174 changes: 90 additions & 84 deletions examples/go.sum

Large diffs are not rendered by default.

36 changes: 36 additions & 0 deletions examples/provider_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ package examples
import (
"bytes"
"context"
_ "embed"
"encoding/json"
"fmt"
"os"
Expand All @@ -13,15 +14,21 @@ import (

"github.com/pulumi/providertest"
"github.com/pulumi/providertest/optproviderupgrade"
"github.com/pulumi/providertest/providers"
"github.com/pulumi/providertest/pulumitest"
"github.com/pulumi/providertest/pulumitest/assertpreview"
"github.com/pulumi/providertest/pulumitest/optnewstack"
"github.com/pulumi/providertest/pulumitest/opttest"
pfbridge "github.com/pulumi/pulumi-terraform-bridge/v3/pkg/pf/tfbridge"
"github.com/pulumi/pulumi/sdk/v3/go/auto/optpreview"
"github.com/pulumi/pulumi/sdk/v3/go/auto/optup"
"github.com/pulumi/pulumi/sdk/v3/go/common/apitype"
pulumirpc "github.com/pulumi/pulumi/sdk/v3/proto/go"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"

aws "github.com/pulumi/pulumi-aws/provider/v6"
"github.com/pulumi/pulumi-aws/provider/v6/pkg/version"
)

func TestUpgradeCoverage(t *testing.T) {
Expand Down Expand Up @@ -317,3 +324,32 @@ func planEqual(t *testing.T, firstPlan, secondPlan string) bool {

return assert.Equal(t, firstPlanData, secondPlanData)
}

func inPlacePulumiTest(t *testing.T, dir string, opts ...opttest.Option) *pulumitest.PulumiTest {
t.Helper()
if testing.Short() {
t.Skipf("Skipping in testing.Short() mode, assuming this is a CI run without AWS creds")
return nil
}
rpFactory := providers.ResourceProviderFactory(providerServer)

opts = append(opts, opttest.AttachProvider("aws", rpFactory))
return pulumitest.NewPulumiTest(t, dir, opts...)
}

func providerServer(_ providers.PulumiTest) (pulumirpc.ResourceProviderServer, error) {
ctx := context.Background()
// This is necessary for gRPC testing. It doesn't effect integration tests, since
// they use their own binary.
version.Version = "6.0.0"
info := *aws.Provider()

return pfbridge.MakeMuxedServer(ctx, info.Name, info,
/*
* We leave the schema blank. This will result in incorrect calls to
* GetSchema, but otherwise does not effect the provider. It reduces the
* time to test start by minutes.
*/
[]byte("{}"),
)(nil)
}
17 changes: 17 additions & 0 deletions examples/test-programs/elasticache-replication-group/Pulumi.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: elasticache-replication-group
runtime: yaml
config:
pulumi:tags:
value:
pulumi:template: aws-yaml
outputs:
replicationGroupArn: ${replicationGroup.arn}
resources:
replicationGroup:
type: aws:elasticache:ReplicationGroup
properties:
description: Example Replication Group
atRestEncryptionEnabled: true
nodeType: cache.m4.large
numCacheClusters: 1
port: 6379
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{"method":"/pulumirpc.LanguageRuntime/GetPluginInfo","request":{},"response":{}}
{"method":"/pulumirpc.LanguageRuntime/GetPluginInfo","request":{},"response":{}}
{"method":"/pulumirpc.LanguageRuntime/GetRequiredPlugins","request":{"info":{"entryPoint":".","options":{},"programDirectory":"/private/var/folders/qb/q9rbqmxn1jqdfps720v2s9h80000gn/T/TestElasticacheReplicationGroupUpgrade2140664671/007/elasticache-replication-group","rootDirectory":"/private/var/folders/qb/q9rbqmxn1jqdfps720v2s9h80000gn/T/TestElasticacheReplicationGroupUpgrade2140664671/007/elasticache-replication-group"},"program":".","project":"deprecated","pwd":"/private/var/folders/qb/q9rbqmxn1jqdfps720v2s9h80000gn/T/TestElasticacheReplicationGroupUpgrade2140664671/007/elasticache-replication-group"},"response":{"plugins":[{"kind":"resource","name":"aws"}]}}
{"method":"/pulumirpc.ResourceMonitor/SupportsFeature","request":{"id":"resourceReferences"},"response":{"hasSupport":true}}
{"method":"/pulumirpc.ResourceMonitor/SupportsFeature","request":{"id":"outputValues"},"response":{"hasSupport":true}}
{"method":"/pulumirpc.ResourceMonitor/SupportsFeature","request":{"id":"deletedWith"},"response":{"hasSupport":true}}
{"method":"/pulumirpc.ResourceMonitor/SupportsFeature","request":{"id":"aliasSpecs"},"response":{"hasSupport":true}}
{"method":"/pulumirpc.ResourceMonitor/SupportsFeature","request":{"id":"transforms"},"response":{"hasSupport":true}}
{"method":"/pulumirpc.ResourceMonitor/SupportsFeature","request":{"id":"invokeTransforms"},"response":{"hasSupport":true}}
{"method":"/pulumirpc.ResourceMonitor/RegisterResource","request":{"acceptResources":true,"acceptSecrets":true,"customTimeouts":{},"name":"elasticache-replication-group-test","object":{},"sourcePosition":{"line":195,"uri":"project://%2Fhome%2Frunner%2Fwork%2Fpulumi-yaml%2Fpulumi-yaml%2Fpkg%2Fserver%2Fserver.go"},"supportsResultReporting":true,"type":"pulumi:pulumi:Stack"},"response":{"object":{},"urn":"urn:pulumi:test::elasticache-replication-group::pulumi:pulumi:Stack::elasticache-replication-group-test"}}
{"method":"/pulumirpc.ResourceProvider/GetPluginInfo","request":{},"response":{"version":"v5.42.0"}}
{"method":"/pulumirpc.ResourceProvider/CheckConfig","request":{"name":"default","news":{},"olds":{},"type":"pulumi:providers:aws","urn":"urn:pulumi:test::elasticache-replication-group::pulumi:providers:aws::default"},"response":{"inputs":{}}}
{"method":"/pulumirpc.ResourceProvider/Configure","request":{"acceptResources":true,"acceptSecrets":true,"args":{},"sendsOldInputs":true,"sendsOldInputsToDelete":true},"response":{"supportsPreview":true}}
{"method":"/pulumirpc.ResourceProvider/Check","request":{"name":"replicationGroup","news":{"atRestEncryptionEnabled":true,"description":"Example Replication Group","nodeType":"cache.m4.large","numCacheClusters":1,"port":6379},"olds":{},"randomSeed":"fefUMF9ftDGSGZ9YAa9BrUVDMLh99HDFb/J/ql7xRl8=","type":"aws:elasticache/replicationGroup:ReplicationGroup","urn":"urn:pulumi:test::elasticache-replication-group::aws:elasticache/replicationGroup:ReplicationGroup::replicationGroup"},"response":{"inputs":{"__defaults":["automaticFailoverEnabled","engine","multiAzEnabled","replicationGroupId"],"atRestEncryptionEnabled":true,"automaticFailoverEnabled":false,"description":"Example Replication Group","engine":"redis","multiAzEnabled":false,"nodeType":"cache.m4.large","numCacheClusters":1,"port":6379,"replicationGroupId":"replicationgroup-f1113fa"}}}
{"method":"/pulumirpc.ResourceProvider/Create","request":{"name":"replicationGroup","properties":{"__defaults":["automaticFailoverEnabled","engine","multiAzEnabled","replicationGroupId"],"atRestEncryptionEnabled":true,"automaticFailoverEnabled":false,"description":"Example Replication Group","engine":"redis","multiAzEnabled":false,"nodeType":"cache.m4.large","numCacheClusters":1,"port":6379,"replicationGroupId":"replicationgroup-f1113fa"},"type":"aws:elasticache/replicationGroup:ReplicationGroup","urn":"urn:pulumi:test::elasticache-replication-group::aws:elasticache/replicationGroup:ReplicationGroup::replicationGroup"},"response":{"id":"replicationgroup-f1113fa","properties":{"__meta":"{\"e2bfb730-ecaa-11e6-8f88-34363bc7c4c0\":{\"create\":3600000000000,\"delete\":2400000000000,\"update\":2400000000000},\"schema_version\":\"1\"}","arn":"arn:aws:elasticache:us-west-2:616138583583:replicationgroup:replicationgroup-f1113fa","atRestEncryptionEnabled":true,"authToken":{"4dabf18193072939515e22adb298388d":"1b47061264138c4ac30d75fd1eb44270","value":"REDACTED BY PROVIDERTEST"},"autoMinorVersionUpgrade":true,"automaticFailoverEnabled":false,"clusterEnabled":false,"clusterMode":{"numNodeGroups":1,"replicasPerNodeGroup":0},"dataTieringEnabled":false,"description":"Example Replication Group","engine":"redis","engineVersion":"7.1","engineVersionActual":"7.1.0","id":"replicationgroup-f1113fa","kmsKeyId":"","logDeliveryConfigurations":[],"maintenanceWindow":"thu:08:00-thu:09:00","memberClusters":["replicationgroup-f1113fa-001"],"multiAzEnabled":false,"nodeType":"cache.m4.large","numCacheClusters":1,"numNodeGroups":1,"numberCacheClusters":1,"parameterGroupName":"default.redis7","port":6379,"primaryEndpointAddress":"replicationgroup-f1113fa.01fu6p.ng.0001.usw2.cache.amazonaws.com","readerEndpointAddress":"replicationgroup-f1113fa-ro.01fu6p.ng.0001.usw2.cache.amazonaws.com","replicasPerNodeGroup":0,"replicationGroupDescription":"Example Replication Group","replicationGroupId":"replicationgroup-f1113fa","securityGroupIds":[],"securityGroupNames":[],"snapshotRetentionLimit":0,"snapshotWindow":"11:30-12:30","subnetGroupName":"default","tags":{},"tagsAll":{},"transitEncryptionEnabled":false,"userGroupIds":[]}}}
{"method":"/pulumirpc.ResourceMonitor/RegisterResource","request":{"acceptResources":true,"acceptSecrets":true,"additionalSecretOutputs":["authToken"],"custom":true,"customTimeouts":{},"name":"replicationGroup","object":{"atRestEncryptionEnabled":true,"description":"Example Replication Group","nodeType":"cache.m4.large","numCacheClusters":1,"port":6379},"parent":"urn:pulumi:test::elasticache-replication-group::pulumi:pulumi:Stack::elasticache-replication-group-test","propertyDependencies":{"atRestEncryptionEnabled":{},"description":{},"nodeType":{},"numCacheClusters":{},"port":{}},"sourcePosition":{"line":740,"uri":"project://%2Fhome%2Frunner%2Fwork%2Fpulumi-yaml%2Fpulumi-yaml%2Fpkg%2Fpulumiyaml%2Frun.go"},"supportsResultReporting":true,"type":"aws:elasticache/replicationGroup:ReplicationGroup"},"response":{"id":"replicationgroup-f1113fa","object":{"__meta":"{\"e2bfb730-ecaa-11e6-8f88-34363bc7c4c0\":{\"create\":3600000000000,\"delete\":2400000000000,\"update\":2400000000000},\"schema_version\":\"1\"}","arn":"arn:aws:elasticache:us-west-2:616138583583:replicationgroup:replicationgroup-f1113fa","atRestEncryptionEnabled":true,"authToken":{"4dabf18193072939515e22adb298388d":"1b47061264138c4ac30d75fd1eb44270","value":"REDACTED BY PROVIDERTEST"},"autoMinorVersionUpgrade":true,"automaticFailoverEnabled":false,"clusterEnabled":false,"clusterMode":{"numNodeGroups":1,"replicasPerNodeGroup":0},"dataTieringEnabled":false,"description":"Example Replication Group","engine":"redis","engineVersion":"7.1","engineVersionActual":"7.1.0","id":"replicationgroup-f1113fa","kmsKeyId":"","logDeliveryConfigurations":[],"maintenanceWindow":"thu:08:00-thu:09:00","memberClusters":["replicationgroup-f1113fa-001"],"multiAzEnabled":false,"nodeType":"cache.m4.large","numCacheClusters":1,"numNodeGroups":1,"numberCacheClusters":1,"parameterGroupName":"default.redis7","port":6379,"primaryEndpointAddress":"replicationgroup-f1113fa.01fu6p.ng.0001.usw2.cache.amazonaws.com","readerEndpointAddress":"replicationgroup-f1113fa-ro.01fu6p.ng.0001.usw2.cache.amazonaws.com","replicasPerNodeGroup":0,"replicationGroupDescription":"Example Replication Group","replicationGroupId":"replicationgroup-f1113fa","securityGroupIds":[],"securityGroupNames":[],"snapshotRetentionLimit":0,"snapshotWindow":"11:30-12:30","subnetGroupName":"default","tags":{},"tagsAll":{},"transitEncryptionEnabled":false,"userGroupIds":[]},"urn":"urn:pulumi:test::elasticache-replication-group::aws:elasticache/replicationGroup:ReplicationGroup::replicationGroup"}}
{"method":"/pulumirpc.ResourceMonitor/RegisterResourceOutputs","request":{"outputs":{"replicationGroupArn":"arn:aws:elasticache:us-west-2:616138583583:replicationgroup:replicationgroup-f1113fa"},"urn":"urn:pulumi:test::elasticache-replication-group::pulumi:pulumi:Stack::elasticache-replication-group-test"},"response":{}}
{"method":"/pulumirpc.LanguageRuntime/Run","request":{"config":{"pulumi:tags":"{\"pulumi:template\":\"aws-yaml\"}"},"configPropertyMap":{"pulumi:tags":{"pulumi:template":"aws-yaml"}},"info":{"entryPoint":".","options":{},"programDirectory":"/private/var/folders/qb/q9rbqmxn1jqdfps720v2s9h80000gn/T/TestElasticacheReplicationGroupUpgrade2140664671/007/elasticache-replication-group","rootDirectory":"/private/var/folders/qb/q9rbqmxn1jqdfps720v2s9h80000gn/T/TestElasticacheReplicationGroupUpgrade2140664671/007/elasticache-replication-group"},"loaderTarget":"127.0.0.1:59853","monitorAddress":"127.0.0.1:59852","organization":"organization","parallel":48,"program":".","project":"elasticache-replication-group","pwd":"/private/var/folders/qb/q9rbqmxn1jqdfps720v2s9h80000gn/T/TestElasticacheReplicationGroupUpgrade2140664671/007/elasticache-replication-group","stack":"test"},"response":{}}
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
{
"version": 3,
"deployment": {
"manifest": {
"time": "2024-12-20T13:46:26.187433+01:00",
"magic": "3b1911ae6e2d8d1f468975cdca7c3c6a48585f5e805330548231ecc6cfbc84ff",
"version": "v3.136.1"
},
"secrets_providers": {
"type": "passphrase",
"state": {
"salt": "v1:oy5ax0JrJHw=:v1:uPbfPDSCG3f7S7Tc:xM0PIOYrlASy+hEOXlvtZF6vRhGylw=="
}
},
"resources": [
{
"urn": "urn:pulumi:test::elasticache-replication-group::pulumi:pulumi:Stack::elasticache-replication-group-test",
"custom": false,
"type": "pulumi:pulumi:Stack",
"outputs": {
"replicationGroupArn": "arn:aws:elasticache:us-west-2:616138583583:replicationgroup:replicationgroup-f1113fa"
},
"created": "2024-12-20T12:38:08.439718Z",
"modified": "2024-12-20T12:38:08.439718Z"
},
{
"urn": "urn:pulumi:test::elasticache-replication-group::pulumi:providers:aws::default",
"custom": true,
"id": "3594d271-89a2-49ba-abff-89e893f43a1e",
"type": "pulumi:providers:aws",
"created": "2024-12-20T12:38:15.234254Z",
"modified": "2024-12-20T12:38:15.234254Z"
},
{
"urn": "urn:pulumi:test::elasticache-replication-group::aws:elasticache/replicationGroup:ReplicationGroup::replicationGroup",
"custom": true,
"id": "replicationgroup-f1113fa",
"type": "aws:elasticache/replicationGroup:ReplicationGroup",
"inputs": {
"__defaults": [
"automaticFailoverEnabled",
"engine",
"multiAzEnabled",
"replicationGroupId"
],
"atRestEncryptionEnabled": true,
"automaticFailoverEnabled": false,
"description": "Example Replication Group",
"engine": "redis",
"multiAzEnabled": false,
"nodeType": "cache.m4.large",
"numCacheClusters": 1,
"port": 6379,
"replicationGroupId": "replicationgroup-f1113fa"
},
"outputs": {
"__meta": "{\"e2bfb730-ecaa-11e6-8f88-34363bc7c4c0\":{\"create\":3600000000000,\"delete\":2400000000000,\"update\":2400000000000},\"schema_version\":\"1\"}",
"arn": "arn:aws:elasticache:us-west-2:616138583583:replicationgroup:replicationgroup-f1113fa",
"atRestEncryptionEnabled": true,
"authToken": {
"4dabf18193072939515e22adb298388d": "1b47061264138c4ac30d75fd1eb44270",
"plaintext": "\"REDACTED BY PROVIDERTEST\""
},
"autoMinorVersionUpgrade": true,
"automaticFailoverEnabled": false,
"clusterEnabled": false,
"clusterMode": {
"numNodeGroups": 1,
"replicasPerNodeGroup": 0
},
"dataTieringEnabled": false,
"description": "Example Replication Group",
"engine": "redis",
"engineVersion": "7.1",
"engineVersionActual": "7.1.0",
"id": "replicationgroup-f1113fa",
"kmsKeyId": "",
"logDeliveryConfigurations": [],
"maintenanceWindow": "thu:08:00-thu:09:00",
"memberClusters": [
"replicationgroup-f1113fa-001"
],
"multiAzEnabled": false,
"nodeType": "cache.m4.large",
"numCacheClusters": 1,
"numNodeGroups": 1,
"numberCacheClusters": 1,
"parameterGroupName": "default.redis7",
"port": 6379,
"primaryEndpointAddress": "replicationgroup-f1113fa.01fu6p.ng.0001.usw2.cache.amazonaws.com",
"readerEndpointAddress": "replicationgroup-f1113fa-ro.01fu6p.ng.0001.usw2.cache.amazonaws.com",
"replicasPerNodeGroup": 0,
"replicationGroupDescription": "Example Replication Group",
"replicationGroupId": "replicationgroup-f1113fa",
"securityGroupIds": [],
"securityGroupNames": [],
"snapshotRetentionLimit": 0,
"snapshotWindow": "11:30-12:30",
"subnetGroupName": "default",
"tags": {},
"tagsAll": {},
"transitEncryptionEnabled": false,
"userGroupIds": []
},
"parent": "urn:pulumi:test::elasticache-replication-group::pulumi:pulumi:Stack::elasticache-replication-group-test",
"provider": "urn:pulumi:test::elasticache-replication-group::pulumi:providers:aws::default::3594d271-89a2-49ba-abff-89e893f43a1e",
"propertyDependencies": {
"atRestEncryptionEnabled": [],
"description": [],
"nodeType": [],
"numCacheClusters": [],
"port": []
},
"additionalSecretOutputs": [
"authToken"
],
"created": "2024-12-20T12:46:26.168687Z",
"modified": "2024-12-20T12:46:26.168687Z"
}
],
"metadata": {}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Subject: [PATCH] Remove lakeformation catalog_resource default


diff --git a/internal/service/lakeformation/permissions.go b/internal/service/lakeformation/permissions.go
index 48ff32d5a5..06523ef2da 100644
index f05de48b13..f22ab6cb01 100644
--- a/internal/service/lakeformation/permissions.go
+++ b/internal/service/lakeformation/permissions.go
@@ -44,8 +44,8 @@ func ResourcePermissions() *schema.Resource {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ index 961d1f0438..710fd0b998 100644
"hls_ingest": {
Type: schema.TypeList,
diff --git a/internal/service/memorydb/cluster.go b/internal/service/memorydb/cluster.go
index ec8b06cf70..2be5b88de3 100644
index f3a35c84e5..1e3027048a 100644
--- a/internal/service/memorydb/cluster.go
+++ b/internal/service/memorydb/cluster.go
@@ -79,7 +79,7 @@ func resourceCluster() *schema.Resource {
Expand Down Expand Up @@ -226,7 +226,7 @@ index d19358fa76..b13859ab8e 100644
names.AttrSkipDestroy: {
Type: schema.TypeBool,
diff --git a/internal/service/rds/parameter_group.go b/internal/service/rds/parameter_group.go
index 8c49d1133c..17c729d305 100644
index 0e4ca3f870..c1e331f54f 100644
--- a/internal/service/rds/parameter_group.go
+++ b/internal/service/rds/parameter_group.go
@@ -53,7 +53,7 @@ func resourceParameterGroup() *schema.Resource {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ index 18133c7439..ea9f2d088f 100644
Blocks: map[string]schema.Block{
"export": schema.ListNestedBlock{
diff --git a/internal/service/bedrockagent/agent.go b/internal/service/bedrockagent/agent.go
index 4a983c9ca6..b596196ea6 100644
index ffd7430856..2ddfed3ebd 100644
--- a/internal/service/bedrockagent/agent.go
+++ b/internal/service/bedrockagent/agent.go
@@ -165,7 +165,7 @@ func (r *agentResource) Schema(ctx context.Context, request resource.SchemaReque
@@ -170,7 +170,7 @@ func (r *agentResource) Schema(ctx context.Context, request resource.SchemaReque
},
},
names.AttrTags: tftags.TagsAttribute(),
Expand Down
Loading

0 comments on commit 8517f88

Please sign in to comment.