Open
Description
Describe the bug
com.azure.resourcemanager.compute.models.VirtualMachines.list()
query returns deleted VM.
Fetching details using the returned VM object will result in ResourceNotFound
ApiErrorException
To Reproduce
- Manually create a VM from Azure Portal
- Query VirtualMachines using
com.azure.resourcemanager.compute.models.VirtualMachines.list()
- Delete VM from Azure Portal
- Query VirtualMachines using
com.azure.resourcemanager.compute.models.VirtualMachines.list()
with the same client - Find object of deleted VM instance from query result and retrieve powerState from found object to trigger
refreshInstanceView
- refreshInstanceView will trigger
ApiErrorException
with codeResourceNotFound