CloudServicesOperations Class

CloudServicesOperations async operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Inheritance
builtins.object
CloudServicesOperations

Constructor

CloudServicesOperations(client, config, serializer, deserializer)

Parameters

client
Required

Client for service requests.

config
Required

Configuration of service client.

serializer
Required

An object model serializer.

deserializer
Required

An object model deserializer.

Variables

models

Alias to model classes used in this operation group.

Methods

begin_create_or_update

Create or update a cloud service. Please note some properties can be set only during cloud service creation.

begin_delete

Deletes a cloud service.

begin_delete_instances

Deletes role instances in a cloud service.

begin_power_off

Power off the cloud service. Note that resources are still attached and you are getting charged for the resources.

begin_rebuild

Rebuild Role Instances reinstalls the operating system on instances of web roles or worker roles and initializes the storage resources that are used by them. If you do not want to initialize storage resources, you can use Reimage Role Instances.

begin_reimage

Reimage asynchronous operation reinstalls the operating system on instances of web roles or worker roles.

begin_restart

Restarts one or more role instances in a cloud service.

begin_start

Starts the cloud service.

begin_update

Update a cloud service.

get

Display information about a cloud service.

get_instance_view

Gets the status of a cloud service.

list

Gets a list of all cloud services under a resource group. Use nextLink property in the response to get the next page of Cloud Services. Do this till nextLink is null to fetch all the Cloud Services.

list_all

Gets a list of all cloud services in the subscription, regardless of the associated resource group. Use nextLink property in the response to get the next page of Cloud Services. Do this till nextLink is null to fetch all the Cloud Services.

begin_create_or_update

Create or update a cloud service. Please note some properties can be set only during cloud service creation.

async begin_create_or_update(resource_group_name: str, cloud_service_name: str, parameters: Optional[azure.mgmt.compute.v2020_10_01_preview.models._models_py3.CloudService] = None, **kwargs: Any) -> azure.core.polling._async_poller.AsyncLROPoller[azure.mgmt.compute.v2020_10_01_preview.models._models_py3.CloudService]

Parameters

resource_group_name
str
Required

Name of the resource group.

cloud_service_name
str
Required

Name of the cloud service.

parameters
CloudService
default value: None

The cloud service object.

cls
callable

A custom type or function that will be passed the direct response

continuation_token
str

A continuation token to restart a poller from a saved state.

polling
bool or AsyncPollingMethod

By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.

polling_interval
int

Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of AsyncLROPoller that returns either CloudService or the result of cls(response)

Return type

Exceptions

begin_delete

Deletes a cloud service.

async begin_delete(resource_group_name: str, cloud_service_name: str, **kwargs: Any) -> azure.core.polling._async_poller.AsyncLROPoller[None]

Parameters

resource_group_name
str
Required

Name of the resource group.

cloud_service_name
str
Required

Name of the cloud service.

cls
callable

A custom type or function that will be passed the direct response

continuation_token
str

A continuation token to restart a poller from a saved state.

polling
bool or AsyncPollingMethod

By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.

polling_interval
int

Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

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

Return type

Exceptions

begin_delete_instances

Deletes role instances in a cloud service.

async begin_delete_instances(resource_group_name: str, cloud_service_name: str, parameters: Optional[azure.mgmt.compute.v2020_10_01_preview.models._models_py3.RoleInstances] = None, **kwargs: Any) -> azure.core.polling._async_poller.AsyncLROPoller[None]

Parameters

resource_group_name
str
Required

Name of the resource group.

cloud_service_name
str
Required

Name of the cloud service.

parameters
RoleInstances
default value: None

List of cloud service role instance names.

cls
callable

A custom type or function that will be passed the direct response

continuation_token
str

A continuation token to restart a poller from a saved state.

polling
bool or AsyncPollingMethod

By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.

polling_interval
int

Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

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

Return type

Exceptions

begin_power_off

Power off the cloud service. Note that resources are still attached and you are getting charged for the resources.

async begin_power_off(resource_group_name: str, cloud_service_name: str, **kwargs: Any) -> azure.core.polling._async_poller.AsyncLROPoller[None]

Parameters

resource_group_name
str
Required

Name of the resource group.

cloud_service_name
str
Required

Name of the cloud service.

cls
callable

A custom type or function that will be passed the direct response

continuation_token
str

A continuation token to restart a poller from a saved state.

polling
bool or AsyncPollingMethod

By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.

polling_interval
int

Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

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

Return type

Exceptions

begin_rebuild

Rebuild Role Instances reinstalls the operating system on instances of web roles or worker roles and initializes the storage resources that are used by them. If you do not want to initialize storage resources, you can use Reimage Role Instances.

async begin_rebuild(resource_group_name: str, cloud_service_name: str, parameters: Optional[azure.mgmt.compute.v2020_10_01_preview.models._models_py3.RoleInstances] = None, **kwargs: Any) -> azure.core.polling._async_poller.AsyncLROPoller[None]

Parameters

resource_group_name
str
Required

Name of the resource group.

cloud_service_name
str
Required

Name of the cloud service.

parameters
RoleInstances
default value: None

List of cloud service role instance names.

cls
callable

A custom type or function that will be passed the direct response

continuation_token
str

A continuation token to restart a poller from a saved state.

polling
bool or AsyncPollingMethod

By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.

polling_interval
int

Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

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

Return type

Exceptions

begin_reimage

Reimage asynchronous operation reinstalls the operating system on instances of web roles or worker roles.

async begin_reimage(resource_group_name: str, cloud_service_name: str, parameters: Optional[azure.mgmt.compute.v2020_10_01_preview.models._models_py3.RoleInstances] = None, **kwargs: Any) -> azure.core.polling._async_poller.AsyncLROPoller[None]

Parameters

resource_group_name
str
Required

Name of the resource group.

cloud_service_name
str
Required

Name of the cloud service.

parameters
RoleInstances
default value: None

List of cloud service role instance names.

cls
callable

A custom type or function that will be passed the direct response

continuation_token
str

A continuation token to restart a poller from a saved state.

polling
bool or AsyncPollingMethod

By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.

polling_interval
int

Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

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

Return type

Exceptions

begin_restart

Restarts one or more role instances in a cloud service.

async begin_restart(resource_group_name: str, cloud_service_name: str, parameters: Optional[azure.mgmt.compute.v2020_10_01_preview.models._models_py3.RoleInstances] = None, **kwargs: Any) -> azure.core.polling._async_poller.AsyncLROPoller[None]

Parameters

resource_group_name
str
Required

Name of the resource group.

cloud_service_name
str
Required

Name of the cloud service.

parameters
RoleInstances
default value: None

List of cloud service role instance names.

cls
callable

A custom type or function that will be passed the direct response

continuation_token
str

A continuation token to restart a poller from a saved state.

polling
bool or AsyncPollingMethod

By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.

polling_interval
int

Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

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

Return type

Exceptions

begin_start

Starts the cloud service.

async begin_start(resource_group_name: str, cloud_service_name: str, **kwargs: Any) -> azure.core.polling._async_poller.AsyncLROPoller[None]

Parameters

resource_group_name
str
Required

Name of the resource group.

cloud_service_name
str
Required

Name of the cloud service.

cls
callable

A custom type or function that will be passed the direct response

continuation_token
str

A continuation token to restart a poller from a saved state.

polling
bool or AsyncPollingMethod

By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.

polling_interval
int

Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

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

Return type

Exceptions

begin_update

Update a cloud service.

async begin_update(resource_group_name: str, cloud_service_name: str, parameters: Optional[azure.mgmt.compute.v2020_10_01_preview.models._models_py3.CloudServiceUpdate] = None, **kwargs: Any) -> azure.core.polling._async_poller.AsyncLROPoller[azure.mgmt.compute.v2020_10_01_preview.models._models_py3.CloudService]

Parameters

resource_group_name
str
Required

Name of the resource group.

cloud_service_name
str
Required

Name of the cloud service.

parameters
CloudServiceUpdate
default value: None

The cloud service object.

cls
callable

A custom type or function that will be passed the direct response

continuation_token
str

A continuation token to restart a poller from a saved state.

polling
bool or AsyncPollingMethod

By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.

polling_interval
int

Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of AsyncLROPoller that returns either CloudService or the result of cls(response)

Return type

Exceptions

get

Display information about a cloud service.

async get(resource_group_name: str, cloud_service_name: str, **kwargs: Any) -> azure.mgmt.compute.v2020_10_01_preview.models._models_py3.CloudService

Parameters

resource_group_name
str
Required

Name of the resource group.

cloud_service_name
str
Required

Name of the cloud service.

cls
callable

A custom type or function that will be passed the direct response

Returns

CloudService, or the result of cls(response)

Return type

Exceptions

get_instance_view

Gets the status of a cloud service.

async get_instance_view(resource_group_name: str, cloud_service_name: str, **kwargs: Any) -> azure.mgmt.compute.v2020_10_01_preview.models._models_py3.CloudServiceInstanceView

Parameters

resource_group_name
str
Required

Name of the resource group.

cloud_service_name
str
Required

Name of the cloud service.

cls
callable

A custom type or function that will be passed the direct response

Returns

CloudServiceInstanceView, or the result of cls(response)

Return type

Exceptions

list

Gets a list of all cloud services under a resource group. Use nextLink property in the response to get the next page of Cloud Services. Do this till nextLink is null to fetch all the Cloud Services.

list(resource_group_name: str, **kwargs: Any) -> AsyncIterable[azure.mgmt.compute.v2020_10_01_preview.models._models_py3.CloudServiceListResult]

Parameters

resource_group_name
str
Required

Name of the resource group.

cls
callable

A custom type or function that will be passed the direct response

Returns

An iterator like instance of either CloudServiceListResult or the result of cls(response)

Return type

Exceptions

list_all

Gets a list of all cloud services in the subscription, regardless of the associated resource group. Use nextLink property in the response to get the next page of Cloud Services. Do this till nextLink is null to fetch all the Cloud Services.

list_all(**kwargs: Any) -> AsyncIterable[azure.mgmt.compute.v2020_10_01_preview.models._models_py3.CloudServiceListResult]

Parameters

cls
callable

A custom type or function that will be passed the direct response

Returns

An iterator like instance of either CloudServiceListResult or the result of cls(response)

Return type

Exceptions

Attributes

models

models = <module 'azure.mgmt.compute.v2020_10_01_preview.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.9.13\\x64\\lib\\site-packages\\azure\\mgmt\\compute\\v2020_10_01_preview\\models\\__init__.py'>