Skip to content
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

[DOC] databricks_mws_network_connectivity_config wrong resource attribute syntax #3592

Open
2 tasks
camilo-s opened this issue May 17, 2024 · 0 comments
Open
2 tasks
Labels
docs add explicit documentation about corner case

Comments

@camilo-s
Copy link

camilo-s commented May 17, 2024

Affected Resource(s)

According to the documentation, subnet configuration of an NCC resource is accessed through default_rules.azure_service_endpoint_rule.

However, these attributes are accessed through the egress_config attribute, which is strangely nested in lists. This is how the whole databricks_mws_network_connectivity_config object looks like:

ncc = {
  "account_id" = "***"
  "creation_time" = 1715951855859
  "egress_config" = tolist([
    {
      "default_rules" = tolist([
        {
          "aws_stable_ip_rule" = tolist([])
          "azure_service_endpoint_rule" = tolist([
            {
              "subnets" = tolist([
                "/subscriptions/<REDACTED>/resourceGroups/prod-westeurope-snp-1-compute-2/providers/Microsoft.Network/virtualNetworks/kaas-vnet/subnets/worker-subnet",
                "/subscriptions/<REDACTED>/resourceGroups/prod-westeurope-snp-1-compute-3/providers/Microsoft.Network/virtualNetworks/kaas-vnet/subnets/worker-subnet",
                "/subscriptions/<REDACTED>/resourceGroups/prod-westeurope-snp-1-compute-4/providers/Microsoft.Network/virtualNetworks/kaas-vnet/subnets/worker-subnet",
                "/subscriptions/<REDACTED>/resourceGroups/prod-azure-westeurope-nephos5/providers/Microsoft.Network/virtualNetworks/kaas-vnet/subnets/worker-subnet",
                "/subscriptions/<REDACTED>/resourceGroups/prod-azure-westeurope-nephos6/providers/Microsoft.Network/virtualNetworks/kaas-vnet/subnets/worker-subnet",
                "/subscriptions/<REDACTED>/resourceGroups/prod-azure-westeuropec2-nephos4/providers/Microsoft.Network/virtualNetworks/kaas-vnet/subnets/worker-subnet",
                "/subscriptions/<REDACTED>/resourceGroups/prod-azure-westeuropec2-nephos5/providers/Microsoft.Network/virtualNetworks/kaas-vnet/subnets/worker-subnet",
                "/subscriptions/<REDACTED>/resourceGroups/prod-azure-westeuropec2-nephos6/providers/Microsoft.Network/virtualNetworks/kaas-vnet/subnets/worker-subnet",
                "/subscriptions/<REDACTED>/resourceGroups/prod-westeurope-snp-1-compute-1/providers/Microsoft.Network/virtualNetworks/kaas-vnet/subnets/worker-subnet",
                "/subscriptions/<REDACTED>/resourceGroups/prod-westeurope-snp-1-compute-9/providers/Microsoft.Network/virtualNetworks/kaas-vnet/subnets/worker-subnet",
              ])
              "target_region" = "westeurope"
              "target_services" = tolist([
                "AZURE_BLOB_STORAGE",
              ])
            },
          ])
        },
      ])
      "target_rules" = tolist([])
    },
  ])
  "id" = "***/<REDACTED>"
  "name" = "ncc-storage-firewall"
  "network_connectivity_config_id" = "<REDACTED>"
  "region" = "westeurope"
  "updated_time" = 1715951855859
}

Expected Details

The section should describe the schema of the object, so one can figure how any necessary attribute should be access. For instance, to reach the list of subnets ids associated with the NCC, you currently need this path: databricks_mws_network_connectivity_config.this.egress_config[0].default_rules[0].azure_service_endpoint_rule[0].subnets

List of things to potentially add/remove

This is a list of things to manipulate in the docs:

  • Describe the attributes schema in detail
  • Ideally fix the issue upstream, so that the databricks_mws_network_connectivity_config object's schema directly follows the corresponding REST endpoint response's schema.

Important Factoids

References

@camilo-s camilo-s added the docs add explicit documentation about corner case label May 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs add explicit documentation about corner case
Projects
None yet
Development

No branches or pull requests

1 participant