VirtualMachinesOperations Class

Warning

DO NOT instantiate this class directly.

Instead, you should access the following operations through

HDInsightManagementClient's

<xref:virtual_machines> attribute.

Constructor

VirtualMachinesOperations(*args, **kwargs)

Methods

begin_restart_hosts

Restarts the specified HDInsight cluster hosts.

get_async_operation_status

Gets the async operation status.

list_hosts

Lists the HDInsight clusters hosts.

begin_restart_hosts

Restarts the specified HDInsight cluster hosts.

begin_restart_hosts(resource_group_name: str, cluster_name: str, hosts: List[str], *, content_type: str = 'application/json', **kwargs: Any) -> LROPoller[None]

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group. Required.

cluster_name
Required
str

The name of the cluster. Required.

hosts
Required
list[str] or IO[bytes]

The list of hosts to restart. Is either a [str] type or a IO[bytes] type. Required.

Returns

Type Description

An instance of LROPoller that returns either None or the result of cls(response)

Exceptions

Type Description

get_async_operation_status

Gets the async operation status.

get_async_operation_status(resource_group_name: str, cluster_name: str, operation_id: str, **kwargs: Any) -> AsyncOperationResult

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group. Required.

cluster_name
Required
str

The name of the cluster. Required.

operation_id
Required
str

The long running operation id. Required.

Returns

Type Description

AsyncOperationResult or the result of cls(response)

Exceptions

Type Description

list_hosts

Lists the HDInsight clusters hosts.

list_hosts(resource_group_name: str, cluster_name: str, **kwargs: Any) -> list[azure.mgmt.hdinsight.models._models_py3.HostInfo]

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group. Required.

cluster_name
Required
str

The name of the cluster. Required.

Returns

Type Description

list of HostInfo or the result of cls(response)

Exceptions

Type Description

Attributes

models

models = <module 'azure.mgmt.hdinsight.models' from 'C:\\ToolCache\\Python\\3.12.10\\x64\\Lib\\site-packages\\py2docfx\\venv\\venv145\\Lib\\site-packages\\azure\\mgmt\\hdinsight\\models\\__init__.py'>