Skip to content

Commit

Permalink
add data catalog tag (#3569) (#2144)
Browse files Browse the repository at this point in the history
* add data catalog tag

* add data catalog tag

* fix missing err check

* update after review comments

* fixing a bad diff

* update per code review comments

* update fields values to camel case in ruby

Signed-off-by: Modular Magician <[email protected]>
  • Loading branch information
modular-magician authored Jun 8, 2020
1 parent c33d9da commit 1e8a142
Show file tree
Hide file tree
Showing 13 changed files with 1,698 additions and 17 deletions.
3 changes: 3 additions & 0 deletions .changelog/3569.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:new-resource
`data_catalog_tag`
```
5 changes: 3 additions & 2 deletions google-beta/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -654,9 +654,9 @@ func Provider() terraform.ResourceProvider {
return provider
}

// Generated resources: 161
// Generated resources: 162
// Generated IAM resources: 66
// Total generated resources: 227
// Total generated resources: 228
func ResourceMap() map[string]*schema.Resource {
resourceMap, _ := ResourceMapWithErrors()
return resourceMap
Expand Down Expand Up @@ -778,6 +778,7 @@ func ResourceMapWithErrors() (map[string]*schema.Resource, error) {
"google_data_catalog_entry_group_iam_policy": ResourceIamPolicy(DataCatalogEntryGroupIamSchema, DataCatalogEntryGroupIamUpdaterProducer, DataCatalogEntryGroupIdParseFunc),
"google_data_catalog_entry": resourceDataCatalogEntry(),
"google_data_catalog_tag_template": resourceDataCatalogTagTemplate(),
"google_data_catalog_tag": resourceDataCatalogTag(),
"google_data_fusion_instance": resourceDataFusionInstance(),
"google_dataproc_autoscaling_policy": resourceDataprocAutoscalingPolicy(),
"google_datastore_index": resourceDatastoreIndex(),
Expand Down
7 changes: 5 additions & 2 deletions google-beta/resource_app_engine_flexible_app_version.go
Original file line number Diff line number Diff line change
Expand Up @@ -3073,13 +3073,16 @@ func expandAppEngineFlexibleAppVersionDeploymentFiles(v interface{}, d Terraform
transformedSha1Sum, err := expandAppEngineFlexibleAppVersionDeploymentFilesSha1Sum(original["sha1_sum"], d, config)
if err != nil {
return nil, err
} else if val := reflect.ValueOf(transformedSha1Sum); val.IsValid() && !isEmptyValue(val) {
transformed["sha1Sum"] = transformedSha1Sum
}
transformed["sha1Sum"] = transformedSha1Sum

transformedSourceUrl, err := expandAppEngineFlexibleAppVersionDeploymentFilesSourceUrl(original["source_url"], d, config)
if err != nil {
return nil, err
} else if val := reflect.ValueOf(transformedSourceUrl); val.IsValid() && !isEmptyValue(val) {
transformed["sourceUrl"] = transformedSourceUrl
}
transformed["sourceUrl"] = transformedSourceUrl

transformedName, err := expandString(original["name"], d, config)
if err != nil {
Expand Down
7 changes: 5 additions & 2 deletions google-beta/resource_app_engine_standard_app_version.go
Original file line number Diff line number Diff line change
Expand Up @@ -1556,13 +1556,16 @@ func expandAppEngineStandardAppVersionDeploymentFiles(v interface{}, d Terraform
transformedSha1Sum, err := expandAppEngineStandardAppVersionDeploymentFilesSha1Sum(original["sha1_sum"], d, config)
if err != nil {
return nil, err
} else if val := reflect.ValueOf(transformedSha1Sum); val.IsValid() && !isEmptyValue(val) {
transformed["sha1Sum"] = transformedSha1Sum
}
transformed["sha1Sum"] = transformedSha1Sum

transformedSourceUrl, err := expandAppEngineStandardAppVersionDeploymentFilesSourceUrl(original["source_url"], d, config)
if err != nil {
return nil, err
} else if val := reflect.ValueOf(transformedSourceUrl); val.IsValid() && !isEmptyValue(val) {
transformed["sourceUrl"] = transformedSourceUrl
}
transformed["sourceUrl"] = transformedSourceUrl

transformedName, err := expandString(original["name"], d, config)
if err != nil {
Expand Down
11 changes: 8 additions & 3 deletions google-beta/resource_binary_authorization_policy.go
Original file line number Diff line number Diff line change
Expand Up @@ -561,18 +561,23 @@ func expandBinaryAuthorizationPolicyClusterAdmissionRules(v interface{}, d Terra
transformedEvaluationMode, err := expandBinaryAuthorizationPolicyClusterAdmissionRulesEvaluationMode(original["evaluation_mode"], d, config)
if err != nil {
return nil, err
} else if val := reflect.ValueOf(transformedEvaluationMode); val.IsValid() && !isEmptyValue(val) {
transformed["evaluationMode"] = transformedEvaluationMode
}
transformed["evaluationMode"] = transformedEvaluationMode

transformedRequireAttestationsBy, err := expandBinaryAuthorizationPolicyClusterAdmissionRulesRequireAttestationsBy(original["require_attestations_by"], d, config)
if err != nil {
return nil, err
} else if val := reflect.ValueOf(transformedRequireAttestationsBy); val.IsValid() && !isEmptyValue(val) {
transformed["requireAttestationsBy"] = transformedRequireAttestationsBy
}
transformed["requireAttestationsBy"] = transformedRequireAttestationsBy

transformedEnforcementMode, err := expandBinaryAuthorizationPolicyClusterAdmissionRulesEnforcementMode(original["enforcement_mode"], d, config)
if err != nil {
return nil, err
} else if val := reflect.ValueOf(transformedEnforcementMode); val.IsValid() && !isEmptyValue(val) {
transformed["enforcementMode"] = transformedEnforcementMode
}
transformed["enforcementMode"] = transformedEnforcementMode

transformedCluster, err := expandString(original["cluster"], d, config)
if err != nil {
Expand Down
Loading

0 comments on commit 1e8a142

Please sign in to comment.