Skip to content

Commit

Permalink
Merge pull request #40420 from hashicorp/f-s3tables
Browse files Browse the repository at this point in the history
New Service: `s3tables`
  • Loading branch information
gdavison authored Dec 4, 2024
2 parents c9525b0 + 533bd2c commit 51769a8
Show file tree
Hide file tree
Showing 52 changed files with 5,482 additions and 136 deletions.
19 changes: 19 additions & 0 deletions .changelog/40420.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
```release-note:new-resource
aws_s3tables_namespace
```

```release-note:new-resource
aws_s3tables_table_bucket
```

```release-note:new-resource
aws_s3tables_table_bucket_policy
```

```release-note:new-resource
aws_s3tables_table
```

```release-note:new-resource
aws_s3tables_table_policy
```
15 changes: 15 additions & 0 deletions .ci/.semgrep-service-name0.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4315,3 +4315,18 @@ rules:
- focus-metavariable: $NAME
- pattern-not: func $NAME($T *testing.T)
severity: WARNING
- id: connect-in-test-name
languages:
- go
message: Include "Connect" in test name
paths:
include:
- internal/service/connect/*_test.go
patterns:
- pattern: func $NAME( ... )
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-not-regex: "^TestAccConnect"
- pattern-regex: ^TestAcc.*
severity: WARNING
47 changes: 32 additions & 15 deletions .ci/.semgrep-service-name1.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,5 @@
# Generated by internal/generate/servicesemgrep/main.go; DO NOT EDIT.
rules:
- id: connect-in-test-name
languages:
- go
message: Include "Connect" in test name
paths:
include:
- internal/service/connect/*_test.go
patterns:
- pattern: func $NAME( ... )
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-not-regex: "^TestAccConnect"
- pattern-regex: ^TestAcc.*
severity: WARNING
- id: connect-in-const-name
languages:
- go
Expand Down Expand Up @@ -4305,3 +4290,35 @@ rules:
patterns:
- pattern-regex: "(?i)IoTAnalytics"
severity: WARNING
- id: iotanalytics-in-var-name
languages:
- go
message: Do not use "IoTAnalytics" in var name inside iotanalytics package
paths:
include:
- internal/service/iotanalytics
patterns:
- pattern: var $NAME = ...
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-regex: "(?i)IoTAnalytics"
severity: WARNING
- id: iotevents-in-func-name
languages:
- go
message: Do not use "IoTEvents" in func name inside iotevents package
paths:
include:
- internal/service/iotevents
exclude:
- internal/service/iotevents/list_pages_gen.go
patterns:
- pattern: func $NAME( ... )
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-regex: "(?i)IoTEvents"
- focus-metavariable: $NAME
- pattern-not: func $NAME($T *testing.T)
severity: WARNING
79 changes: 47 additions & 32 deletions .ci/.semgrep-service-name2.yml
Original file line number Diff line number Diff line change
@@ -1,37 +1,5 @@
# Generated by internal/generate/servicesemgrep/main.go; DO NOT EDIT.
rules:
- id: iotanalytics-in-var-name
languages:
- go
message: Do not use "IoTAnalytics" in var name inside iotanalytics package
paths:
include:
- internal/service/iotanalytics
patterns:
- pattern: var $NAME = ...
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-regex: "(?i)IoTAnalytics"
severity: WARNING
- id: iotevents-in-func-name
languages:
- go
message: Do not use "IoTEvents" in func name inside iotevents package
paths:
include:
- internal/service/iotevents
exclude:
- internal/service/iotevents/list_pages_gen.go
patterns:
- pattern: func $NAME( ... )
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-regex: "(?i)IoTEvents"
- focus-metavariable: $NAME
- pattern-not: func $NAME($T *testing.T)
severity: WARNING
- id: iotevents-in-test-name
languages:
- go
Expand Down Expand Up @@ -4308,3 +4276,50 @@ rules:
patterns:
- pattern-regex: "(?i)Redshift"
severity: WARNING
- id: redshiftdata-in-func-name
languages:
- go
message: Do not use "RedshiftData" in func name inside redshiftdata package
paths:
include:
- internal/service/redshiftdata
exclude:
- internal/service/redshiftdata/list_pages_gen.go
patterns:
- pattern: func $NAME( ... )
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-regex: "(?i)RedshiftData"
- focus-metavariable: $NAME
- pattern-not: func $NAME($T *testing.T)
severity: WARNING
- id: redshiftdata-in-test-name
languages:
- go
message: Include "RedshiftData" in test name
paths:
include:
- internal/service/redshiftdata/*_test.go
patterns:
- pattern: func $NAME( ... )
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-not-regex: "^TestAccRedshiftData"
- pattern-regex: ^TestAcc.*
severity: WARNING
- id: redshiftdata-in-const-name
languages:
- go
message: Do not use "RedshiftData" in const name inside redshiftdata package
paths:
include:
- internal/service/redshiftdata
patterns:
- pattern: const $NAME = ...
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-regex: "(?i)RedshiftData"
severity: WARNING
108 changes: 61 additions & 47 deletions .ci/.semgrep-service-name3.yml
Original file line number Diff line number Diff line change
@@ -1,52 +1,5 @@
# Generated by internal/generate/servicesemgrep/main.go; DO NOT EDIT.
rules:
- id: redshiftdata-in-func-name
languages:
- go
message: Do not use "RedshiftData" in func name inside redshiftdata package
paths:
include:
- internal/service/redshiftdata
exclude:
- internal/service/redshiftdata/list_pages_gen.go
patterns:
- pattern: func $NAME( ... )
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-regex: "(?i)RedshiftData"
- focus-metavariable: $NAME
- pattern-not: func $NAME($T *testing.T)
severity: WARNING
- id: redshiftdata-in-test-name
languages:
- go
message: Include "RedshiftData" in test name
paths:
include:
- internal/service/redshiftdata/*_test.go
patterns:
- pattern: func $NAME( ... )
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-not-regex: "^TestAccRedshiftData"
- pattern-regex: ^TestAcc.*
severity: WARNING
- id: redshiftdata-in-const-name
languages:
- go
message: Do not use "RedshiftData" in const name inside redshiftdata package
paths:
include:
- internal/service/redshiftdata
patterns:
- pattern: const $NAME = ...
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-regex: "(?i)RedshiftData"
severity: WARNING
- id: redshiftdata-in-var-name
languages:
- go
Expand Down Expand Up @@ -1236,6 +1189,67 @@ rules:
patterns:
- pattern-regex: "(?i)S3Outposts"
severity: WARNING
- id: s3tables-in-func-name
languages:
- go
message: Do not use "S3Tables" in func name inside s3tables package
paths:
include:
- internal/service/s3tables
exclude:
- internal/service/s3tables/list_pages_gen.go
patterns:
- pattern: func $NAME( ... )
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-regex: "(?i)S3Tables"
- focus-metavariable: $NAME
- pattern-not: func $NAME($T *testing.T)
severity: WARNING
- id: s3tables-in-test-name
languages:
- go
message: Include "S3Tables" in test name
paths:
include:
- internal/service/s3tables/*_test.go
patterns:
- pattern: func $NAME( ... )
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-not-regex: "^TestAccS3Tables"
- pattern-regex: ^TestAcc.*
severity: WARNING
- id: s3tables-in-const-name
languages:
- go
message: Do not use "S3Tables" in const name inside s3tables package
paths:
include:
- internal/service/s3tables
patterns:
- pattern: const $NAME = ...
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-regex: "(?i)S3Tables"
severity: WARNING
- id: s3tables-in-var-name
languages:
- go
message: Do not use "S3Tables" in var name inside s3tables package
paths:
include:
- internal/service/s3tables
patterns:
- pattern: var $NAME = ...
- metavariable-pattern:
metavariable: $NAME
patterns:
- pattern-regex: "(?i)S3Tables"
severity: WARNING
- id: sagemaker-in-func-name
languages:
- go
Expand Down
1 change: 1 addition & 0 deletions .ci/semgrep/aws/go-sdk-v1.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ rules:
- metavariable-regex:
metavariable: "$X"
regex: '^github.com/aws/aws-sdk-go/.+$'
- focus-metavariable: $X
severity: WARNING

- id: aws-sdk-go-base-awsv1shim-imports
Expand Down
2 changes: 2 additions & 0 deletions .github/labeler-issue-triage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -599,6 +599,8 @@ service/s3control:
- '((\*|-)\s*`?|(data|resource)\s+"?)aws_(s3_account_|s3control_|s3_access_)'
service/s3outposts:
- '((\*|-)\s*`?|(data|resource)\s+"?)aws_s3outposts_'
service/s3tables:
- '((\*|-)\s*`?|(data|resource)\s+"?)aws_s3tables_'
service/sagemaker:
- '((\*|-)\s*`?|(data|resource)\s+"?)aws_sagemaker_'
service/sagemakera2iruntime:
Expand Down
6 changes: 6 additions & 0 deletions .github/labeler-pr-triage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1890,6 +1890,12 @@ service/s3outposts:
- any-glob-to-any-file:
- 'internal/service/s3outposts/**/*'
- 'website/**/s3outposts_*'
service/s3tables:
- any:
- changed-files:
- any-glob-to-any-file:
- 'internal/service/s3tables/**/*'
- 'website/**/s3tables_*'
service/sagemaker:
- any:
- changed-files:
Expand Down
1 change: 1 addition & 0 deletions .teamcity/components/generated/services_all.kt
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,7 @@ val services = mapOf(
"s3" to ServiceSpec("S3 (Simple Storage)"),
"s3control" to ServiceSpec("S3 Control"),
"s3outposts" to ServiceSpec("S3 on Outposts"),
"s3tables" to ServiceSpec("S3 Tables"),
"sagemaker" to ServiceSpec("SageMaker", vpcLock = true),
"scheduler" to ServiceSpec("EventBridge Scheduler"),
"schemas" to ServiceSpec("EventBridge Schemas"),
Expand Down
1 change: 1 addition & 0 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,7 @@ require (
github.com/aws/aws-sdk-go-v2/service/s3 v1.71.0
github.com/aws/aws-sdk-go-v2/service/s3control v1.52.0
github.com/aws/aws-sdk-go-v2/service/s3outposts v1.28.7
github.com/aws/aws-sdk-go-v2/service/s3tables v1.0.0
github.com/aws/aws-sdk-go-v2/service/sagemaker v1.168.1
github.com/aws/aws-sdk-go-v2/service/scheduler v1.12.7
github.com/aws/aws-sdk-go-v2/service/schemas v1.28.8
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -453,6 +453,8 @@ github.com/aws/aws-sdk-go-v2/service/s3control v1.52.0 h1:tH6HJdKj1O5N8Uti8D2X20
github.com/aws/aws-sdk-go-v2/service/s3control v1.52.0/go.mod h1:sAOVMYapLSs3nCfdQo63qfVkKHlu97oqHDPrRbqayNg=
github.com/aws/aws-sdk-go-v2/service/s3outposts v1.28.7 h1:yUuN4xIlI/2bUqniq5OdIw13FIGtUdPhzU4dzl2v6fM=
github.com/aws/aws-sdk-go-v2/service/s3outposts v1.28.7/go.mod h1:yCIumXPHLHsjmrD8P9UvXFVT0R9R+Wlqut71bW5+ZY4=
github.com/aws/aws-sdk-go-v2/service/s3tables v1.0.0 h1:akXaBXvSIT3ca7Ojnc1TX+2pTK6lhyodZTYTrdUD6Vc=
github.com/aws/aws-sdk-go-v2/service/s3tables v1.0.0/go.mod h1:X85zeZUOEsqLnH/CShIydM9ANVMwXHL1A/pvTMSQw6U=
github.com/aws/aws-sdk-go-v2/service/sagemaker v1.168.1 h1:Sz0HMK2/8itHAb9ABnMOEHfpOAIxk2a+f6EMsw7jn54=
github.com/aws/aws-sdk-go-v2/service/sagemaker v1.168.1/go.mod h1:LoIh7abCP1rQng1kxJVJOTux55TaYN2tVN7G+zNbhus=
github.com/aws/aws-sdk-go-v2/service/scheduler v1.12.7 h1:lRA+BvESWVoldCxaw3SG9UssITkVref8rlVy5xCsh0A=
Expand Down
1 change: 1 addition & 0 deletions infrastructure/repository/labels-service.tf
Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,7 @@ variable "service_labels" {
"s3",
"s3control",
"s3outposts",
"s3tables",
"sagemaker",
"sagemakera2iruntime",
"sagemakeredge",
Expand Down
10 changes: 10 additions & 0 deletions internal/acctest/knownvalue/stringable_value.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// Copyright (c) HashiCorp, Inc.
// SPDX-License-Identifier: MPL-2.0

package statecheck

import "github.com/hashicorp/terraform-plugin-testing/knownvalue"

func StringExact[T ~string](value T) knownvalue.Check {
return knownvalue.StringExact(string(value))
}
5 changes: 5 additions & 0 deletions internal/conns/awsclient_gen.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 51769a8

Please sign in to comment.