-
Notifications
You must be signed in to change notification settings - Fork 101
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Terraformer phase 2 updates #921
base: master
Are you sure you want to change the base?
Conversation
* Updated Read function in access_switch_policy_group * User security role update (#151) * Updated fabricNodeControl and userSecurityDomainRole * Updated user security domain * Updated Read Function for UI Deletion Test case (#152) * added set for annotation in ldap_group_map * Updated resources (#155) * aaep_to_domain resource file updated, dn changed and description removed (#156) * updated documentation * updated documentation for match_rule * resource_tagannotation updated (#159) * tag_resource schema updated * Updated Index file of Interface Blacklist * Updated Mgmt Zone (#162) * updated docs
@@ -24,12 +24,20 @@ func resourceAciContractInterfaceRelationship() *schema.Resource { | |||
}, | |||
|
|||
SchemaVersion: 1, | |||
Schema: AppendBaseAttrSchema(map[string]*schema.Schema{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we remove this function and add the annotation as separate entries to the Schema?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This Function appends description and annotation attribute to the respective resource schema. Some of the ACI classes doesn't support description but may support annotation, Hence addition of annotation separately.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you consider creating separate function for annotation only and re-use this? Also have a look at the AppendAttrSchemas function in https://github.com/CiscoDevNet/terraform-provider-aci/blob/master/aci/base_attr_schema.go, this could perhaps be leveraged.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added a GetAnnotation function for uniform schema implementation.
I see vendor file updated but not a new version of the aci-go-client. Was this already merged into go-client? |
@lhercot, Yes as it was a minor change, it is already merged to main branch |
aci/resource_aci_fabricrsoospath.go
Outdated
Schema: map[string]*schema.Schema{ | ||
"annotation": { | ||
Type: schema.TypeString, | ||
Optional: true, | ||
Computed: true, | ||
DefaultFunc: func() (interface{}, error) { | ||
return "orchestrator:terraform", nil | ||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same comment as Akini on other file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added a GetAnnotation function for uniform schema implementation.
aci/resource_aci_infrarsdomp.go
Outdated
"annotation": &schema.Schema{ | ||
Type: schema.TypeString, | ||
Optional: true, | ||
Computed: true, | ||
DefaultFunc: func() (interface{}, error) { | ||
return "orchestrator:terraform", nil | ||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same comment as Akini on other file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added a GetAnnotation function for uniform schema implementation.
Updated Read function in access_switch_policy_group
User security role update (CACIT-82 added datasource #151)
Updated fabricNodeControl and userSecurityDomainRole
Updated user security domain
Updated Read Function for UI Deletion Test case (tags/annotations cause error or don't get created #152)
added set for annotation in ldap_group_map
Updated resources (Resource for DHCP Relay Policy #155)
aaep_to_domain resource file updated, dn changed and description removed (Mapping of DHCP Relay Label into BD Resource #156)
updated documentation
updated documentation for match_rule
resource_tagannotation updated (Add name in subnet #159)
tag_resource schema updated
Updated Index file of Interface Blacklist
Updated Mgmt Zone (HOW-TO aci_contract with filter and filter entry? #162)
updated docs