SWP: Add support for value "EXPLICIT_ROUTING_MODE" on field "routing_mode" on resource "google_network_services_gateway" #19826
Labels
enhancement
forward/review
In review; remove label to forward
service/networkservices-traffic-director
Community Note
Description
Important
This field is working on Beta and GA, but the API docs was not updated yet.
The Gateway API currently says that this new field
routingMode
supports two values:NEXT_HOP_ROUTING_MODE
andEXPLICIT_ROUTING_MODE
During the development of this new fiel on this PR we noticied that the Gateway API doesn't return the value of this new field when the value is
EXPLICIT_ROUTING_MODE
(this field only return when the value isNEXT_HOP_ROUTING_MODE
)Because of this API behavior the value
EXPLICIT_ROUTING_MODE
was removed from the Terraform Enum field.Even though the API says the field is required when
type = "SECURE WEB GATEWAY"
it accepts empty and set the valueEXPLICIT_ROUTING_MODE
, which apparently is the default.We needed to remove the value from provider to make the resource work but we should add once the API changes.
Since the API says that this field is required when the gateway is SWP, it's good to have this value on the Terraform Enum and returning on the API (at least when the type is secure web proxy)
New or Affected Resource(s)
Potential Terraform Configuration
terraform-provider-google/google/services/networkservices/resource_network_services_gateway_test.go
Line 945 in 5edbe43
Terraform code:
Terraform output:
See:
"routing_mode": ""
References
https://cloud.google.com/secure-web-proxy/docs/deploy-next-hop
The text was updated successfully, but these errors were encountered: