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

Bug(docs): armconnectedvmware docs example reference a non existing client #22158

Open
erezrokah opened this issue Dec 18, 2023 · 14 comments
Open
Assignees
Labels
Connected Kubernetes customer-reported Issues that are reported by GitHub users external to the Azure organization. Mgmt This issue is related to a management-plane library. needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team question The issue doesn't require a change to the product in order to be resolved. Most issues start as that Service Attention Workflow: This issue is responsible by Azure service team.

Comments

@erezrokah
Copy link
Contributor

erezrokah commented Dec 18, 2023

Bug Report

v1.0.0 of this package removed NewVirtualMachinesClient, see https://github.com/Azure/azure-sdk-for-go/blob/2621632e48ea508e16ce568001402f92fca4afa0/sdk/resourcemanager/connectedvmware/armconnectedvmware/CHANGELOG.md#100-2023-10-27

However it's still referenced from the docs https://github.com/Azure/azure-sdk-for-go/tree/2621632e48ea508e16ce568001402f92fca4afa0/sdk/resourcemanager/connectedvmware/armconnectedvmware#clients

@github-actions github-actions bot added customer-reported Issues that are reported by GitHub users external to the Azure organization. needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that labels Dec 18, 2023
@lirenhe lirenhe added the Mgmt This issue is related to a management-plane library. label Dec 19, 2023
@github-actions github-actions bot removed the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label Dec 19, 2023
@Alancere
Copy link
Contributor

Hi @erezrokah thanks for this issue! .
You can check the information of the new version on CHANGELOG. I have submitted PR to fix doc.

@erezrokah
Copy link
Contributor Author

Thanks @erezrokah I can see it was removed, I'm just not sure what replaced it. It's still available in the REST API and the old version of the Go SDK that has it still works

@Alancere
Copy link
Contributor

The sdk/resourcemanager/connectedvmware/armconnectedvmware/v1.0.0 generated is dependent on the swagger

@Alancere Alancere added the needs-author-feedback Workflow: More information is needed from author to address the issue. label Dec 21, 2023
Copy link

Hi @erezrokah. Thank you for opening this issue and giving us the opportunity to assist. To help our team better understand your issue and the details of your scenario please provide a response to the question asked above or the information requested above. This will help us more accurately address your issue.

@erezrokah
Copy link
Contributor Author

The sdk/resourcemanager/connectedvmware/armconnectedvmware/v1.0.0 generated is dependent on the swagger

Thank you for the response. Can we you advise how can someone use the Go SDK to retrieve the data from https://learn.microsoft.com/en-us/azure/templates/microsoft.connectedvmwarevsphere/2022-01-10-preview/virtualmachines?pivots=deployment-language-arm-template?

What should we use instead of NewVirtualMachinesClient?

@github-actions github-actions bot added needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team and removed needs-author-feedback Workflow: More information is needed from author to address the issue. labels Dec 21, 2023
@Alancere
Copy link
Contributor

The sdk/resourcemanager/connectedvmware/armconnectedvmware/v1.0.0 generated is dependent on the swagger

Thank you for the response. Can we you advise how can someone use the Go SDK to retrieve the data from https://learn.microsoft.com/en-us/azure/templates/microsoft.connectedvmwarevsphere/2022-01-10-preview/virtualmachines?pivots=deployment-language-arm-template?

What should we use instead of NewVirtualMachinesClient?

Service Team Answer: the VIrtualMachine resource has been removed from the latest swagger due to resource modelling change. VirtualMachineInstance is the newly added resource type for this: https://github.com/Azure/azure-rest-api-specs/blob/main/specification/connectedvmware/resource-manager/Microsoft.ConnectedVMwarevSphere/stable/2023-10-01/connectedvmware.json#L2623

You could try NewVirtualMachineInstancesClient

@erezrokah
Copy link
Contributor Author

You could try NewVirtualMachineInstancesClient

I'm trying to use this one but looking at the example looks like I need to pass a VM resource ID:

pager := clientFactory.NewVirtualMachineInstancesClient().NewListPager("subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.HybridCompute/machines/DemoVM", nil)

How can I list the VMs and get the IDs to list the instances?

@Alancere
Copy link
Contributor

You could try NewVirtualMachineInstancesClient

I'm trying to use this one but looking at the example looks like I need to pass a VM resource ID:

pager := clientFactory.NewVirtualMachineInstancesClient().NewListPager("subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.HybridCompute/machines/DemoVM", nil)

How can I list the VMs and get the IDs to list the instances?

You could use "subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg/providers/Microsoft.HybridCompute/machines/DemoVM" replace "subscriptions/fd3c3665-1729-4b7b-9a38-238e83b0f98b/resourceGroups/testrg" try

@erezrokah
Copy link
Contributor Author

erezrokah commented Dec 22, 2023

Passing scope := "subscriptions/****/resourceGroups/****/providers/Microsoft.HybridCompute/machines" I get

GET https://management.azure.com/subscriptions/****/resourceGroups/****/providers/Microsoft.HybridCompute/machines/providers/Microsoft.ConnectedVMwarevSphere/virtualMachineInstances

The Resource 'Microsoft.HybridCompute/machines/providers' under resource group '****' was not found. For more details please go to https://aka.ms/ARMResourceNotFoundFix

Passing scope := "subscriptions/****/resourceGroups/****" I get

GET https://management.azure.com/subscriptions/****/resourceGroups/****/providers/Microsoft.ConnectedVMwarevSphere/virtualMachineInstances

Resource type 'virtualmachineinstances' of provider namespace 'Microsoft.ConnectedVMwarevSphere' was not found in global location for api version '2023-10-01'

Which one should I use and are the errors expected?

@Alancere Alancere added Service Attention Workflow: This issue is responsible by Azure service team. Connected Kubernetes labels Dec 25, 2023
Copy link

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @akashkeshari.

@erezrokah
Copy link
Contributor Author

erezrokah commented Jan 15, 2024

Hi 👋 When are we expected to receive an update on the issue?

@Alancere
Copy link
Contributor

I found that virtualmachineinstances already exist on azure portal. Please try again.
image

@Alancere Alancere added the needs-author-feedback Workflow: More information is needed from author to address the issue. label Jan 22, 2024
@github-actions github-actions bot removed the needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team label Jan 22, 2024
Copy link

Hi @erezrokah. Thank you for opening this issue and giving us the opportunity to assist. To help our team better understand your issue and the details of your scenario please provide a response to the question asked above or the information requested above. This will help us more accurately address your issue.

@erezrokah
Copy link
Contributor Author

I found that virtualmachineinstances already exist on azure portal. Please try again.

Hi @Alancere which scope from #22158 (comment) is expected to work?

@github-actions github-actions bot added needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team and removed needs-author-feedback Workflow: More information is needed from author to address the issue. labels Jan 22, 2024
@lirenhe lirenhe assigned Mitse1n and unassigned Alancere Sep 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Connected Kubernetes customer-reported Issues that are reported by GitHub users external to the Azure organization. Mgmt This issue is related to a management-plane library. needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team question The issue doesn't require a change to the product in order to be resolved. Most issues start as that Service Attention Workflow: This issue is responsible by Azure service team.
Projects
None yet
Development

No branches or pull requests

4 participants