CloudJob Class

Definition

An Azure Batch job.

public class CloudJob : Microsoft.Azure.Batch.IInheritedBehaviors, Microsoft.Azure.Batch.IRefreshable
type CloudJob = class
    interface IRefreshable
    interface IInheritedBehaviors
Public Class CloudJob
Implements IInheritedBehaviors, IRefreshable
Inheritance
CloudJob
Implements

Properties

CommonEnvironmentSettings

Gets or sets a list of common environment variable settings. These environment variables are set for all tasks in this CloudJob (including the Job Manager, Job Preparation and Job Release tasks).

Constraints

Gets or sets the execution constraints for the job.

CreationTime

Gets the creation time of the job.

CustomBehaviors

Gets or sets a list of behaviors that modify or customize requests to the Batch service made via this CloudJob.

DisplayName

Gets or sets the display name of the job.

ETag

Gets the ETag for the job.

ExecutionInformation

Gets the execution information for the job.

Id

Gets or sets the id of the job.

JobManagerTask

Gets or sets the Job Manager task. The Job Manager task is launched when the CloudJob is started.

JobPreparationTask

Gets or sets the Job Preparation task. The Batch service will run the Job Preparation task on a compute node before starting any tasks of that job on that compute node.

JobReleaseTask

Gets or sets the Job Release task. The Batch service runs the Job Release task when the job ends, on each compute node where any task of the job has run.

LastModified

Gets the last modified time of the job.

Metadata

Gets or sets a list of name-value pairs associated with the job as metadata.

NetworkConfiguration

Gets or sets the network configuration for the job.

OnAllTasksComplete

Gets or sets the action the Batch service should take when all tasks in the job are in the Completed state.

OnTaskFailure

Gets or sets the action the Batch service should take when any task in the job fails.

PoolInformation

Gets or sets the pool on which the Batch service runs the job's tasks.

PreviousState

Gets the previous state of the job.

PreviousStateTransitionTime

Gets the time at which the job entered its previous state.

Priority

Gets or sets the priority of the job. Priority values can range from -1000 to 1000, with -1000 being the lowest priority and 1000 being the highest priority.

State

Gets the current state of the job.

StateTransitionTime

Gets the time at which the job entered its current state.

Statistics

Gets resource usage statistics for the entire lifetime of the job.

Url

Gets the URL of the job.

UsesTaskDependencies

Gets or sets whether tasks in the job can define dependencies on each other.

Methods

AddTask(CloudTask, IEnumerable<BatchClientBehavior>)

Adds a single task to this CloudJob. To add multiple tasks, use AddTask(String, IEnumerable<CloudTask>, BatchClientParallelOptions, ConcurrentBag<ConcurrentDictionary<Type,IFileStagingArtifact>>, Nullable<TimeSpan>, IEnumerable<BatchClientBehavior>).

AddTask(IEnumerable<CloudTask>, BatchClientParallelOptions, ConcurrentBag<ConcurrentDictionary<Type,IFileStagingArtifact>>, Nullable<TimeSpan>, IEnumerable<BatchClientBehavior>)

Adds tasks to a job.

AddTaskAsync(CloudTask, ConcurrentDictionary<Type,IFileStagingArtifact>, IEnumerable<BatchClientBehavior>, CancellationToken)

Adds a single task to this CloudJob. To add multiple tasks, use AddTaskAsync(String, IEnumerable<CloudTask>, BatchClientParallelOptions, ConcurrentBag<ConcurrentDictionary<Type,IFileStagingArtifact>>, Nullable<TimeSpan>, IEnumerable<BatchClientBehavior>).

AddTaskAsync(IEnumerable<CloudTask>, BatchClientParallelOptions, ConcurrentBag<ConcurrentDictionary<Type,IFileStagingArtifact>>, Nullable<TimeSpan>, IEnumerable<BatchClientBehavior>)

Adds tasks to a job.

Commit(IEnumerable<BatchClientBehavior>)

Commits this CloudJob to the Azure Batch service.

CommitAsync(IEnumerable<BatchClientBehavior>, CancellationToken)

Commits this CloudJob to the Azure Batch service.

CommitChanges(IEnumerable<BatchClientBehavior>)

Commits all pending changes to this CloudJob to the Azure Batch service.

CommitChangesAsync(IEnumerable<BatchClientBehavior>, CancellationToken)

Commits all pending changes to this CloudJob to the Azure Batch service.

Delete(IEnumerable<BatchClientBehavior>)

Deletes this CloudJob.

DeleteAsync(IEnumerable<BatchClientBehavior>, CancellationToken)

Deletes this CloudJob.

Disable(DisableJobOption, IEnumerable<BatchClientBehavior>)

Disables this CloudJob. Disabled jobs do not run new tasks, but may be re-enabled later.

DisableAsync(DisableJobOption, IEnumerable<BatchClientBehavior>, CancellationToken)

Disables this CloudJob. Disabled jobs do not run new tasks, but may be re-enabled later.

Enable(IEnumerable<BatchClientBehavior>)

Enables this CloudJob, allowing new tasks to run.

EnableAsync(IEnumerable<BatchClientBehavior>, CancellationToken)

Enables this CloudJob, allowing new tasks to run.

GetTask(String, DetailLevel, IEnumerable<BatchClientBehavior>)

Gets the specified CloudTask.

GetTaskAsync(String, DetailLevel, IEnumerable<BatchClientBehavior>, CancellationToken)

Gets the specified CloudTask.

GetTaskCounts(IEnumerable<BatchClientBehavior>)

Gets the task counts for the job.

GetTaskCountsAsync(IEnumerable<BatchClientBehavior>, CancellationToken)

Gets the task counts for the job.

ListTasks(DetailLevel, IEnumerable<BatchClientBehavior>)

Enumerates the CloudTask of this CloudJob.

Refresh(DetailLevel, IEnumerable<BatchClientBehavior>)

Refreshes the current CloudJob.

RefreshAsync(DetailLevel, IEnumerable<BatchClientBehavior>, CancellationToken)

Refreshes the current CloudJob.

Terminate(String, IEnumerable<BatchClientBehavior>)

Terminates this CloudJob, marking it as completed.

TerminateAsync(String, IEnumerable<BatchClientBehavior>, CancellationToken)

Terminates this CloudJob, marking it as completed.

Extension Methods

GetOutputStorageContainerUrl(CloudJob, CloudStorageAccount)

Gets the URL, including a Shared Access Signature (SAS) that permits writing, for the job's output storage container in Azure blob storage. This URL is suitable for passing to tasks so they can use the JobOutputStorage(Uri) or TaskOutputStorage(Uri, String) constructors that take a Uri.

GetOutputStorageContainerUrl(CloudJob, CloudStorageAccount, TimeSpan)

Gets the URL, including a Shared Access Signature (SAS) that permits writing, for the job's output storage container in Azure blob storage. This URL is suitable for passing to tasks so they can use the JobOutputStorage(Uri) or TaskOutputStorage(Uri, String) constructors that take a Uri.

GetOutputStoragePath(CloudJob, JobOutputKind)

Gets the Blob name prefix/folder where files of the given kind are stored

OutputStorage(CloudJob, CloudStorageAccount)

Gets the JobOutputStorage for a specified CloudJob.

OutputStorageContainerName(CloudJob)

Gets the name of the Azure blob storage container for the outputs of a CloudJob.

PrepareOutputStorageAsync(CloudJob, CloudStorageAccount, CancellationToken)

Creates an Azure blob storage container for the outputs of a CloudJob.

Applies to