Skip to content

Commit 11d228f

Browse files
Add support for description to tag template fields (#8810) (#4650) (#8851)
Co-authored-by: Geir Sagberg <[email protected]> Signed-off-by: Modular Magician <[email protected]> Co-authored-by: Geir Sagberg <[email protected]>
1 parent 0e036bd commit 11d228f

File tree

4 files changed

+13
-7
lines changed

4 files changed

+13
-7
lines changed

.changelog/4650.txt

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
```release-note:enhancement
2+
datacatalog: added `description` field to `google_data_catalog_tag_template ` resource
3+
```

google/resource_data_catalog_tag_template.go

+6-6
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,11 @@ Can have up to 500 allowed values.`,
9696
},
9797
},
9898
},
99+
"description": {
100+
Type: schema.TypeString,
101+
Optional: true,
102+
Description: `A description for this field.`,
103+
},
99104
"display_name": {
100105
Type: schema.TypeString,
101106
Optional: true,
@@ -118,11 +123,6 @@ Multiple fields can have the same order, and field orders within a tag do not ha
118123
Computed: true,
119124
Description: `The resource name of the tag template field in URL format. Example: projects/{project_id}/locations/{location}/tagTemplates/{tagTemplateId}/fields/{field}`,
120125
},
121-
"description": {
122-
Type: schema.TypeString,
123-
Optional: true,
124-
Description: `A description for this field.`,
125-
},
126126
},
127127
},
128128
},
@@ -434,10 +434,10 @@ func flattenDataCatalogTagTemplateFields(v interface{}, d *schema.ResourceData,
434434
"field_id": k,
435435
"name": flattenDataCatalogTagTemplateFieldsName(original["name"], d, config),
436436
"display_name": flattenDataCatalogTagTemplateFieldsDisplayName(original["displayName"], d, config),
437+
"description": flattenDataCatalogTagTemplateFieldsDescription(original["description"], d, config),
437438
"type": flattenDataCatalogTagTemplateFieldsType(original["type"], d, config),
438439
"is_required": flattenDataCatalogTagTemplateFieldsIsRequired(original["isRequired"], d, config),
439440
"order": flattenDataCatalogTagTemplateFieldsOrder(original["order"], d, config),
440-
"description": flattenDataCatalogTagTemplateFieldsDescription(original["description"], d, config),
441441
})
442442
}
443443
return transformed

google/resource_data_catalog_tag_test.go

-1
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,6 @@ resource "google_data_catalog_tag_template" "tag_template" {
7373
primitive_type = "STRING"
7474
}
7575
is_required = true
76-
description = "The source of the data asset"
7776
}
7877
7978
fields {

website/docs/r/data_catalog_tag_template.html.markdown

+4
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,10 @@ The `fields` block supports:
111111
(Optional)
112112
The display name for this field.
113113

114+
* `description` -
115+
(Optional)
116+
A description for this field.
117+
114118
* `type` -
115119
(Required)
116120
The type of value this tag field can contain.

0 commit comments

Comments
 (0)