Open zbuchheit opened 1 week ago
@zbuchheit Do you know if the customer is interested in disabling this globally, or for specific fields or resources.
If they want to disable all type aware case manipulation, I think they can do this:
tfbridge.MustTraverseProperties(&prov, "disable-type-aware-naming",
func(info tfbridge.PropertyVisitInfo) (tfbridge.PropertyVisitResult, error) {
p := info.SchemaPath()
step, ok := p[len(p)-1].(walk.GetAttrStep)
if !ok {
return tfbridge.PropertyVisitResult{}, nil
}
sInfo := info.SchemaInfo()
if sInfo.Name != "" {
return tfbridge.PropertyVisitResult{}, nil
}
sInfo.Name = tfbridge.TerraformToPulumiNameV2(step.Name, nil, nil)
return tfbridge.PropertyVisitResult{HasEffect: true}, nil
})
I believe they would be interested in disabling this globally, but mainly the interest right now is for specific fields/resources.
They tried the above, but ended up with bunch of overriding non-existent field
errors
Hello!
Issue details
Currently if I have an array property the bridge will singularize it. It would be nice to be able to opt out of that functionality.
For example, if I have a field like
ConfigValuesArgs
array it would be converted toConfigValueArgs
Affected area/feature
TF Bridge