Azure.Batch (preview:2024-07-01.20.0)

2024/12/17 • 29 updated methods

Jobs_ListJobs (updated)
Description Lists all of the Jobs in the specified Account.
Reference Link ¶

⚶ Changes

{
  "#id": "Jobs_ListJobs",
  "$parameters": [
    {
      "#name": "$filter",
      "Description": {
        "new": "An OData $filter clause. For more information on constructing this filter, see\nhttps://learn.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-jobs.",
        "old": "An OData $filter clause. For more information on constructing this filter, see\nhttps://docs.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-jobs."
      }
    }
  ],
  "$responses": {
    "200": {
      "$properties": {
        "value": {
          "$properties": {
            "jobManagerTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              },
              {
                "outputFiles": {
                  "$properties": {
                    "destination": [
                      {
                        "container": [
                          {
                            "#name": "uploadHeaders",
                            "Description": {
                              "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                              "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                            }
                          }
                        ]
                      }
                    ]
                  }
                }
              }
            ],
            "jobPreparationTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              }
            ],
            "jobReleaseTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              }
            ],
            "poolInfo": [
              {
                "autoPoolSpecification": [
                  {
                    "pool": [
                      {
                        "#name": "vmSize",
                        "Description": {
                          "new": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
                          "old": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
                        }
                      },
                      {
                        "virtualMachineConfiguration": [
                          {
                            "imageReference": [
                              {
                                "#name": "virtualMachineImageId",
                                "Description": {
                                  "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                                  "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                                }
                              }
                            ]
                          },
                          {
                            "#name": "dataDisks",
                            "Description": {
                              "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
                              "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
                            }
                          },
                          {
                            "osDisk": [
                              {
                                "ephemeralOSDiskSettings": [
                                  {
                                    "#name": "placement",
                                    "Description": {
                                      "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                                      "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                                    }
                                  }
                                ]
                              }
                            ]
                          }
                        ]
                      },
                      {
                        "networkConfiguration": [
                          {
                            "#name": "subnetId",
                            "Description": {
                              "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
                              "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
                            }
                          }
                        ]
                      },
                      {
                        "startTask": [
                          {
                            "#name": "commandLine",
                            "Description": {
                              "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                              "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                            }
                          }
                        ]
                      }
                    ]
                  }
                ]
              }
            ],
            "networkConfiguration": [
              {
                "#name": "subnetId",
                "Description": {
                  "new": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://learn.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration.",
                  "old": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://docs.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration."
                }
              }
            ]
          }
        }
      }
    }
  }
}

⚼ Request

GET:  /jobs
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
maxresults: integer ,
$filter: string ,
$select: array ,
$expand: array ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
value:
[
{
id: string ,
displayName: string ,
usesTaskDependencies: boolean ,
url: string ,
eTag: string ,
lastModified: string ,
creationTime: string ,
state: enum ,
stateTransitionTime: string ,
previousState: enum ,
previousStateTransitionTime: string ,
priority: integer ,
allowTaskPreemption: boolean ,
maxParallelTasks: integer ,
constraints:
{
maxWallClockTime: string ,
maxTaskRetryCount: integer ,
}
,
jobManagerTask:
{
id: string ,
displayName: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
killJobOnCompletion: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
runExclusive: boolean ,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
allowLowPriorityNode: boolean ,
}
,
jobPreparationTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
waitForSuccess: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
rerunOnNodeRebootAfterSuccess: boolean ,
}
,
jobReleaseTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
maxWallClockTime: string ,
retentionTime: string ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
}
,
commonEnvironmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
poolInfo:
{
poolId: string ,
autoPoolSpecification:
{
autoPoolIdPrefix: string ,
poolLifetimeOption: enum ,
keepAlive: boolean ,
pool:
{
displayName: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
resizeTimeout: string ,
resourceTags: string ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
targetNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}
,
}
,
onAllTasksComplete: enum ,
onTaskFailure: enum ,
networkConfiguration:
{
subnetId: string ,
skipWithdrawFromVNet: boolean ,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
executionInfo:
{
startTime: string ,
endTime: string ,
poolId: string ,
schedulingError:
{
category: enum ,
code: string ,
message: string ,
details:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
terminateReason: string ,
}
,
stats:
{
url: string ,
startTime: string ,
lastUpdateTime: string ,
userCPUTime: string ,
kernelCPUTime: string ,
wallClockTime: string ,
readIOps: integer ,
writeIOps: integer ,
readIOGiB: number ,
writeIOGiB: number ,
numSucceededTasks: integer ,
numFailedTasks: integer ,
numTaskRetries: integer ,
waitTime: string ,
}
,
}
,
]
,
odata.nextLink: string ,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Jobs_CreateJob (updated)
Description The Batch service supports two ways to control the work done as part of a Job. In the first approach, the user specifies a Job Manager Task. The Batch service launches this Task when it is ready to start the Job. The Job Manager Task controls all other Tasks that run under this Job, by using the Task APIs. In the second approach, the user directly controls the execution of Tasks under an active Job, by using the Task APIs. Also note: when naming Jobs, avoid including sensitive information such as user names or secret project names. This information may appear in telemetry logs accessible to Microsoft Support engineers.
Reference Link ¶

⚶ Changes

{
  "#id": "Jobs_CreateJob",
  "$parameters": {
    "job": {
      "$properties": {
        "jobManagerTask": [
          {
            "#name": "commandLine",
            "Description": {
              "new": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
              "old": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
            }
          },
          {
            "outputFiles": {
              "$properties": {
                "destination": [
                  {
                    "container": [
                      {
                        "#name": "uploadHeaders",
                        "Description": {
                          "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                          "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                        }
                      }
                    ]
                  }
                ]
              }
            }
          }
        ],
        "jobPreparationTask": [
          {
            "#name": "commandLine",
            "Description": {
              "new": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
              "old": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
            }
          }
        ],
        "jobReleaseTask": [
          {
            "#name": "commandLine",
            "Description": {
              "new": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
              "old": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
            }
          }
        ],
        "poolInfo": [
          {
            "autoPoolSpecification": [
              {
                "pool": [
                  {
                    "#name": "vmSize",
                    "Description": {
                      "new": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
                      "old": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
                    }
                  },
                  {
                    "virtualMachineConfiguration": [
                      {
                        "imageReference": [
                          {
                            "#name": "virtualMachineImageId",
                            "Description": {
                              "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                              "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                            }
                          }
                        ]
                      },
                      {
                        "#name": "dataDisks",
                        "Description": {
                          "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
                          "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
                        }
                      },
                      {
                        "osDisk": [
                          {
                            "ephemeralOSDiskSettings": [
                              {
                                "#name": "placement",
                                "Description": {
                                  "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                                  "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                                }
                              }
                            ]
                          }
                        ]
                      }
                    ]
                  },
                  {
                    "networkConfiguration": [
                      {
                        "#name": "subnetId",
                        "Description": {
                          "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
                          "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
                        }
                      }
                    ]
                  },
                  {
                    "startTask": [
                      {
                        "#name": "commandLine",
                        "Description": {
                          "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                          "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                        }
                      }
                    ]
                  }
                ]
              }
            ]
          }
        ],
        "networkConfiguration": [
          {
            "#name": "subnetId",
            "Description": {
              "new": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://learn.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration.",
              "old": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://docs.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration."
            }
          }
        ]
      }
    }
  }
}

⚼ Request

POST:  /jobs
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
job:
{
id: string ,
displayName: string ,
usesTaskDependencies: boolean ,
priority: integer ,
allowTaskPreemption: boolean ,
maxParallelTasks: integer ,
constraints:
{
maxWallClockTime: string ,
maxTaskRetryCount: integer ,
}
,
jobManagerTask:
{
id: string ,
displayName: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
killJobOnCompletion: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
runExclusive: boolean ,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
allowLowPriorityNode: boolean ,
}
,
jobPreparationTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
waitForSuccess: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
rerunOnNodeRebootAfterSuccess: boolean ,
}
,
jobReleaseTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
maxWallClockTime: string ,
retentionTime: string ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
}
,
commonEnvironmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
poolInfo:
{
poolId: string ,
autoPoolSpecification:
{
autoPoolIdPrefix: string ,
poolLifetimeOption: enum ,
keepAlive: boolean ,
pool:
{
displayName: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
resizeTimeout: string ,
resourceTags: string ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
targetNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}
,
}
,
onAllTasksComplete: enum ,
onTaskFailure: enum ,
networkConfiguration:
{
subnetId: string ,
skipWithdrawFromVNet: boolean ,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}

⚐ Response (201)

{
dataserviceid: string ,
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Jobs_GetJob (updated)
Description Gets information about the specified Job.
Reference Link ¶

⚶ Changes

{
  "#id": "Jobs_GetJob",
  "$responses": {
    "200": {
      "$properties": {
        "jobManagerTask": [
          {
            "#name": "commandLine",
            "Description": {
              "new": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
              "old": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
            }
          },
          {
            "outputFiles": {
              "$properties": {
                "destination": [
                  {
                    "container": [
                      {
                        "#name": "uploadHeaders",
                        "Description": {
                          "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                          "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                        }
                      }
                    ]
                  }
                ]
              }
            }
          }
        ],
        "jobPreparationTask": [
          {
            "#name": "commandLine",
            "Description": {
              "new": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
              "old": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
            }
          }
        ],
        "jobReleaseTask": [
          {
            "#name": "commandLine",
            "Description": {
              "new": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
              "old": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
            }
          }
        ],
        "poolInfo": [
          {
            "autoPoolSpecification": [
              {
                "pool": [
                  {
                    "#name": "vmSize",
                    "Description": {
                      "new": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
                      "old": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
                    }
                  },
                  {
                    "virtualMachineConfiguration": [
                      {
                        "imageReference": [
                          {
                            "#name": "virtualMachineImageId",
                            "Description": {
                              "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                              "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                            }
                          }
                        ]
                      },
                      {
                        "#name": "dataDisks",
                        "Description": {
                          "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
                          "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
                        }
                      },
                      {
                        "osDisk": [
                          {
                            "ephemeralOSDiskSettings": [
                              {
                                "#name": "placement",
                                "Description": {
                                  "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                                  "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                                }
                              }
                            ]
                          }
                        ]
                      }
                    ]
                  },
                  {
                    "networkConfiguration": [
                      {
                        "#name": "subnetId",
                        "Description": {
                          "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
                          "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
                        }
                      }
                    ]
                  },
                  {
                    "startTask": [
                      {
                        "#name": "commandLine",
                        "Description": {
                          "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                          "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                        }
                      }
                    ]
                  }
                ]
              }
            ]
          }
        ],
        "networkConfiguration": [
          {
            "#name": "subnetId",
            "Description": {
              "new": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://learn.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration.",
              "old": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://docs.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration."
            }
          }
        ]
      }
    }
  }
}

⚼ Request

GET:  /jobs/{jobId}
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
If-Modified-Since: string ,
If-Unmodified-Since: string ,
If-Match: string ,
If-None-Match: string ,
jobId: string ,
$select: array ,
$expand: array ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
id: string ,
displayName: string ,
usesTaskDependencies: boolean ,
url: string ,
eTag: string ,
lastModified: string ,
creationTime: string ,
state: enum ,
stateTransitionTime: string ,
previousState: enum ,
previousStateTransitionTime: string ,
priority: integer ,
allowTaskPreemption: boolean ,
maxParallelTasks: integer ,
constraints:
{
maxWallClockTime: string ,
maxTaskRetryCount: integer ,
}
,
jobManagerTask:
{
id: string ,
displayName: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
killJobOnCompletion: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
runExclusive: boolean ,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
allowLowPriorityNode: boolean ,
}
,
jobPreparationTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
waitForSuccess: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
rerunOnNodeRebootAfterSuccess: boolean ,
}
,
jobReleaseTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
maxWallClockTime: string ,
retentionTime: string ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
}
,
commonEnvironmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
poolInfo:
{
poolId: string ,
autoPoolSpecification:
{
autoPoolIdPrefix: string ,
poolLifetimeOption: enum ,
keepAlive: boolean ,
pool:
{
displayName: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
resizeTimeout: string ,
resourceTags: string ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
targetNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}
,
}
,
onAllTasksComplete: enum ,
onTaskFailure: enum ,
networkConfiguration:
{
subnetId: string ,
skipWithdrawFromVNet: boolean ,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
executionInfo:
{
startTime: string ,
endTime: string ,
poolId: string ,
schedulingError:
{
category: enum ,
code: string ,
message: string ,
details:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
terminateReason: string ,
}
,
stats:
{
url: string ,
startTime: string ,
lastUpdateTime: string ,
userCPUTime: string ,
kernelCPUTime: string ,
wallClockTime: string ,
readIOps: integer ,
writeIOps: integer ,
readIOGiB: number ,
writeIOGiB: number ,
numSucceededTasks: integer ,
numFailedTasks: integer ,
numTaskRetries: integer ,
waitTime: string ,
}
,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Jobs_ReplaceJob (updated)
Description This fully replaces all the updatable properties of the Job. For example, if the Job has constraints associated with it and if constraints is not specified with this request, then the Batch service will remove the existing constraints.
Reference Link ¶

⚶ Changes

{
  "#id": "Jobs_ReplaceJob",
  "$parameters": {
    "job": {
      "$properties": {
        "jobManagerTask": [
          {
            "#name": "commandLine",
            "Description": {
              "new": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
              "old": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
            }
          },
          {
            "outputFiles": {
              "$properties": {
                "destination": [
                  {
                    "container": [
                      {
                        "#name": "uploadHeaders",
                        "Description": {
                          "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                          "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                        }
                      }
                    ]
                  }
                ]
              }
            }
          }
        ],
        "jobPreparationTask": [
          {
            "#name": "commandLine",
            "Description": {
              "new": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
              "old": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
            }
          }
        ],
        "jobReleaseTask": [
          {
            "#name": "commandLine",
            "Description": {
              "new": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
              "old": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
            }
          }
        ],
        "poolInfo": [
          {
            "autoPoolSpecification": [
              {
                "pool": [
                  {
                    "#name": "vmSize",
                    "Description": {
                      "new": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
                      "old": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
                    }
                  },
                  {
                    "virtualMachineConfiguration": [
                      {
                        "imageReference": [
                          {
                            "#name": "virtualMachineImageId",
                            "Description": {
                              "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                              "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                            }
                          }
                        ]
                      },
                      {
                        "#name": "dataDisks",
                        "Description": {
                          "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
                          "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
                        }
                      },
                      {
                        "osDisk": [
                          {
                            "ephemeralOSDiskSettings": [
                              {
                                "#name": "placement",
                                "Description": {
                                  "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                                  "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                                }
                              }
                            ]
                          }
                        ]
                      }
                    ]
                  },
                  {
                    "networkConfiguration": [
                      {
                        "#name": "subnetId",
                        "Description": {
                          "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
                          "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
                        }
                      }
                    ]
                  },
                  {
                    "startTask": [
                      {
                        "#name": "commandLine",
                        "Description": {
                          "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                          "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                        }
                      }
                    ]
                  }
                ]
              }
            ]
          }
        ],
        "networkConfiguration": [
          {
            "#name": "subnetId",
            "Description": {
              "new": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://learn.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration.",
              "old": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://docs.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration."
            }
          }
        ]
      }
    }
  }
}

⚼ Request

PUT:  /jobs/{jobId}
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
If-Modified-Since: string ,
If-Unmodified-Since: string ,
If-Match: string ,
If-None-Match: string ,
jobId: string ,
job:
{
id: string ,
displayName: string ,
usesTaskDependencies: boolean ,
url: string ,
eTag: string ,
lastModified: string ,
creationTime: string ,
state: enum ,
stateTransitionTime: string ,
previousState: enum ,
previousStateTransitionTime: string ,
priority: integer ,
allowTaskPreemption: boolean ,
maxParallelTasks: integer ,
constraints:
{
maxWallClockTime: string ,
maxTaskRetryCount: integer ,
}
,
jobManagerTask:
{
id: string ,
displayName: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
killJobOnCompletion: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
runExclusive: boolean ,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
allowLowPriorityNode: boolean ,
}
,
jobPreparationTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
waitForSuccess: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
rerunOnNodeRebootAfterSuccess: boolean ,
}
,
jobReleaseTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
maxWallClockTime: string ,
retentionTime: string ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
}
,
commonEnvironmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
poolInfo:
{
poolId: string ,
autoPoolSpecification:
{
autoPoolIdPrefix: string ,
poolLifetimeOption: enum ,
keepAlive: boolean ,
pool:
{
displayName: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
resizeTimeout: string ,
resourceTags: string ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
targetNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}
,
}
,
onAllTasksComplete: enum ,
onTaskFailure: enum ,
networkConfiguration:
{
subnetId: string ,
skipWithdrawFromVNet: boolean ,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
executionInfo:
{
startTime: string ,
endTime: string ,
poolId: string ,
schedulingError:
{
category: enum ,
code: string ,
message: string ,
details:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
terminateReason: string ,
}
,
stats:
{
url: string ,
startTime: string ,
lastUpdateTime: string ,
userCPUTime: string ,
kernelCPUTime: string ,
wallClockTime: string ,
readIOps: integer ,
writeIOps: integer ,
readIOGiB: number ,
writeIOGiB: number ,
numSucceededTasks: integer ,
numFailedTasks: integer ,
numTaskRetries: integer ,
waitTime: string ,
}
,
}
,
}

⚐ Response (200)

{
dataserviceid: string ,
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Jobs_UpdateJob (updated)
Description This replaces only the Job properties specified in the request. For example, if the Job has constraints, and a request does not specify the constraints element, then the Job keeps the existing constraints.
Reference Link ¶

⚶ Changes

{
  "#id": "Jobs_UpdateJob",
  "$parameters": {
    "job": {
      "$properties": {
        "poolInfo": [
          {
            "autoPoolSpecification": [
              {
                "pool": [
                  {
                    "#name": "vmSize",
                    "Description": {
                      "new": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
                      "old": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
                    }
                  },
                  {
                    "virtualMachineConfiguration": [
                      {
                        "imageReference": [
                          {
                            "#name": "virtualMachineImageId",
                            "Description": {
                              "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                              "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                            }
                          }
                        ]
                      },
                      {
                        "#name": "dataDisks",
                        "Description": {
                          "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
                          "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
                        }
                      },
                      {
                        "osDisk": [
                          {
                            "ephemeralOSDiskSettings": [
                              {
                                "#name": "placement",
                                "Description": {
                                  "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                                  "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                                }
                              }
                            ]
                          }
                        ]
                      }
                    ]
                  },
                  {
                    "networkConfiguration": [
                      {
                        "#name": "subnetId",
                        "Description": {
                          "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
                          "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
                        }
                      }
                    ]
                  },
                  {
                    "startTask": [
                      {
                        "#name": "commandLine",
                        "Description": {
                          "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                          "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                        }
                      }
                    ]
                  }
                ]
              }
            ]
          }
        ],
        "networkConfiguration": [
          {
            "#name": "subnetId",
            "Description": {
              "new": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://learn.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration.",
              "old": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://docs.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration."
            }
          }
        ]
      }
    }
  }
}

⚼ Request

PATCH:  /jobs/{jobId}
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
If-Modified-Since: string ,
If-Unmodified-Since: string ,
If-Match: string ,
If-None-Match: string ,
jobId: string ,
job:
{
priority: integer ,
allowTaskPreemption: boolean ,
maxParallelTasks: integer ,
constraints:
{
maxWallClockTime: string ,
maxTaskRetryCount: integer ,
}
,
poolInfo:
{
poolId: string ,
autoPoolSpecification:
{
autoPoolIdPrefix: string ,
poolLifetimeOption: enum ,
keepAlive: boolean ,
pool:
{
displayName: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
resizeTimeout: string ,
resourceTags: string ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
targetNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}
,
}
,
onAllTasksComplete: enum ,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
networkConfiguration:
{
subnetId: string ,
skipWithdrawFromVNet: boolean ,
}
,
}
,
}

⚐ Response (200)

{
dataserviceid: string ,
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Tasks_CreateTaskCollection (updated)
Description Note that each Task must have a unique ID. The Batch service may not return the results for each Task in the same order the Tasks were submitted in this request. If the server times out or the connection is closed during the request, the request may have been partially or fully processed, or not at all. In such cases, the user should re-issue the request. Note that it is up to the user to correctly handle failures when re-issuing a request. For example, you should use the same Task IDs during a retry so that if the prior operation succeeded, the retry will not create extra Tasks unexpectedly. If the response contains any Tasks which failed to add, a client can retry the request. In a retry, it is most efficient to resubmit only Tasks that failed to add, and to omit Tasks that were successfully added on the first attempt. The maximum lifetime of a Task from addition to completion is 180 days. If a Task has not completed within 180 days of being added it will be terminated by the Batch service and left in whatever state it was in at that time.
Reference Link ¶

⚶ Changes

{
  "#id": "Tasks_CreateTaskCollection",
  "$parameters": {
    "taskCollection": {
      "$properties": {
        "value": {
          "$properties": [
            {
              "#name": "commandLine",
              "Description": {
                "new": "The command line of the Task. For multi-instance Tasks, the command line is executed as the primary Task, after the primary Task and all subtasks have finished executing the coordination command line. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/en-us/azure/batch/batch-compute-node-environment-variables).",
                "old": "The command line of the Task. For multi-instance Tasks, the command line is executed as the primary Task, after the primary Task and all subtasks have finished executing the coordination command line. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/en-us/azure/batch/batch-compute-node-environment-variables)."
              }
            },
            {
              "outputFiles": {
                "$properties": {
                  "destination": [
                    {
                      "container": [
                        {
                          "#name": "uploadHeaders",
                          "Description": {
                            "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                            "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                          }
                        }
                      ]
                    }
                  ]
                }
              }
            }
          ]
        }
      }
    }
  }
}

⚼ Request

POST:  /jobs/{jobId}/addtaskcollection
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
jobId: string ,
taskCollection:
{
value:
[
{
id: string ,
displayName: string ,
exitConditions:
{
exitCodes:
[
{
code: integer ,
exitOptions:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
]
,
exitCodeRanges:
[
{
start: integer ,
end: integer ,
exitOptions:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
]
,
preProcessingError:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
fileUploadError:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
default:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
affinityInfo:
{
affinityId: string ,
}
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
multiInstanceSettings:
{
numberOfInstances: integer ,
coordinationCommandLine: string ,
commonResourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
dependsOn:
{
taskIds:
[
string ,
]
,
taskIdRanges:
[
{
start: integer ,
end: integer ,
}
,
]
,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
}
,
]
,
}
,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
value:
[
{
status: enum ,
taskId: string ,
eTag: string ,
lastModified: string ,
location: string ,
error:
{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
,
}
,
]
,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Jobs_ListJobPreparationAndReleaseTaskStatus (updated)
Description This API returns the Job Preparation and Job Release Task status on all Compute Nodes that have run the Job Preparation or Job Release Task. This includes Compute Nodes which have since been removed from the Pool. If this API is invoked on a Job which has no Job Preparation or Job Release Task, the Batch service returns HTTP status code 409 (Conflict) with an error code of JobPreparationTaskNotSpecified.
Reference Link ¶

⚶ Changes

{
  "#id": "Jobs_ListJobPreparationAndReleaseTaskStatus",
  "$parameters": [
    {
      "#name": "$filter",
      "Description": {
        "new": "An OData $filter clause. For more information on constructing this filter, see\nhttps://learn.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-job-preparation-and-release-status.",
        "old": "An OData $filter clause. For more information on constructing this filter, see\nhttps://docs.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-job-preparation-and-release-status."
      }
    }
  ]
}

⚼ Request

GET:  /jobs/{jobId}/jobpreparationandreleasetaskstatus
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
maxresults: integer ,
jobId: string ,
$filter: string ,
$select: array ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
value:
[
{
poolId: string ,
nodeId: string ,
nodeUrl: string ,
jobPreparationTaskExecutionInfo:
{
startTime: string ,
endTime: string ,
state: enum ,
taskRootDirectory: string ,
taskRootDirectoryUrl: string ,
exitCode: integer ,
containerInfo:
{
containerId: string ,
state: string ,
error: string ,
}
,
failureInfo:
{
category: enum ,
code: string ,
message: string ,
details:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
retryCount: integer ,
lastRetryTime: string ,
result: enum ,
}
,
jobReleaseTaskExecutionInfo:
{
startTime: string ,
endTime: string ,
state: enum ,
taskRootDirectory: string ,
taskRootDirectoryUrl: string ,
exitCode: integer ,
containerInfo:
{
containerId: string ,
state: string ,
error: string ,
}
,
failureInfo:
{
category: enum ,
code: string ,
message: string ,
details:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
result: enum ,
}
,
}
,
]
,
odata.nextLink: string ,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Tasks_ListTasks (updated)
Description For multi-instance Tasks, information such as affinityId, executionInfo and nodeInfo refer to the primary Task. Use the list subtasks API to retrieve information about subtasks.
Reference Link ¶

⚶ Changes

{
  "#id": "Tasks_ListTasks",
  "$parameters": [
    {
      "#name": "$filter",
      "Description": {
        "new": "An OData $filter clause. For more information on constructing this filter, see\nhttps://learn.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-tasks.",
        "old": "An OData $filter clause. For more information on constructing this filter, see\nhttps://docs.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-tasks."
      }
    }
  ],
  "$responses": {
    "200": {
      "$properties": {
        "value": {
          "$properties": [
            {
              "#name": "commandLine",
              "Description": {
                "new": "The command line of the Task. For multi-instance Tasks, the command line is executed as the primary Task, after the primary Task and all subtasks have finished executing the coordination command line. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                "old": "The command line of the Task. For multi-instance Tasks, the command line is executed as the primary Task, after the primary Task and all subtasks have finished executing the coordination command line. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
              }
            },
            {
              "outputFiles": {
                "$properties": {
                  "destination": [
                    {
                      "container": [
                        {
                          "#name": "uploadHeaders",
                          "Description": {
                            "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                            "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                          }
                        }
                      ]
                    }
                  ]
                }
              }
            }
          ]
        }
      }
    }
  }
}

⚼ Request

GET:  /jobs/{jobId}/tasks
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
maxresults: integer ,
jobId: string ,
$filter: string ,
$select: array ,
$expand: array ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
value:
[
{
id: string ,
displayName: string ,
url: string ,
eTag: string ,
lastModified: string ,
creationTime: string ,
exitConditions:
{
exitCodes:
[
{
code: integer ,
exitOptions:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
]
,
exitCodeRanges:
[
{
start: integer ,
end: integer ,
exitOptions:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
]
,
preProcessingError:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
fileUploadError:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
default:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
state: enum ,
stateTransitionTime: string ,
previousState: enum ,
previousStateTransitionTime: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
affinityInfo:
{
affinityId: string ,
}
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
executionInfo:
{
startTime: string ,
endTime: string ,
exitCode: integer ,
containerInfo:
{
containerId: string ,
state: string ,
error: string ,
}
,
failureInfo:
{
category: enum ,
code: string ,
message: string ,
details:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
retryCount: integer ,
lastRetryTime: string ,
requeueCount: integer ,
lastRequeueTime: string ,
result: enum ,
}
,
nodeInfo:
{
affinityId: string ,
nodeUrl: string ,
poolId: string ,
nodeId: string ,
taskRootDirectory: string ,
taskRootDirectoryUrl: string ,
}
,
multiInstanceSettings:
{
numberOfInstances: integer ,
coordinationCommandLine: string ,
commonResourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
stats:
{
url: string ,
startTime: string ,
lastUpdateTime: string ,
userCPUTime: string ,
kernelCPUTime: string ,
wallClockTime: string ,
readIOps: integer ,
writeIOps: integer ,
readIOGiB: number ,
writeIOGiB: number ,
waitTime: string ,
}
,
dependsOn:
{
taskIds:
[
string ,
]
,
taskIdRanges:
[
{
start: integer ,
end: integer ,
}
,
]
,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
}
,
]
,
odata.nextLink: string ,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Tasks_CreateTask (updated)
Description The maximum lifetime of a Task from addition to completion is 180 days. If a Task has not completed within 180 days of being added it will be terminated by the Batch service and left in whatever state it was in at that time.
Reference Link ¶

⚶ Changes

{
  "#id": "Tasks_CreateTask",
  "$parameters": {
    "task": {
      "$properties": [
        {
          "#name": "commandLine",
          "Description": {
            "new": "The command line of the Task. For multi-instance Tasks, the command line is executed as the primary Task, after the primary Task and all subtasks have finished executing the coordination command line. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/en-us/azure/batch/batch-compute-node-environment-variables).",
            "old": "The command line of the Task. For multi-instance Tasks, the command line is executed as the primary Task, after the primary Task and all subtasks have finished executing the coordination command line. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/en-us/azure/batch/batch-compute-node-environment-variables)."
          }
        },
        {
          "outputFiles": {
            "$properties": {
              "destination": [
                {
                  "container": [
                    {
                      "#name": "uploadHeaders",
                      "Description": {
                        "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                        "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                      }
                    }
                  ]
                }
              ]
            }
          }
        }
      ]
    }
  }
}

⚼ Request

POST:  /jobs/{jobId}/tasks
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
jobId: string ,
task:
{
id: string ,
displayName: string ,
exitConditions:
{
exitCodes:
[
{
code: integer ,
exitOptions:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
]
,
exitCodeRanges:
[
{
start: integer ,
end: integer ,
exitOptions:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
]
,
preProcessingError:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
fileUploadError:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
default:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
affinityInfo:
{
affinityId: string ,
}
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
multiInstanceSettings:
{
numberOfInstances: integer ,
coordinationCommandLine: string ,
commonResourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
dependsOn:
{
taskIds:
[
string ,
]
,
taskIdRanges:
[
{
start: integer ,
end: integer ,
}
,
]
,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
}
,
}

⚐ Response (201)

{
dataserviceid: string ,
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Tasks_GetTask (updated)
Description For multi-instance Tasks, information such as affinityId, executionInfo and nodeInfo refer to the primary Task. Use the list subtasks API to retrieve information about subtasks.
Reference Link ¶

⚶ Changes

{
  "#id": "Tasks_GetTask",
  "$responses": {
    "200": {
      "$properties": [
        {
          "#name": "commandLine",
          "Description": {
            "new": "The command line of the Task. For multi-instance Tasks, the command line is executed as the primary Task, after the primary Task and all subtasks have finished executing the coordination command line. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
            "old": "The command line of the Task. For multi-instance Tasks, the command line is executed as the primary Task, after the primary Task and all subtasks have finished executing the coordination command line. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
          }
        },
        {
          "outputFiles": {
            "$properties": {
              "destination": [
                {
                  "container": [
                    {
                      "#name": "uploadHeaders",
                      "Description": {
                        "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                        "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                      }
                    }
                  ]
                }
              ]
            }
          }
        }
      ]
    }
  }
}

⚼ Request

GET:  /jobs/{jobId}/tasks/{taskId}
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
If-Modified-Since: string ,
If-Unmodified-Since: string ,
If-Match: string ,
If-None-Match: string ,
jobId: string ,
taskId: string ,
$select: array ,
$expand: array ,
}

⚐ Response (200)

{
$headers:
{
dataserviceid: string ,
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
id: string ,
displayName: string ,
url: string ,
eTag: string ,
lastModified: string ,
creationTime: string ,
exitConditions:
{
exitCodes:
[
{
code: integer ,
exitOptions:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
]
,
exitCodeRanges:
[
{
start: integer ,
end: integer ,
exitOptions:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
]
,
preProcessingError:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
fileUploadError:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
default:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
state: enum ,
stateTransitionTime: string ,
previousState: enum ,
previousStateTransitionTime: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
affinityInfo:
{
affinityId: string ,
}
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
executionInfo:
{
startTime: string ,
endTime: string ,
exitCode: integer ,
containerInfo:
{
containerId: string ,
state: string ,
error: string ,
}
,
failureInfo:
{
category: enum ,
code: string ,
message: string ,
details:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
retryCount: integer ,
lastRetryTime: string ,
requeueCount: integer ,
lastRequeueTime: string ,
result: enum ,
}
,
nodeInfo:
{
affinityId: string ,
nodeUrl: string ,
poolId: string ,
nodeId: string ,
taskRootDirectory: string ,
taskRootDirectoryUrl: string ,
}
,
multiInstanceSettings:
{
numberOfInstances: integer ,
coordinationCommandLine: string ,
commonResourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
stats:
{
url: string ,
startTime: string ,
lastUpdateTime: string ,
userCPUTime: string ,
kernelCPUTime: string ,
wallClockTime: string ,
readIOps: integer ,
writeIOps: integer ,
readIOGiB: number ,
writeIOGiB: number ,
waitTime: string ,
}
,
dependsOn:
{
taskIds:
[
string ,
]
,
taskIdRanges:
[
{
start: integer ,
end: integer ,
}
,
]
,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Tasks_ReplaceTask (updated)
Description Updates the properties of the specified Task.
Reference Link ¶

⚶ Changes

{
  "#id": "Tasks_ReplaceTask",
  "$parameters": {
    "task": {
      "$properties": [
        {
          "#name": "commandLine",
          "Description": {
            "new": "The command line of the Task. For multi-instance Tasks, the command line is executed as the primary Task, after the primary Task and all subtasks have finished executing the coordination command line. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
            "old": "The command line of the Task. For multi-instance Tasks, the command line is executed as the primary Task, after the primary Task and all subtasks have finished executing the coordination command line. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
          }
        },
        {
          "outputFiles": {
            "$properties": {
              "destination": [
                {
                  "container": [
                    {
                      "#name": "uploadHeaders",
                      "Description": {
                        "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                        "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                      }
                    }
                  ]
                }
              ]
            }
          }
        }
      ]
    }
  }
}

⚼ Request

PUT:  /jobs/{jobId}/tasks/{taskId}
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
If-Modified-Since: string ,
If-Unmodified-Since: string ,
If-Match: string ,
If-None-Match: string ,
jobId: string ,
taskId: string ,
task:
{
id: string ,
displayName: string ,
url: string ,
eTag: string ,
lastModified: string ,
creationTime: string ,
exitConditions:
{
exitCodes:
[
{
code: integer ,
exitOptions:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
]
,
exitCodeRanges:
[
{
start: integer ,
end: integer ,
exitOptions:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
]
,
preProcessingError:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
fileUploadError:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
default:
{
jobAction: enum ,
dependencyAction: enum ,
}
,
}
,
state: enum ,
stateTransitionTime: string ,
previousState: enum ,
previousStateTransitionTime: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
affinityInfo:
{
affinityId: string ,
}
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
executionInfo:
{
startTime: string ,
endTime: string ,
exitCode: integer ,
containerInfo:
{
containerId: string ,
state: string ,
error: string ,
}
,
failureInfo:
{
category: enum ,
code: string ,
message: string ,
details:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
retryCount: integer ,
lastRetryTime: string ,
requeueCount: integer ,
lastRequeueTime: string ,
result: enum ,
}
,
nodeInfo:
{
affinityId: string ,
nodeUrl: string ,
poolId: string ,
nodeId: string ,
taskRootDirectory: string ,
taskRootDirectoryUrl: string ,
}
,
multiInstanceSettings:
{
numberOfInstances: integer ,
coordinationCommandLine: string ,
commonResourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
stats:
{
url: string ,
startTime: string ,
lastUpdateTime: string ,
userCPUTime: string ,
kernelCPUTime: string ,
wallClockTime: string ,
readIOps: integer ,
writeIOps: integer ,
readIOGiB: number ,
writeIOGiB: number ,
waitTime: string ,
}
,
dependsOn:
{
taskIds:
[
string ,
]
,
taskIdRanges:
[
{
start: integer ,
end: integer ,
}
,
]
,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
}
,
}

⚐ Response (200)

{
dataserviceid: string ,
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Tasks_ListTaskFiles (updated)
Description Lists the files in a Task's directory on its Compute Node.
Reference Link ¶

⚶ Changes

{
  "#id": "Tasks_ListTaskFiles",
  "$parameters": [
    {
      "#name": "$filter",
      "Description": {
        "new": "An OData $filter clause. For more information on constructing this filter, see\nhttps://learn.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-task-files.",
        "old": "An OData $filter clause. For more information on constructing this filter, see\nhttps://docs.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-task-files."
      }
    }
  ]
}

⚼ Request

GET:  /jobs/{jobId}/tasks/{taskId}/files
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
maxresults: integer ,
jobId: string ,
taskId: string ,
$filter: string ,
recursive: boolean ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
value:
[
{
name: string ,
url: string ,
isDirectory: boolean ,
properties:
{
creationTime: string ,
lastModified: string ,
contentLength: string ,
contentType: string ,
fileMode: string ,
}
,
}
,
]
,
odata.nextLink: string ,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
JobSchedules_ListJobSchedules (updated)
Description Lists all of the Job Schedules in the specified Account.
Reference Link ¶

⚶ Changes

{
  "#id": "JobSchedules_ListJobSchedules",
  "$parameters": [
    {
      "#name": "$filter",
      "Description": {
        "new": "An OData $filter clause. For more information on constructing this filter, see\nhttps://learn.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-job-schedules.",
        "old": "An OData $filter clause. For more information on constructing this filter, see\nhttps://docs.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-job-schedules."
      }
    }
  ],
  "$responses": {
    "200": {
      "$properties": {
        "value": {
          "$properties": {
            "jobSpecification": [
              {
                "networkConfiguration": [
                  {
                    "#name": "subnetId",
                    "Description": {
                      "new": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://learn.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration.",
                      "old": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://docs.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration."
                    }
                  }
                ]
              },
              {
                "jobManagerTask": [
                  {
                    "#name": "commandLine",
                    "Description": {
                      "new": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                      "old": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                    }
                  },
                  {
                    "outputFiles": {
                      "$properties": {
                        "destination": [
                          {
                            "container": [
                              {
                                "#name": "uploadHeaders",
                                "Description": {
                                  "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                                  "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                                }
                              }
                            ]
                          }
                        ]
                      }
                    }
                  }
                ]
              },
              {
                "jobPreparationTask": [
                  {
                    "#name": "commandLine",
                    "Description": {
                      "new": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                      "old": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                    }
                  }
                ]
              },
              {
                "jobReleaseTask": [
                  {
                    "#name": "commandLine",
                    "Description": {
                      "new": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                      "old": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                    }
                  }
                ]
              },
              {
                "poolInfo": [
                  {
                    "autoPoolSpecification": [
                      {
                        "pool": [
                          {
                            "#name": "vmSize",
                            "Description": {
                              "new": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
                              "old": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
                            }
                          },
                          {
                            "virtualMachineConfiguration": [
                              {
                                "imageReference": [
                                  {
                                    "#name": "virtualMachineImageId",
                                    "Description": {
                                      "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                                      "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                                    }
                                  }
                                ]
                              },
                              {
                                "#name": "dataDisks",
                                "Description": {
                                  "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
                                  "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
                                }
                              },
                              {
                                "osDisk": [
                                  {
                                    "ephemeralOSDiskSettings": [
                                      {
                                        "#name": "placement",
                                        "Description": {
                                          "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                                          "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                                        }
                                      }
                                    ]
                                  }
                                ]
                              }
                            ]
                          },
                          {
                            "networkConfiguration": [
                              {
                                "#name": "subnetId",
                                "Description": {
                                  "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
                                  "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
                                }
                              }
                            ]
                          },
                          {
                            "startTask": [
                              {
                                "#name": "commandLine",
                                "Description": {
                                  "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                                  "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                                }
                              }
                            ]
                          }
                        ]
                      }
                    ]
                  }
                ]
              }
            ]
          }
        }
      }
    }
  }
}

⚼ Request

GET:  /jobschedules
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
maxresults: integer ,
$filter: string ,
$select: array ,
$expand: array ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
value:
[
{
id: string ,
displayName: string ,
url: string ,
eTag: string ,
lastModified: string ,
creationTime: string ,
state: enum ,
stateTransitionTime: string ,
previousState: enum ,
previousStateTransitionTime: string ,
schedule:
{
doNotRunUntil: string ,
doNotRunAfter: string ,
startWindow: string ,
recurrenceInterval: string ,
}
,
jobSpecification:
{
priority: integer ,
allowTaskPreemption: boolean ,
maxParallelTasks: integer ,
displayName: string ,
usesTaskDependencies: boolean ,
onAllTasksComplete: enum ,
onTaskFailure: enum ,
networkConfiguration:
{
subnetId: string ,
skipWithdrawFromVNet: boolean ,
}
,
constraints:
{
maxWallClockTime: string ,
maxTaskRetryCount: integer ,
}
,
jobManagerTask:
{
id: string ,
displayName: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
killJobOnCompletion: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
runExclusive: boolean ,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
allowLowPriorityNode: boolean ,
}
,
jobPreparationTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
waitForSuccess: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
rerunOnNodeRebootAfterSuccess: boolean ,
}
,
jobReleaseTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
maxWallClockTime: string ,
retentionTime: string ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
}
,
commonEnvironmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
poolInfo:
{
poolId: string ,
autoPoolSpecification:
{
autoPoolIdPrefix: string ,
poolLifetimeOption: enum ,
keepAlive: boolean ,
pool:
{
displayName: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
resizeTimeout: string ,
resourceTags: string ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
targetNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}
,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
executionInfo:
{
nextRunTime: string ,
recentJob:
{
id: string ,
url: string ,
}
,
endTime: string ,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
stats:
{
url: string ,
startTime: string ,
lastUpdateTime: string ,
userCPUTime: string ,
kernelCPUTime: string ,
wallClockTime: string ,
readIOps: integer ,
writeIOps: integer ,
readIOGiB: number ,
writeIOGiB: number ,
numSucceededTasks: integer ,
numFailedTasks: integer ,
numTaskRetries: integer ,
waitTime: string ,
}
,
}
,
]
,
odata.nextLink: string ,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
JobSchedules_CreateJobSchedule (updated)
Description Creates a Job Schedule to the specified Account.
Reference Link ¶

⚶ Changes

{
  "#id": "JobSchedules_CreateJobSchedule",
  "$parameters": {
    "jobSchedule": {
      "$properties": {
        "jobSpecification": [
          {
            "networkConfiguration": [
              {
                "#name": "subnetId",
                "Description": {
                  "new": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://learn.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration.",
                  "old": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://docs.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration."
                }
              }
            ]
          },
          {
            "jobManagerTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              },
              {
                "outputFiles": {
                  "$properties": {
                    "destination": [
                      {
                        "container": [
                          {
                            "#name": "uploadHeaders",
                            "Description": {
                              "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                              "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                            }
                          }
                        ]
                      }
                    ]
                  }
                }
              }
            ]
          },
          {
            "jobPreparationTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              }
            ]
          },
          {
            "jobReleaseTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              }
            ]
          },
          {
            "poolInfo": [
              {
                "autoPoolSpecification": [
                  {
                    "pool": [
                      {
                        "#name": "vmSize",
                        "Description": {
                          "new": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
                          "old": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
                        }
                      },
                      {
                        "virtualMachineConfiguration": [
                          {
                            "imageReference": [
                              {
                                "#name": "virtualMachineImageId",
                                "Description": {
                                  "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                                  "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                                }
                              }
                            ]
                          },
                          {
                            "#name": "dataDisks",
                            "Description": {
                              "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
                              "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
                            }
                          },
                          {
                            "osDisk": [
                              {
                                "ephemeralOSDiskSettings": [
                                  {
                                    "#name": "placement",
                                    "Description": {
                                      "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                                      "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                                    }
                                  }
                                ]
                              }
                            ]
                          }
                        ]
                      },
                      {
                        "networkConfiguration": [
                          {
                            "#name": "subnetId",
                            "Description": {
                              "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
                              "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
                            }
                          }
                        ]
                      },
                      {
                        "startTask": [
                          {
                            "#name": "commandLine",
                            "Description": {
                              "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                              "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                            }
                          }
                        ]
                      }
                    ]
                  }
                ]
              }
            ]
          }
        ]
      }
    }
  }
}

⚼ Request

POST:  /jobschedules
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
jobSchedule:
{
id: string ,
displayName: string ,
schedule:
{
doNotRunUntil: string ,
doNotRunAfter: string ,
startWindow: string ,
recurrenceInterval: string ,
}
,
jobSpecification:
{
priority: integer ,
allowTaskPreemption: boolean ,
maxParallelTasks: integer ,
displayName: string ,
usesTaskDependencies: boolean ,
onAllTasksComplete: enum ,
onTaskFailure: enum ,
networkConfiguration:
{
subnetId: string ,
skipWithdrawFromVNet: boolean ,
}
,
constraints:
{
maxWallClockTime: string ,
maxTaskRetryCount: integer ,
}
,
jobManagerTask:
{
id: string ,
displayName: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
killJobOnCompletion: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
runExclusive: boolean ,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
allowLowPriorityNode: boolean ,
}
,
jobPreparationTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
waitForSuccess: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
rerunOnNodeRebootAfterSuccess: boolean ,
}
,
jobReleaseTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
maxWallClockTime: string ,
retentionTime: string ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
}
,
commonEnvironmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
poolInfo:
{
poolId: string ,
autoPoolSpecification:
{
autoPoolIdPrefix: string ,
poolLifetimeOption: enum ,
keepAlive: boolean ,
pool:
{
displayName: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
resizeTimeout: string ,
resourceTags: string ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
targetNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}
,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}

⚐ Response (201)

{
dataserviceid: string ,
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
JobSchedules_GetJobSchedule (updated)
Description Gets information about the specified Job Schedule.
Reference Link ¶

⚶ Changes

{
  "#id": "JobSchedules_GetJobSchedule",
  "$responses": {
    "200": {
      "$properties": {
        "jobSpecification": [
          {
            "networkConfiguration": [
              {
                "#name": "subnetId",
                "Description": {
                  "new": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://learn.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration.",
                  "old": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://docs.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration."
                }
              }
            ]
          },
          {
            "jobManagerTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              },
              {
                "outputFiles": {
                  "$properties": {
                    "destination": [
                      {
                        "container": [
                          {
                            "#name": "uploadHeaders",
                            "Description": {
                              "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                              "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                            }
                          }
                        ]
                      }
                    ]
                  }
                }
              }
            ]
          },
          {
            "jobPreparationTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              }
            ]
          },
          {
            "jobReleaseTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              }
            ]
          },
          {
            "poolInfo": [
              {
                "autoPoolSpecification": [
                  {
                    "pool": [
                      {
                        "#name": "vmSize",
                        "Description": {
                          "new": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
                          "old": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
                        }
                      },
                      {
                        "virtualMachineConfiguration": [
                          {
                            "imageReference": [
                              {
                                "#name": "virtualMachineImageId",
                                "Description": {
                                  "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                                  "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                                }
                              }
                            ]
                          },
                          {
                            "#name": "dataDisks",
                            "Description": {
                              "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
                              "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
                            }
                          },
                          {
                            "osDisk": [
                              {
                                "ephemeralOSDiskSettings": [
                                  {
                                    "#name": "placement",
                                    "Description": {
                                      "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                                      "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                                    }
                                  }
                                ]
                              }
                            ]
                          }
                        ]
                      },
                      {
                        "networkConfiguration": [
                          {
                            "#name": "subnetId",
                            "Description": {
                              "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
                              "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
                            }
                          }
                        ]
                      },
                      {
                        "startTask": [
                          {
                            "#name": "commandLine",
                            "Description": {
                              "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                              "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                            }
                          }
                        ]
                      }
                    ]
                  }
                ]
              }
            ]
          }
        ]
      }
    }
  }
}

⚼ Request

GET:  /jobschedules/{jobScheduleId}
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
If-Modified-Since: string ,
If-Unmodified-Since: string ,
If-Match: string ,
If-None-Match: string ,
jobScheduleId: string ,
$select: array ,
$expand: array ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
id: string ,
displayName: string ,
url: string ,
eTag: string ,
lastModified: string ,
creationTime: string ,
state: enum ,
stateTransitionTime: string ,
previousState: enum ,
previousStateTransitionTime: string ,
schedule:
{
doNotRunUntil: string ,
doNotRunAfter: string ,
startWindow: string ,
recurrenceInterval: string ,
}
,
jobSpecification:
{
priority: integer ,
allowTaskPreemption: boolean ,
maxParallelTasks: integer ,
displayName: string ,
usesTaskDependencies: boolean ,
onAllTasksComplete: enum ,
onTaskFailure: enum ,
networkConfiguration:
{
subnetId: string ,
skipWithdrawFromVNet: boolean ,
}
,
constraints:
{
maxWallClockTime: string ,
maxTaskRetryCount: integer ,
}
,
jobManagerTask:
{
id: string ,
displayName: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
killJobOnCompletion: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
runExclusive: boolean ,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
allowLowPriorityNode: boolean ,
}
,
jobPreparationTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
waitForSuccess: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
rerunOnNodeRebootAfterSuccess: boolean ,
}
,
jobReleaseTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
maxWallClockTime: string ,
retentionTime: string ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
}
,
commonEnvironmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
poolInfo:
{
poolId: string ,
autoPoolSpecification:
{
autoPoolIdPrefix: string ,
poolLifetimeOption: enum ,
keepAlive: boolean ,
pool:
{
displayName: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
resizeTimeout: string ,
resourceTags: string ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
targetNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}
,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
executionInfo:
{
nextRunTime: string ,
recentJob:
{
id: string ,
url: string ,
}
,
endTime: string ,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
stats:
{
url: string ,
startTime: string ,
lastUpdateTime: string ,
userCPUTime: string ,
kernelCPUTime: string ,
wallClockTime: string ,
readIOps: integer ,
writeIOps: integer ,
readIOGiB: number ,
writeIOGiB: number ,
numSucceededTasks: integer ,
numFailedTasks: integer ,
numTaskRetries: integer ,
waitTime: string ,
}
,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
JobSchedules_ReplaceJobSchedule (updated)
Description This fully replaces all the updatable properties of the Job Schedule. For example, if the schedule property is not specified with this request, then the Batch service will remove the existing schedule. Changes to a Job Schedule only impact Jobs created by the schedule after the update has taken place; currently running Jobs are unaffected.
Reference Link ¶

⚶ Changes

{
  "#id": "JobSchedules_ReplaceJobSchedule",
  "$parameters": {
    "jobSchedule": {
      "$properties": {
        "jobSpecification": [
          {
            "networkConfiguration": [
              {
                "#name": "subnetId",
                "Description": {
                  "new": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://learn.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration.",
                  "old": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://docs.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration."
                }
              }
            ]
          },
          {
            "jobManagerTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              },
              {
                "outputFiles": {
                  "$properties": {
                    "destination": [
                      {
                        "container": [
                          {
                            "#name": "uploadHeaders",
                            "Description": {
                              "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                              "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                            }
                          }
                        ]
                      }
                    ]
                  }
                }
              }
            ]
          },
          {
            "jobPreparationTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              }
            ]
          },
          {
            "jobReleaseTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              }
            ]
          },
          {
            "poolInfo": [
              {
                "autoPoolSpecification": [
                  {
                    "pool": [
                      {
                        "#name": "vmSize",
                        "Description": {
                          "new": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
                          "old": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
                        }
                      },
                      {
                        "virtualMachineConfiguration": [
                          {
                            "imageReference": [
                              {
                                "#name": "virtualMachineImageId",
                                "Description": {
                                  "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                                  "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                                }
                              }
                            ]
                          },
                          {
                            "#name": "dataDisks",
                            "Description": {
                              "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
                              "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
                            }
                          },
                          {
                            "osDisk": [
                              {
                                "ephemeralOSDiskSettings": [
                                  {
                                    "#name": "placement",
                                    "Description": {
                                      "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                                      "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                                    }
                                  }
                                ]
                              }
                            ]
                          }
                        ]
                      },
                      {
                        "networkConfiguration": [
                          {
                            "#name": "subnetId",
                            "Description": {
                              "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
                              "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
                            }
                          }
                        ]
                      },
                      {
                        "startTask": [
                          {
                            "#name": "commandLine",
                            "Description": {
                              "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                              "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                            }
                          }
                        ]
                      }
                    ]
                  }
                ]
              }
            ]
          }
        ]
      }
    }
  }
}

⚼ Request

PUT:  /jobschedules/{jobScheduleId}
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
If-Modified-Since: string ,
If-Unmodified-Since: string ,
If-Match: string ,
If-None-Match: string ,
jobScheduleId: string ,
jobSchedule:
{
id: string ,
displayName: string ,
url: string ,
eTag: string ,
lastModified: string ,
creationTime: string ,
state: enum ,
stateTransitionTime: string ,
previousState: enum ,
previousStateTransitionTime: string ,
schedule:
{
doNotRunUntil: string ,
doNotRunAfter: string ,
startWindow: string ,
recurrenceInterval: string ,
}
,
jobSpecification:
{
priority: integer ,
allowTaskPreemption: boolean ,
maxParallelTasks: integer ,
displayName: string ,
usesTaskDependencies: boolean ,
onAllTasksComplete: enum ,
onTaskFailure: enum ,
networkConfiguration:
{
subnetId: string ,
skipWithdrawFromVNet: boolean ,
}
,
constraints:
{
maxWallClockTime: string ,
maxTaskRetryCount: integer ,
}
,
jobManagerTask:
{
id: string ,
displayName: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
killJobOnCompletion: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
runExclusive: boolean ,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
allowLowPriorityNode: boolean ,
}
,
jobPreparationTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
waitForSuccess: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
rerunOnNodeRebootAfterSuccess: boolean ,
}
,
jobReleaseTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
maxWallClockTime: string ,
retentionTime: string ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
}
,
commonEnvironmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
poolInfo:
{
poolId: string ,
autoPoolSpecification:
{
autoPoolIdPrefix: string ,
poolLifetimeOption: enum ,
keepAlive: boolean ,
pool:
{
displayName: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
resizeTimeout: string ,
resourceTags: string ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
targetNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}
,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
executionInfo:
{
nextRunTime: string ,
recentJob:
{
id: string ,
url: string ,
}
,
endTime: string ,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
stats:
{
url: string ,
startTime: string ,
lastUpdateTime: string ,
userCPUTime: string ,
kernelCPUTime: string ,
wallClockTime: string ,
readIOps: integer ,
writeIOps: integer ,
readIOGiB: number ,
writeIOGiB: number ,
numSucceededTasks: integer ,
numFailedTasks: integer ,
numTaskRetries: integer ,
waitTime: string ,
}
,
}
,
}

⚐ Response (200)

{
dataserviceid: string ,
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
JobSchedules_UpdateJobSchedule (updated)
Description This replaces only the Job Schedule properties specified in the request. For example, if the schedule property is not specified with this request, then the Batch service will keep the existing schedule. Changes to a Job Schedule only impact Jobs created by the schedule after the update has taken place; currently running Jobs are unaffected.
Reference Link ¶

⚶ Changes

{
  "#id": "JobSchedules_UpdateJobSchedule",
  "$parameters": {
    "jobSchedule": {
      "$properties": {
        "jobSpecification": [
          {
            "networkConfiguration": [
              {
                "#name": "subnetId",
                "Description": {
                  "new": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://learn.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration.",
                  "old": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://docs.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration."
                }
              }
            ]
          },
          {
            "jobManagerTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              },
              {
                "outputFiles": {
                  "$properties": {
                    "destination": [
                      {
                        "container": [
                          {
                            "#name": "uploadHeaders",
                            "Description": {
                              "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                              "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                            }
                          }
                        ]
                      }
                    ]
                  }
                }
              }
            ]
          },
          {
            "jobPreparationTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              }
            ]
          },
          {
            "jobReleaseTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              }
            ]
          },
          {
            "poolInfo": [
              {
                "autoPoolSpecification": [
                  {
                    "pool": [
                      {
                        "#name": "vmSize",
                        "Description": {
                          "new": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
                          "old": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
                        }
                      },
                      {
                        "virtualMachineConfiguration": [
                          {
                            "imageReference": [
                              {
                                "#name": "virtualMachineImageId",
                                "Description": {
                                  "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                                  "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                                }
                              }
                            ]
                          },
                          {
                            "#name": "dataDisks",
                            "Description": {
                              "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
                              "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
                            }
                          },
                          {
                            "osDisk": [
                              {
                                "ephemeralOSDiskSettings": [
                                  {
                                    "#name": "placement",
                                    "Description": {
                                      "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                                      "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                                    }
                                  }
                                ]
                              }
                            ]
                          }
                        ]
                      },
                      {
                        "networkConfiguration": [
                          {
                            "#name": "subnetId",
                            "Description": {
                              "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
                              "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
                            }
                          }
                        ]
                      },
                      {
                        "startTask": [
                          {
                            "#name": "commandLine",
                            "Description": {
                              "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                              "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                            }
                          }
                        ]
                      }
                    ]
                  }
                ]
              }
            ]
          }
        ]
      }
    }
  }
}

⚼ Request

PATCH:  /jobschedules/{jobScheduleId}
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
If-Modified-Since: string ,
If-Unmodified-Since: string ,
If-Match: string ,
If-None-Match: string ,
jobScheduleId: string ,
jobSchedule:
{
schedule:
{
doNotRunUntil: string ,
doNotRunAfter: string ,
startWindow: string ,
recurrenceInterval: string ,
}
,
jobSpecification:
{
priority: integer ,
allowTaskPreemption: boolean ,
maxParallelTasks: integer ,
displayName: string ,
usesTaskDependencies: boolean ,
onAllTasksComplete: enum ,
onTaskFailure: enum ,
networkConfiguration:
{
subnetId: string ,
skipWithdrawFromVNet: boolean ,
}
,
constraints:
{
maxWallClockTime: string ,
maxTaskRetryCount: integer ,
}
,
jobManagerTask:
{
id: string ,
displayName: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
killJobOnCompletion: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
runExclusive: boolean ,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
allowLowPriorityNode: boolean ,
}
,
jobPreparationTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
waitForSuccess: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
rerunOnNodeRebootAfterSuccess: boolean ,
}
,
jobReleaseTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
maxWallClockTime: string ,
retentionTime: string ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
}
,
commonEnvironmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
poolInfo:
{
poolId: string ,
autoPoolSpecification:
{
autoPoolIdPrefix: string ,
poolLifetimeOption: enum ,
keepAlive: boolean ,
pool:
{
displayName: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
resizeTimeout: string ,
resourceTags: string ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
targetNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}
,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}

⚐ Response (200)

{
dataserviceid: string ,
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Jobs_ListJobsFromSchedule (updated)
Description Lists the Jobs that have been created under the specified Job Schedule.
Reference Link ¶

⚶ Changes

{
  "#id": "Jobs_ListJobsFromSchedule",
  "$parameters": [
    {
      "#name": "$filter",
      "Description": {
        "new": "An OData $filter clause. For more information on constructing this filter, see\nhttps://learn.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-jobs-in-a-job-schedule.",
        "old": "An OData $filter clause. For more information on constructing this filter, see\nhttps://docs.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-jobs-in-a-job-schedule."
      }
    }
  ],
  "$responses": {
    "200": {
      "$properties": {
        "value": {
          "$properties": {
            "jobManagerTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Manager Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              },
              {
                "outputFiles": {
                  "$properties": {
                    "destination": [
                      {
                        "container": [
                          {
                            "#name": "uploadHeaders",
                            "Description": {
                              "new": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://learn.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types.",
                              "old": "A list of name-value pairs for headers to be used in uploading output files. These headers will be specified when uploading files to Azure Storage. Official document on allowed headers when uploading blobs: https://docs.microsoft.com/rest/api/storageservices/put-blob#request-headers-all-blob-types."
                            }
                          }
                        ]
                      }
                    ]
                  }
                }
              }
            ],
            "jobPreparationTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Preparation Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              }
            ],
            "jobReleaseTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the Job Release Task. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              }
            ],
            "poolInfo": [
              {
                "autoPoolSpecification": [
                  {
                    "pool": [
                      {
                        "#name": "vmSize",
                        "Description": {
                          "new": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
                          "old": "The size of the virtual machines in the Pool. All virtual machines in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
                        }
                      },
                      {
                        "virtualMachineConfiguration": [
                          {
                            "imageReference": [
                              {
                                "#name": "virtualMachineImageId",
                                "Description": {
                                  "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                                  "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                                }
                              }
                            ]
                          },
                          {
                            "#name": "dataDisks",
                            "Description": {
                              "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
                              "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
                            }
                          },
                          {
                            "osDisk": [
                              {
                                "ephemeralOSDiskSettings": [
                                  {
                                    "#name": "placement",
                                    "Description": {
                                      "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                                      "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                                    }
                                  }
                                ]
                              }
                            ]
                          }
                        ]
                      },
                      {
                        "networkConfiguration": [
                          {
                            "#name": "subnetId",
                            "Description": {
                              "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
                              "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
                            }
                          }
                        ]
                      },
                      {
                        "startTask": [
                          {
                            "#name": "commandLine",
                            "Description": {
                              "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                              "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                            }
                          }
                        ]
                      }
                    ]
                  }
                ]
              }
            ],
            "networkConfiguration": [
              {
                "#name": "subnetId",
                "Description": {
                  "new": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://learn.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration.",
                  "old": "The ARM resource identifier of the virtual network subnet which Compute Nodes running Tasks from the Job will join for the duration of the Task. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes which will run Tasks from the Job. This can be up to the number of Compute Nodes in the Pool. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet so that Azure Batch service can schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication from the Azure Batch service. For Pools created with a Virtual Machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. Port 443 is also required to be open for outbound connections for communications to Azure Storage. For more details see: https://docs.microsoft.com/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration."
                }
              }
            ]
          }
        }
      }
    }
  }
}

⚼ Request

GET:  /jobschedules/{jobScheduleId}/jobs
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
maxresults: integer ,
jobScheduleId: string ,
$filter: string ,
$select: array ,
$expand: array ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
value:
[
{
id: string ,
displayName: string ,
usesTaskDependencies: boolean ,
url: string ,
eTag: string ,
lastModified: string ,
creationTime: string ,
state: enum ,
stateTransitionTime: string ,
previousState: enum ,
previousStateTransitionTime: string ,
priority: integer ,
allowTaskPreemption: boolean ,
maxParallelTasks: integer ,
constraints:
{
maxWallClockTime: string ,
maxTaskRetryCount: integer ,
}
,
jobManagerTask:
{
id: string ,
displayName: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
outputFiles:
[
{
filePattern: string ,
destination:
{
container:
{
path: string ,
containerUrl: string ,
identityReference:
{
resourceId: string ,
}
,
uploadHeaders:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
uploadOptions:
{
uploadCondition: enum ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
requiredSlots: integer ,
killJobOnCompletion: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
runExclusive: boolean ,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
authenticationTokenSettings:
{
access:
[
string ,
]
,
}
,
allowLowPriorityNode: boolean ,
}
,
jobPreparationTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
constraints:
{
maxWallClockTime: string ,
retentionTime: string ,
maxTaskRetryCount: integer ,
}
,
waitForSuccess: boolean ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
rerunOnNodeRebootAfterSuccess: boolean ,
}
,
jobReleaseTask:
{
id: string ,
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
maxWallClockTime: string ,
retentionTime: string ,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
}
,
commonEnvironmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
poolInfo:
{
poolId: string ,
autoPoolSpecification:
{
autoPoolIdPrefix: string ,
poolLifetimeOption: enum ,
keepAlive: boolean ,
pool:
{
displayName: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
resizeTimeout: string ,
resourceTags: string ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
targetNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}
,
}
,
onAllTasksComplete: enum ,
onTaskFailure: enum ,
networkConfiguration:
{
subnetId: string ,
skipWithdrawFromVNet: boolean ,
}
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
executionInfo:
{
startTime: string ,
endTime: string ,
poolId: string ,
schedulingError:
{
category: enum ,
code: string ,
message: string ,
details:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
terminateReason: string ,
}
,
stats:
{
url: string ,
startTime: string ,
lastUpdateTime: string ,
userCPUTime: string ,
kernelCPUTime: string ,
wallClockTime: string ,
readIOps: integer ,
writeIOps: integer ,
readIOGiB: number ,
writeIOGiB: number ,
numSucceededTasks: integer ,
numFailedTasks: integer ,
numTaskRetries: integer ,
waitTime: string ,
}
,
}
,
]
,
odata.nextLink: string ,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Pools_ListPoolNodeCounts (updated)
Description Gets the number of Compute Nodes in each state, grouped by Pool. Note that the numbers returned may not always be up to date. If you need exact node counts, use a list query.
Reference Link ¶

⚶ Changes

{
  "#id": "Pools_ListPoolNodeCounts",
  "$parameters": [
    {
      "#name": "$filter",
      "Description": {
        "new": "An OData $filter clause. For more information on constructing this filter, see\nhttps://learn.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-support-images.",
        "old": "An OData $filter clause. For more information on constructing this filter, see\nhttps://docs.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-support-images."
      }
    }
  ]
}

⚼ Request

GET:  /nodecounts
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
maxresults: integer ,
$filter: string ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
value:
[
{
poolId: string ,
dedicated:
{
creating: integer ,
idle: integer ,
offline: integer ,
preempted: integer ,
rebooting: integer ,
reimaging: integer ,
running: integer ,
starting: integer ,
startTaskFailed: integer ,
leavingPool: integer ,
unknown: integer ,
unusable: integer ,
waitingForStartTask: integer ,
deallocated: integer ,
deallocating: integer ,
total: integer ,
upgradingOS: integer ,
}
,
lowPriority:
{
creating: integer ,
idle: integer ,
offline: integer ,
preempted: integer ,
rebooting: integer ,
reimaging: integer ,
running: integer ,
starting: integer ,
startTaskFailed: integer ,
leavingPool: integer ,
unknown: integer ,
unusable: integer ,
waitingForStartTask: integer ,
deallocated: integer ,
deallocating: integer ,
total: integer ,
upgradingOS: integer ,
}
,
}
,
]
,
odata.nextLink: string ,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Pools_ListPools (updated)
Description Lists all of the Pools which be mounted.
Reference Link ¶

⚶ Changes

{
  "#id": "Pools_ListPools",
  "$parameters": [
    {
      "#name": "$filter",
      "Description": {
        "new": "An OData $filter clause. For more information on constructing this filter, see\nhttps://learn.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-pools.",
        "old": "An OData $filter clause. For more information on constructing this filter, see\nhttps://docs.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-pools."
      }
    }
  ],
  "$responses": {
    "200": {
      "$properties": {
        "value": {
          "$properties": {
            "virtualMachineConfiguration": [
              {
                "imageReference": [
                  {
                    "#name": "virtualMachineImageId",
                    "Description": {
                      "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                      "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                    }
                  }
                ]
              },
              {
                "#name": "dataDisks",
                "Description": {
                  "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
                  "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
                }
              },
              {
                "osDisk": [
                  {
                    "ephemeralOSDiskSettings": [
                      {
                        "#name": "placement",
                        "Description": {
                          "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                          "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                        }
                      }
                    ]
                  }
                ]
              }
            ],
            "networkConfiguration": [
              {
                "#name": "subnetId",
                "Description": {
                  "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
                  "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
                }
              }
            ],
            "startTask": [
              {
                "#name": "commandLine",
                "Description": {
                  "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                  "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                }
              }
            ]
          }
        }
      }
    }
  }
}

⚼ Request

GET:  /pools
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
maxresults: integer ,
$filter: string ,
$select: array ,
$expand: array ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
value:
[
{
id: string ,
displayName: string ,
url: string ,
eTag: string ,
lastModified: string ,
creationTime: string ,
state: enum ,
stateTransitionTime: string ,
allocationState: enum ,
allocationStateTransitionTime: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
resizeTimeout: string ,
resizeErrors:
[
{
code: string ,
message: string ,
values:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
]
,
resourceTags: object ,
currentDedicatedNodes: integer ,
currentLowPriorityNodes: integer ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
autoScaleRun:
{
timestamp: string ,
results: string ,
error:
{
code: string ,
message: string ,
values:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
stats:
{
url: string ,
startTime: string ,
lastUpdateTime: string ,
usageStats:
{
startTime: string ,
lastUpdateTime: string ,
dedicatedCoreTime: string ,
}
,
resourceStats:
{
startTime: string ,
lastUpdateTime: string ,
avgCPUPercentage: number ,
avgMemoryGiB: number ,
peakMemoryGiB: number ,
avgDiskGiB: number ,
peakDiskGiB: number ,
diskReadIOps: integer ,
diskWriteIOps: integer ,
diskReadGiB: number ,
diskWriteGiB: number ,
networkReadGiB: number ,
networkWriteGiB: number ,
}
,
}
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
identity:
{
type: enum ,
userAssignedIdentities:
[
{
resourceId: string ,
clientId: string ,
principalId: string ,
}
,
]
,
}
,
targetNodeCommunicationMode: enum ,
currentNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
]
,
odata.nextLink: string ,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Pools_CreatePool (updated)
Description When naming Pools, avoid including sensitive information such as user names or secret project names. This information may appear in telemetry logs accessible to Microsoft Support engineers.
Reference Link ¶

⚶ Changes

{
  "#id": "Pools_CreatePool",
  "$parameters": {
    "pool": {
      "$properties": {
        "virtualMachineConfiguration": [
          {
            "imageReference": [
              {
                "#name": "virtualMachineImageId",
                "Description": {
                  "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                  "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                }
              }
            ]
          },
          {
            "#name": "dataDisks",
            "Description": {
              "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
              "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
            }
          },
          {
            "osDisk": [
              {
                "ephemeralOSDiskSettings": [
                  {
                    "#name": "placement",
                    "Description": {
                      "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                      "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                    }
                  }
                ]
              }
            ]
          }
        ],
        "networkConfiguration": [
          {
            "#name": "subnetId",
            "Description": {
              "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
              "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
            }
          }
        ],
        "startTask": [
          {
            "#name": "commandLine",
            "Description": {
              "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
              "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
            }
          }
        ]
      }
    }
  }
}

⚼ Request

POST:  /pools
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
pool:
{
id: string ,
displayName: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
resizeTimeout: string ,
resourceTags: object ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
targetNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}

⚐ Response (201)

{
dataserviceid: string ,
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Pools_GetPool (updated)
Description Gets information about the specified Pool.
Reference Link ¶

⚶ Changes

{
  "#id": "Pools_GetPool",
  "$responses": {
    "200": {
      "$properties": {
        "virtualMachineConfiguration": [
          {
            "imageReference": [
              {
                "#name": "virtualMachineImageId",
                "Description": {
                  "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                  "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                }
              }
            ]
          },
          {
            "#name": "dataDisks",
            "Description": {
              "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.",
              "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine."
            }
          },
          {
            "osDisk": [
              {
                "ephemeralOSDiskSettings": [
                  {
                    "#name": "placement",
                    "Description": {
                      "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.",
                      "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements."
                    }
                  }
                ]
              }
            ]
          }
        ],
        "networkConfiguration": [
          {
            "#name": "subnetId",
            "Description": {
              "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration",
              "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration"
            }
          }
        ],
        "startTask": [
          {
            "#name": "commandLine",
            "Description": {
              "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
              "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
            }
          }
        ]
      }
    }
  }
}

⚼ Request

GET:  /pools/{poolId}
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
If-Modified-Since: string ,
If-Unmodified-Since: string ,
If-Match: string ,
If-None-Match: string ,
poolId: string ,
$select: array ,
$expand: array ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
id: string ,
displayName: string ,
url: string ,
eTag: string ,
lastModified: string ,
creationTime: string ,
state: enum ,
stateTransitionTime: string ,
allocationState: enum ,
allocationStateTransitionTime: string ,
vmSize: string ,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
resizeTimeout: string ,
resizeErrors:
[
{
code: string ,
message: string ,
values:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
]
,
resourceTags: object ,
currentDedicatedNodes: integer ,
currentLowPriorityNodes: integer ,
targetDedicatedNodes: integer ,
targetLowPriorityNodes: integer ,
enableAutoScale: boolean ,
autoScaleFormula: string ,
autoScaleEvaluationInterval: string ,
autoScaleRun:
{
timestamp: string ,
results: string ,
error:
{
code: string ,
message: string ,
values:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
}
,
enableInterNodeCommunication: boolean ,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
stats:
{
url: string ,
startTime: string ,
lastUpdateTime: string ,
usageStats:
{
startTime: string ,
lastUpdateTime: string ,
dedicatedCoreTime: string ,
}
,
resourceStats:
{
startTime: string ,
lastUpdateTime: string ,
avgCPUPercentage: number ,
avgMemoryGiB: number ,
peakMemoryGiB: number ,
avgDiskGiB: number ,
peakDiskGiB: number ,
diskReadIOps: integer ,
diskWriteIOps: integer ,
diskReadGiB: number ,
diskWriteGiB: number ,
networkReadGiB: number ,
networkWriteGiB: number ,
}
,
}
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
identity:
{
type: enum ,
userAssignedIdentities:
[
{
resourceId: string ,
clientId: string ,
principalId: string ,
}
,
]
,
}
,
targetNodeCommunicationMode: enum ,
currentNodeCommunicationMode: enum ,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Pools_UpdatePool (updated)
Description This only replaces the Pool properties specified in the request. For example, if the Pool has a StartTask associated with it, and a request does not specify a StartTask element, then the Pool keeps the existing StartTask.
Reference Link ¶

⚶ Changes

{
  "#id": "Pools_UpdatePool",
  "$parameters": {
    "pool": {
      "$properties": [
        {
          "#name": "vmSize",
          "Description": {
            "new": "The size of virtual machines in the Pool. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).

This field can be updated only when the pool is empty.", "old": "The size of virtual machines in the Pool. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes).

This field can be updated only when the pool is empty." } }, { "startTask": [ { "#name": "commandLine", "Description": { "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).", "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)." } } ] }, { "virtualMachineConfiguration": [ { "imageReference": [ { "#name": "virtualMachineImageId", "Description": { "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.", "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration." } } ] }, { "#name": "dataDisks", "Description": { "new": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://learn.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://learn.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine.", "old": "The configuration for data disks attached to the Compute Nodes in the Pool. This property must be specified if the Compute Nodes in the Pool need to have empty data disks attached to them. This cannot be updated. Each Compute Node gets its own disk (the disk is not a file share). Existing disks cannot be attached, each attached disk is empty. When the Compute Node is removed from the Pool, the disk and all data associated with it is also deleted. The disk is not formatted after being attached, it must be formatted before use - for more information see https://docs.microsoft.com/azure/virtual-machines/linux/classic/attach-disk#initialize-a-new-data-disk-in-linux and https://docs.microsoft.com/azure/virtual-machines/windows/attach-disk-ps#add-an-empty-data-disk-to-a-virtual-machine." } }, { "osDisk": [ { "ephemeralOSDiskSettings": [ { "#name": "placement", "Description": { "new": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://learn.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://learn.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.", "old": "Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. This property can be used by user in the request to choose the location e.g., cache disk space for Ephemeral OS disk provisioning. For more information on Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at https://docs.microsoft.com/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux VMs at https://docs.microsoft.com/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements." } } ] } ] } ] }, { "networkConfiguration": [ { "#name": "subnetId", "Description": { "new": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration", "old": "The ARM resource identifier of the virtual network subnet which the Compute Nodes of the Pool will join. This is of the form /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. The virtual network must be in the same region and subscription as the Azure Batch Account. The specified subnet should have enough free IP addresses to accommodate the number of Compute Nodes in the Pool. If the subnet doesn't have enough free IP addresses, the Pool will partially allocate Nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule Tasks on the Nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the Nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the Compute Nodes to unusable. Only ARM virtual networks ('Microsoft.Network/virtualNetworks') are supported. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication, including ports 29876 and 29877. Also enable outbound connections to Azure Storage on port 443. For more details see: https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration" } } ] } ] } } }

⚼ Request

PATCH:  /pools/{poolId}
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
If-Modified-Since: string ,
If-Unmodified-Since: string ,
If-Match: string ,
If-None-Match: string ,
poolId: string ,
pool:
{
displayName: string ,
vmSize: string ,
enableInterNodeCommunication: boolean ,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
virtualMachineConfiguration:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
nodeAgentSKUId: string ,
windowsConfiguration:
{
enableAutomaticUpdates: boolean ,
}
,
dataDisks:
[
{
lun: integer ,
caching: enum ,
diskSizeGB: integer ,
storageAccountType: enum ,
}
,
]
,
licenseType: string ,
containerConfiguration:
{
type: enum ,
containerImageNames:
[
string ,
]
,
containerRegistries:
[
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
}
,
diskEncryptionConfiguration:
{
targets:
[
string ,
]
,
}
,
nodePlacementConfiguration:
{
policy: enum ,
}
,
extensions:
[
{
name: string ,
publisher: string ,
type: string ,
typeHandlerVersion: string ,
autoUpgradeMinorVersion: boolean ,
enableAutomaticUpgrade: boolean ,
settings: object ,
protectedSettings: object ,
provisionAfterExtensions:
[
string ,
]
,
}
,
]
,
osDisk:
{
ephemeralOSDiskSettings:
{
placement: enum ,
}
,
caching: enum ,
diskSizeGB: integer ,
managedDisk:
{
storageAccountType: enum ,
securityProfile:
{
securityEncryptionType: enum ,
}
,
}
,
writeAcceleratorEnabled: boolean ,
}
,
securityProfile:
{
encryptionAtHost: boolean ,
securityType: enum ,
uefiSettings:
{
secureBootEnabled: boolean ,
vTpmEnabled: boolean ,
}
,
}
,
serviceArtifactReference:
{
id: string ,
}
,
}
,
targetNodeCommunicationMode: enum ,
taskSlotsPerNode: integer ,
taskSchedulingPolicy:
{
nodeFillType: enum ,
}
,
networkConfiguration:
{
subnetId: string ,
dynamicVNetAssignmentScope: enum ,
endpointConfiguration:
{
inboundNATPools:
[
{
name: string ,
protocol: enum ,
backendPort: integer ,
frontendPortRangeStart: integer ,
frontendPortRangeEnd: integer ,
networkSecurityGroupRules:
[
{
priority: integer ,
access: enum ,
sourceAddressPrefix: string ,
sourcePortRanges:
[
string ,
]
,
}
,
]
,
}
,
]
,
}
,
publicIPAddressConfiguration:
{
provision: enum ,
ipAddressIds:
[
string ,
]
,
}
,
enableAcceleratedNetworking: boolean ,
}
,
resourceTags: object ,
userAccounts:
[
{
name: string ,
password: string ,
elevationLevel: enum ,
linuxUserConfiguration:
{
uid: integer ,
gid: integer ,
sshPrivateKey: string ,
}
,
windowsUserConfiguration:
{
loginMode: enum ,
}
,
}
,
]
,
mountConfiguration:
[
{
azureBlobFileSystemConfiguration:
{
accountName: string ,
containerName: string ,
accountKey: string ,
sasKey: string ,
blobfuseOptions: string ,
relativeMountPath: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
nfsMountConfiguration:
{
source: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
cifsMountConfiguration:
{
username: string ,
source: string ,
relativeMountPath: string ,
mountOptions: string ,
password: string ,
}
,
azureFileShareConfiguration:
{
accountName: string ,
azureFileUrl: string ,
accountKey: string ,
relativeMountPath: string ,
mountOptions: string ,
}
,
}
,
]
,
upgradePolicy:
{
mode: enum ,
automaticOSUpgradePolicy:
{
disableAutomaticRollback: boolean ,
enableAutomaticOSUpgrade: boolean ,
useRollingUpgradePolicy: boolean ,
osRollingUpgradeDeferral: boolean ,
}
,
rollingUpgradePolicy:
{
enableCrossZoneUpgrade: boolean ,
maxBatchInstancePercent: integer ,
maxUnhealthyInstancePercent: integer ,
maxUnhealthyUpgradedInstancePercent: integer ,
pauseTimeBetweenBatches: string ,
prioritizeUnhealthyInstances: boolean ,
rollbackFailedInstancesOnPolicyBreach: boolean ,
}
,
}
,
}
,
}

⚐ Response (200)

{
dataserviceid: string ,
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Nodes_ListNodes (updated)
Description Lists the Compute Nodes in the specified Pool.
Reference Link ¶

⚶ Changes

{
  "#id": "Nodes_ListNodes",
  "$parameters": [
    {
      "#name": "$filter",
      "Description": {
        "new": "An OData $filter clause. For more information on constructing this filter, see\nhttps://learn.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-nodes-in-a-pool.",
        "old": "An OData $filter clause. For more information on constructing this filter, see\nhttps://docs.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-nodes-in-a-pool."
      }
    }
  ],
  "$responses": {
    "200": {
      "$properties": {
        "value": {
          "$properties": [
            {
              "#name": "vmSize",
              "Description": {
                "new": "The size of the virtual machine hosting the Compute Node. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
                "old": "The size of the virtual machine hosting the Compute Node. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
              }
            },
            {
              "startTask": [
                {
                  "#name": "commandLine",
                  "Description": {
                    "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                    "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
                  }
                }
              ]
            },
            {
              "virtualMachineInfo": [
                {
                  "imageReference": [
                    {
                      "#name": "virtualMachineImageId",
                      "Description": {
                        "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                        "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                      }
                    }
                  ]
                }
              ]
            }
          ]
        }
      }
    }
  }
}

⚼ Request

GET:  /pools/{poolId}/nodes
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
maxresults: integer ,
poolId: string ,
$filter: string ,
$select: array ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
value:
[
{
id: string ,
url: string ,
state: enum ,
schedulingState: enum ,
stateTransitionTime: string ,
lastBootTime: string ,
allocationTime: string ,
ipAddress: string ,
affinityId: string ,
vmSize: string ,
totalTasksRun: integer ,
runningTasksCount: integer ,
runningTaskSlotsCount: integer ,
totalTasksSucceeded: integer ,
recentTasks:
[
{
taskUrl: string ,
jobId: string ,
taskId: string ,
subtaskId: integer ,
taskState: enum ,
executionInfo:
{
startTime: string ,
endTime: string ,
exitCode: integer ,
containerInfo:
{
containerId: string ,
state: string ,
error: string ,
}
,
failureInfo:
{
category: enum ,
code: string ,
message: string ,
details:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
retryCount: integer ,
lastRetryTime: string ,
requeueCount: integer ,
lastRequeueTime: string ,
result: enum ,
}
,
}
,
]
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
startTaskInfo:
{
state: enum ,
startTime: string ,
endTime: string ,
exitCode: integer ,
containerInfo:
{
containerId: string ,
state: string ,
error: string ,
}
,
failureInfo:
{
category: enum ,
code: string ,
message: string ,
details:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
retryCount: integer ,
lastRetryTime: string ,
result: enum ,
}
,
errors:
[
{
code: string ,
message: string ,
errorDetails:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
]
,
isDedicated: boolean ,
endpointConfiguration:
{
inboundEndpoints:
[
{
name: string ,
protocol: enum ,
publicIPAddress: string ,
publicFQDN: string ,
frontendPort: integer ,
backendPort: integer ,
}
,
]
,
}
,
nodeAgentInfo:
{
version: string ,
lastUpdateTime: string ,
}
,
virtualMachineInfo:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
scaleSetVmResourceId: string ,
}
,
}
,
]
,
odata.nextLink: string ,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Nodes_GetNode (updated)
Description Gets information about the specified Compute Node.
Reference Link ¶

⚶ Changes

{
  "#id": "Nodes_GetNode",
  "$responses": {
    "200": {
      "$properties": [
        {
          "#name": "vmSize",
          "Description": {
            "new": "The size of the virtual machine hosting the Compute Node. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
            "old": "The size of the virtual machine hosting the Compute Node. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
          }
        },
        {
          "startTask": [
            {
              "#name": "commandLine",
              "Description": {
                "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
                "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
              }
            }
          ]
        },
        {
          "virtualMachineInfo": [
            {
              "imageReference": [
                {
                  "#name": "virtualMachineImageId",
                  "Description": {
                    "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                    "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                  }
                }
              ]
            }
          ]
        }
      ]
    }
  }
}

⚼ Request

GET:  /pools/{poolId}/nodes/{nodeId}
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
poolId: string ,
nodeId: string ,
$select: array ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
id: string ,
url: string ,
state: enum ,
schedulingState: enum ,
stateTransitionTime: string ,
lastBootTime: string ,
allocationTime: string ,
ipAddress: string ,
affinityId: string ,
vmSize: string ,
totalTasksRun: integer ,
runningTasksCount: integer ,
runningTaskSlotsCount: integer ,
totalTasksSucceeded: integer ,
recentTasks:
[
{
taskUrl: string ,
jobId: string ,
taskId: string ,
subtaskId: integer ,
taskState: enum ,
executionInfo:
{
startTime: string ,
endTime: string ,
exitCode: integer ,
containerInfo:
{
containerId: string ,
state: string ,
error: string ,
}
,
failureInfo:
{
category: enum ,
code: string ,
message: string ,
details:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
retryCount: integer ,
lastRetryTime: string ,
requeueCount: integer ,
lastRequeueTime: string ,
result: enum ,
}
,
}
,
]
,
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
startTaskInfo:
{
state: enum ,
startTime: string ,
endTime: string ,
exitCode: integer ,
containerInfo:
{
containerId: string ,
state: string ,
error: string ,
}
,
failureInfo:
{
category: enum ,
code: string ,
message: string ,
details:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
retryCount: integer ,
lastRetryTime: string ,
result: enum ,
}
,
errors:
[
{
code: string ,
message: string ,
errorDetails:
[
{
name: string ,
value: string ,
}
,
]
,
}
,
]
,
isDedicated: boolean ,
endpointConfiguration:
{
inboundEndpoints:
[
{
name: string ,
protocol: enum ,
publicIPAddress: string ,
publicFQDN: string ,
frontendPort: integer ,
backendPort: integer ,
}
,
]
,
}
,
nodeAgentInfo:
{
version: string ,
lastUpdateTime: string ,
}
,
virtualMachineInfo:
{
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
scaleSetVmResourceId: string ,
}
,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Nodes_ListNodeFiles (updated)
Description Lists all of the files in Task directories on the specified Compute Node.
Reference Link ¶

⚶ Changes

{
  "#id": "Nodes_ListNodeFiles",
  "$parameters": [
    {
      "#name": "$filter",
      "Description": {
        "new": "An OData $filter clause. For more information on constructing this filter, see\nhttps://learn.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-compute-node-files.",
        "old": "An OData $filter clause. For more information on constructing this filter, see\nhttps://docs.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-compute-node-files."
      }
    }
  ]
}

⚼ Request

GET:  /pools/{poolId}/nodes/{nodeId}/files
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
maxresults: integer ,
poolId: string ,
nodeId: string ,
$filter: string ,
recursive: boolean ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
value:
[
{
name: string ,
url: string ,
isDirectory: boolean ,
properties:
{
creationTime: string ,
lastModified: string ,
contentLength: string ,
contentType: string ,
fileMode: string ,
}
,
}
,
]
,
odata.nextLink: string ,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Pools_ReplacePoolProperties (updated)
Description This fully replaces all the updatable properties of the Pool. For example, if the Pool has a StartTask associated with it and if StartTask is not specified with this request, then the Batch service will remove the existing StartTask.
Reference Link ¶

⚶ Changes

{
  "#id": "Pools_ReplacePoolProperties",
  "$parameters": {
    "pool": {
      "$properties": {
        "startTask": [
          {
            "#name": "commandLine",
            "Description": {
              "new": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://learn.microsoft.com/azure/batch/batch-compute-node-environment-variables).",
              "old": "The command line of the StartTask. The command line does not run under a shell, and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take advantage of such features, you should invoke the shell in the command line, for example using \"cmd /c MyCommand\" in Windows or \"/bin/sh -c MyCommand\" in Linux. If the command line refers to file paths, it should use a relative path (relative to the Task working directory), or use the Batch provided environment variable (https://docs.microsoft.com/azure/batch/batch-compute-node-environment-variables)."
            }
          }
        ]
      }
    }
  }
}

⚼ Request

POST:  /pools/{poolId}/updateproperties
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
poolId: string ,
pool:
{
startTask:
{
commandLine: string ,
containerSettings:
{
containerRunOptions: string ,
imageName: string ,
registry:
{
username: string ,
password: string ,
registryServer: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
workingDirectory: enum ,
containerHostBatchBindMounts:
[
{
source: enum ,
isReadOnly: boolean ,
}
,
]
,
}
,
resourceFiles:
[
{
autoStorageContainerName: string ,
storageContainerUrl: string ,
httpUrl: string ,
blobPrefix: string ,
filePath: string ,
fileMode: string ,
identityReference:
{
resourceId: string ,
}
,
}
,
]
,
environmentSettings:
[
{
name: string ,
value: string ,
}
,
]
,
userIdentity:
{
username: string ,
autoUser:
{
scope: enum ,
elevationLevel: enum ,
}
,
}
,
maxTaskRetryCount: integer ,
waitForSuccess: boolean ,
}
,
applicationPackageReferences:
[
{
applicationId: string ,
version: string ,
}
,
]
,
metadata:
[
{
name: string ,
value: string ,
}
,
]
,
targetNodeCommunicationMode: enum ,
}
,
}

⚐ Response (204)

{
dataserviceid: string ,
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Pools_ListPoolUsageMetrics (updated)
Description If you do not specify a $filter clause including a poolId, the response includes all Pools that existed in the Account in the time range of the returned aggregation intervals. If you do not specify a $filter clause including a startTime or endTime these filters default to the start and end times of the last aggregation interval currently available; that is, only the last aggregation interval is returned.
Reference Link ¶

⚶ Changes

{
  "#id": "Pools_ListPoolUsageMetrics",
  "$parameters": [
    {
      "#name": "$filter",
      "Description": {
        "new": "An OData $filter clause. For more information on constructing this filter, see\nhttps://learn.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-account-usage-metrics.",
        "old": "An OData $filter clause. For more information on constructing this filter, see\nhttps://docs.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-account-usage-metrics."
      }
    }
  ],
  "$responses": {
    "200": {
      "$properties": {
        "value": {
          "$properties": [
            {
              "#name": "vmSize",
              "Description": {
                "new": "The size of virtual machines in the Pool. All VMs in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://learn.microsoft.com/azure/batch/batch-pool-vm-sizes).",
                "old": "The size of virtual machines in the Pool. All VMs in a Pool are the same size. For information about available sizes of virtual machines in Pools, see Choose a VM size for Compute Nodes in an Azure Batch Pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes)."
              }
            }
          ]
        }
      }
    }
  }
}

⚼ Request

GET:  /poolusagemetrics
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
maxresults: integer ,
startTime: string ,
endtime: string ,
$filter: string ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
value:
[
{
poolId: string ,
startTime: string ,
endTime: string ,
vmSize: string ,
totalCoreHours: number ,
}
,
]
,
odata.nextLink: string ,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}
Pools_ListSupportedImages (updated)
Description Lists all Virtual Machine Images supported by the Azure Batch service.
Reference Link ¶

⚶ Changes

{
  "#id": "Pools_ListSupportedImages",
  "$parameters": [
    {
      "#name": "$filter",
      "Description": {
        "new": "An OData $filter clause. For more information on constructing this filter, see\nhttps://learn.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-support-images.",
        "old": "An OData $filter clause. For more information on constructing this filter, see\nhttps://docs.microsoft.com/rest/api/batchservice/odata-filters-in-batch#list-support-images."
      }
    }
  ],
  "$responses": {
    "200": {
      "$properties": {
        "value": {
          "$properties": {
            "imageReference": [
              {
                "#name": "virtualMachineImageId",
                "Description": {
                  "new": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://learn.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration.",
                  "old": "The ARM resource identifier of the Azure Compute Gallery Image. Compute Nodes in the Pool will be created using this Image Id. This is of the form /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{VersionId} or /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName} for always defaulting to the latest image version. This property is mutually exclusive with other ImageReference properties. The Azure Compute Gallery Image must have replicas in the same region and must be in the same subscription as the Azure Batch account. If the image version is not specified in the imageId, the latest version will be used. For information about the firewall settings for the Batch Compute Node agent to communicate with the Batch service see https://docs.microsoft.com/azure/batch/nodes-and-pools#virtual-network-vnet-and-firewall-configuration."
                }
              }
            ]
          }
        }
      }
    }
  }
}

⚼ Request

GET:  /supportedimages
{
api-version: string ,
timeOut: integer ,
client-request-id: string ,
return-client-request-id: boolean ,
ocp-date: string ,
maxresults: integer ,
$filter: string ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
last-modified: string ,
client-request-id: string ,
request-id: string ,
}
,
$schema:
{
value:
[
{
nodeAgentSKUId: string ,
imageReference:
{
publisher: string ,
offer: string ,
sku: string ,
version: string ,
virtualMachineImageId: string ,
exactVersion: string ,
sharedGalleryImageId: string ,
communityGalleryImageId: string ,
}
,
osType: enum ,
capabilities:
[
string ,
]
,
batchSupportEndOfLife: string ,
verificationType: enum ,
}
,
]
,
odata.nextLink: string ,
}
,
}

⚐ Response (default)

{
code: string ,
message:
{
lang: string ,
value: string ,
}
,
values:
[
{
key: string ,
value: string ,
}
,
]
,
}