ComputeNodeOperations Class
ComputeNodeOperations operations.
You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute.
- Inheritance
-
builtins.objectComputeNodeOperations
Constructor
ComputeNodeOperations(client, config, serializer, deserializer)
Parameters
Name | Description |
---|---|
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
Name | Description |
---|---|
api_version
|
The API version to use for the request. Constant value: "2024-02-01.19.0". |
Methods
add_user |
Adds a user Account to the specified Compute Node. You can add a user Account to a Compute Node only when it is in the idle or running state. |
delete_user |
Deletes a user Account from the specified Compute Node. You can delete a user Account to a Compute Node only when it is in the idle or running state. |
disable_scheduling |
Disables Task scheduling on the specified Compute Node. You can disable Task scheduling on a Compute Node only if its current scheduling state is enabled. |
enable_scheduling |
Enables Task scheduling on the specified Compute Node. You can enable Task scheduling on a Compute Node only if its current scheduling state is disabled. |
get |
Gets information about the specified Compute Node. |
get_remote_desktop |
Gets the Remote Desktop Protocol file for the specified Compute Node. Before you can access a Compute Node by using the RDP file, you must create a user Account on the Compute Node. This API can only be invoked on Pools created with a cloud service configuration. For Pools created with a virtual machine configuration, see the GetRemoteLoginSettings API. |
get_remote_login_settings |
Gets the settings required for remote login to a Compute Node. Before you can remotely login to a Compute Node using the remote login settings, you must create a user Account on the Compute Node. This API can be invoked only on Pools created with the virtual machine configuration property. For Pools created with a cloud service configuration, see the GetRemoteDesktop API. |
list |
Lists the Compute Nodes in the specified Pool. |
reboot |
Restarts the specified Compute Node. You can restart a Compute Node only if it is in an idle or running state. |
reimage |
Reinstalls the operating system on the specified Compute Node. You can reinstall the operating system on a Compute Node only if it is in an idle or running state. This API can be invoked only on Pools created with the cloud service configuration property. |
update_user |
Updates the password and expiration time of a user Account on the specified Compute Node. This operation replaces of all the updatable properties of the Account. For example, if the expiryTime element is not specified, the current value is replaced with the default value, not left unmodified. You can update a user Account on a Compute Node only when it is in the idle or running state. |
upload_batch_service_logs |
Upload Azure Batch service log files from the specified Compute Node to Azure Blob Storage. This is for gathering Azure Batch service log files in an automated fashion from Compute Nodes if you are experiencing an error and wish to escalate to Azure support. The Azure Batch service log files should be shared with Azure support to aid in debugging issues with the Batch service. |
add_user
Adds a user Account to the specified Compute Node.
You can add a user Account to a Compute Node only when it is in the idle or running state.
add_user(pool_id, node_id, user, compute_node_add_user_options=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
pool_id
Required
|
The ID of the Pool that contains the Compute Node. |
node_id
Required
|
The ID of the machine on which you want to create a user Account. |
user
Required
|
The user Account to be created. |
compute_node_add_user_options
|
Additional parameters for the operation Default value: None
|
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
None,
<xref:msrest.pipeline.ClientRawResponse>
|
None or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
delete_user
Deletes a user Account from the specified Compute Node.
You can delete a user Account to a Compute Node only when it is in the idle or running state.
delete_user(pool_id, node_id, user_name, compute_node_delete_user_options=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
pool_id
Required
|
The ID of the Pool that contains the Compute Node. |
node_id
Required
|
The ID of the machine on which you want to delete a user Account. |
user_name
Required
|
The name of the user Account to delete. |
compute_node_delete_user_options
|
Additional parameters for the operation Default value: None
|
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
None,
<xref:msrest.pipeline.ClientRawResponse>
|
None or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
disable_scheduling
Disables Task scheduling on the specified Compute Node.
You can disable Task scheduling on a Compute Node only if its current scheduling state is enabled.
disable_scheduling(pool_id, node_id, node_disable_scheduling_option=None, compute_node_disable_scheduling_options=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
pool_id
Required
|
The ID of the Pool that contains the Compute Node. |
node_id
Required
|
The ID of the Compute Node on which you want to disable Task scheduling. |
node_disable_scheduling_option
|
The default value is requeue. Possible values include: 'requeue', 'terminate', 'taskCompletion' Default value: None
|
compute_node_disable_scheduling_options
|
Additional parameters for the operation Default value: None
|
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
None,
<xref:msrest.pipeline.ClientRawResponse>
|
None or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
enable_scheduling
Enables Task scheduling on the specified Compute Node.
You can enable Task scheduling on a Compute Node only if its current scheduling state is disabled.
enable_scheduling(pool_id, node_id, compute_node_enable_scheduling_options=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
pool_id
Required
|
The ID of the Pool that contains the Compute Node. |
node_id
Required
|
The ID of the Compute Node on which you want to enable Task scheduling. |
compute_node_enable_scheduling_options
|
Additional parameters for the operation Default value: None
|
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
None,
<xref:msrest.pipeline.ClientRawResponse>
|
None or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
get
Gets information about the specified Compute Node.
get(pool_id, node_id, compute_node_get_options=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
pool_id
Required
|
The ID of the Pool that contains the Compute Node. |
node_id
Required
|
The ID of the Compute Node that you want to get information about. |
compute_node_get_options
|
Additional parameters for the operation Default value: None
|
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
<xref:msrest.pipeline.ClientRawResponse>
|
ComputeNode or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
get_remote_desktop
Gets the Remote Desktop Protocol file for the specified Compute Node.
Before you can access a Compute Node by using the RDP file, you must create a user Account on the Compute Node. This API can only be invoked on Pools created with a cloud service configuration. For Pools created with a virtual machine configuration, see the GetRemoteLoginSettings API.
get_remote_desktop(pool_id, node_id, compute_node_get_remote_desktop_options=None, custom_headers=None, raw=False, callback=None, **operation_config)
Parameters
Name | Description |
---|---|
pool_id
Required
|
The ID of the Pool that contains the Compute Node. |
node_id
Required
|
The ID of the Compute Node for which you want to get the Remote Desktop Protocol file. |
compute_node_get_remote_desktop_options
|
Additional parameters for the operation Default value: None
|
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
callback
|
When specified, will be called with each chunk of data that is streamed. The callback should take two arguments, the bytes of the current chunk of data and the response object. If the data is uploading, response will be None. Default value: None
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
<xref:msrest.pipeline.ClientRawResponse>
|
object or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
get_remote_login_settings
Gets the settings required for remote login to a Compute Node.
Before you can remotely login to a Compute Node using the remote login settings, you must create a user Account on the Compute Node. This API can be invoked only on Pools created with the virtual machine configuration property. For Pools created with a cloud service configuration, see the GetRemoteDesktop API.
get_remote_login_settings(pool_id, node_id, compute_node_get_remote_login_settings_options=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
pool_id
Required
|
The ID of the Pool that contains the Compute Node. |
node_id
Required
|
The ID of the Compute Node for which to obtain the remote login settings. |
compute_node_get_remote_login_settings_options
|
Additional parameters for the operation Default value: None
|
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
<xref:msrest.pipeline.ClientRawResponse>
|
ComputeNodeGetRemoteLoginSettingsResult or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
list
Lists the Compute Nodes in the specified Pool.
list(pool_id, compute_node_list_options=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
pool_id
Required
|
The ID of the Pool from which you want to list Compute Nodes. |
compute_node_list_options
|
Additional parameters for the operation Default value: None
|
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
An iterator like instance of ComputeNode |
Exceptions
Type | Description |
---|---|
reboot
Restarts the specified Compute Node.
You can restart a Compute Node only if it is in an idle or running state.
reboot(pool_id, node_id, node_reboot_option=None, compute_node_reboot_options=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
pool_id
Required
|
The ID of the Pool that contains the Compute Node. |
node_id
Required
|
The ID of the Compute Node that you want to restart. |
node_reboot_option
|
The default value is requeue. Possible values include: 'requeue', 'terminate', 'taskCompletion', 'retainedData' Default value: None
|
compute_node_reboot_options
|
Additional parameters for the operation Default value: None
|
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
None,
<xref:msrest.pipeline.ClientRawResponse>
|
None or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
reimage
Reinstalls the operating system on the specified Compute Node.
You can reinstall the operating system on a Compute Node only if it is in an idle or running state. This API can be invoked only on Pools created with the cloud service configuration property.
reimage(pool_id, node_id, node_reimage_option=None, compute_node_reimage_options=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
pool_id
Required
|
The ID of the Pool that contains the Compute Node. |
node_id
Required
|
The ID of the Compute Node that you want to restart. |
node_reimage_option
|
The default value is requeue. Possible values include: 'requeue', 'terminate', 'taskCompletion', 'retainedData' Default value: None
|
compute_node_reimage_options
|
Additional parameters for the operation Default value: None
|
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
None,
<xref:msrest.pipeline.ClientRawResponse>
|
None or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
update_user
Updates the password and expiration time of a user Account on the specified Compute Node.
This operation replaces of all the updatable properties of the Account. For example, if the expiryTime element is not specified, the current value is replaced with the default value, not left unmodified. You can update a user Account on a Compute Node only when it is in the idle or running state.
update_user(pool_id, node_id, user_name, node_update_user_parameter, compute_node_update_user_options=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
pool_id
Required
|
The ID of the Pool that contains the Compute Node. |
node_id
Required
|
The ID of the machine on which you want to update a user Account. |
user_name
Required
|
The name of the user Account to update. |
node_update_user_parameter
Required
|
The parameters for the request. |
compute_node_update_user_options
|
Additional parameters for the operation Default value: None
|
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
None,
<xref:msrest.pipeline.ClientRawResponse>
|
None or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
upload_batch_service_logs
Upload Azure Batch service log files from the specified Compute Node to Azure Blob Storage.
This is for gathering Azure Batch service log files in an automated fashion from Compute Nodes if you are experiencing an error and wish to escalate to Azure support. The Azure Batch service log files should be shared with Azure support to aid in debugging issues with the Batch service.
upload_batch_service_logs(pool_id, node_id, upload_batch_service_logs_configuration, compute_node_upload_batch_service_logs_options=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
pool_id
Required
|
The ID of the Pool that contains the Compute Node. |
node_id
Required
|
The ID of the Compute Node from which you want to upload the Azure Batch service log files. |
upload_batch_service_logs_configuration
Required
|
The Azure Batch service log files upload configuration. |
compute_node_upload_batch_service_logs_options
|
Additional parameters for the operation Default value: None
|
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
<xref:msrest.pipeline.ClientRawResponse>
|
UploadBatchServiceLogsResult or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
Attributes
models
models = <module 'azure.batch.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.11.9\\x64\\Lib\\site-packages\\azure\\batch\\models\\__init__.py'>
Azure SDK for Python