Skip to content

Use lineage instead of api_name for property conflicts#3885

Merged
c2thorn merged 1 commit intoGoogleCloudPlatform:masterfrom
c2thorn:url_map_conflicts
Aug 19, 2020
Merged

Use lineage instead of api_name for property conflicts#3885
c2thorn merged 1 commit intoGoogleCloudPlatform:masterfrom
c2thorn:url_map_conflicts

Conversation

@c2thorn
Copy link
Copy Markdown
Member

@c2thorn c2thorn commented Aug 19, 2020

Fixes hashicorp/terraform-provider-google#6967

Within google_compute_url_map, both default_url_redirect and path_matcher.default_url_redirect exist, as well as default_route_action and path_matcher.default_route_action. default_url_redirect is set to conflict with default_route_action, but the path_matcher subfields are not intended to conflict with anything.

The logic to generate ConflictsWith used api_name which does not differentiate between the two versions of each field, causing the path_matcher subfields to conflict with the top-level fields. Using lineage instead of api_name will remove these unintended conflicts.

If this PR is for Terraform, I acknowledge that I have:

  • Searched through the issue tracker for an open issue that this either resolves or contributes to, commented on it to claim it, and written "fixes {url}" or "part of {url}" in this PR description. If there were no relevant open issues, I opened one and commented that I would like to work on it (not necessary for very small changes).
  • Generated Terraform, and ran make test and make lint to ensure it passes unit and linter tests.
  • Ensured that all new fields I added that can be set by a user appear in at least one example (for generated resources) or third_party test (for handwritten resources or update tests).
  • Ran relevant acceptance tests (If the acceptance tests do not yet pass or you are unable to run them, please let your reviewer know).
  • Read the Release Notes Guide before writing my release note below.

Release Note Template for Downstream PRs (will be copied)

compute: fixed an issue where `google_compute_url_map` `path_matcher.default_route_action` would conflict with `default_url_redirect`

@google-cla google-cla bot added the cla: yes label Aug 19, 2020
@modular-magician
Copy link
Copy Markdown
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 1 file changed, 2 deletions(-))
Terraform Beta: Diff ( 1 file changed, 2 deletions(-))

@modular-magician
Copy link
Copy Markdown
Collaborator

I have triggered VCR tests based on this PR's diffs. See the results here: "https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=140954"

@modular-magician
Copy link
Copy Markdown
Collaborator

I have triggered VCR tests in RECORDING mode for the following tests that failed during VCR: TestAccDataSourceComputeInstanceSerialPort_basic|TestAccDataSourceComputeInstance_basic|TestAccActiveDirectoryDomain_activeDirectoryDomainBasicExample|TestAccActiveDirectoryDomainTrust_activeDirectoryDomainTrustBasicExample|TestAccComposerEnvironment_basic|TestAccComposerEnvironment_private|TestAccComposerEnvironment_update|TestAccComposerEnvironment_privateWithWebServerControl|TestAccComposerEnvironment_withUpdateOnCreate|TestAccComposerEnvironment_withSoftwareConfig|TestAccComputeAttachedDisk_count|TestAccComposerEnvironment_withNodeConfig|TestAccComputeBackendService_withMaxRatePerEndpoint|TestAccComputeBackendService_withMaxConnectionsPerEndpoint|TestAccComputeHealthCheck_healthCheckGrpcExample|TestAccComputeHealthCheck_healthCheckGrpcFullExample|TestAccComputeInstanceFromTemplate_basic|TestAccComputeRegionDisk_deleteDetach|TestAccComputeRegionHealthCheck_regionHealthCheckGrpcExample|TestAccComputeRegionHealthCheck_regionHealthCheckGrpcFullExample|TestAccRegionInstanceGroupManager_basic|TestAccComputeVpnGateway_targetVpnGatewayBasicExample|TestAccComputeVpnTunnel_vpnTunnelBasicExample|TestAccComputeVpnTunnel_vpnTunnelBetaExample|TestAccComputeVpnTunnel_router|TestAccComputeVpnTunnel_defaultTrafficSelectors|TestAccContainerCluster_withNodePoolNodeConfig|TestAccContainerCluster_nodeAutoprovisioning|TestAccContainerNodePool_withWorkloadIdentityConfig|TestAccMemcacheInstance_update|TestAccMemcacheInstance_memcacheInstanceBasicExample|TestAccNetworkManagementConnectivityTest_networkManagementConnectivityTestInstancesExample|TestAccNetworkManagementConnectivityTest_networkManagementConnectivityTestAddressesExample|TestAccNetworkManagementConnectivityTest_update You can view the result here: "https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=140956"

@c2thorn c2thorn requested a review from nat-henderson August 19, 2020 15:55
Copy link
Copy Markdown
Contributor

@nat-henderson nat-henderson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ooh, lineage. Fun name. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Path matcher default_route_action conflicts with default_url_redirect

3 participants