/// <summary>
 /// Creates a Job in the given Experiment.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// Name of the resource group to which the resource belongs.
 /// </param>
 /// <param name='workspaceName'>
 /// The name of the workspace. Workspace names can only contain a combination
 /// of alphanumeric characters along with dash (-) and underscore (_). The name
 /// must be from 1 through 64 characters long.
 /// </param>
 /// <param name='experimentName'>
 /// The name of the experiment. Experiment names can only contain a combination
 /// of alphanumeric characters along with dash (-) and underscore (_). The name
 /// must be from 1 through 64 characters long.
 /// </param>
 /// <param name='jobName'>
 /// The name of the job within the specified resource group. Job names can only
 /// contain a combination of alphanumeric characters along with dash (-) and
 /// underscore (_). The name must be from 1 through 64 characters long.
 /// </param>
 /// <param name='parameters'>
 /// The parameters to provide for job creation.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <JobInner> CreateAsync(this IJobsOperations operations, string resourceGroupName, string workspaceName, string experimentName, string jobName, JobCreateParameters parameters, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CreateWithHttpMessagesAsync(resourceGroupName, workspaceName, experimentName, jobName, parameters, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Creates a new job with the specified parameters. Existing job cannot be
 /// updated with this API and should instead be updated with the Update job
 /// API.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The Resource Group Name
 /// </param>
 /// <param name='jobName'>
 /// The name of the job Resource within the specified resource group. job names
 /// must be between 3 and 24 characters in length and use any alphanumeric and
 /// underscore only
 /// </param>
 /// <param name='jobResource'>
 /// Job details from request body.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <JobResource> CreateAsync(this IJobsOperations operations, string resourceGroupName, string jobName, JobResource jobResource, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CreateWithHttpMessagesAsync(resourceGroupName, jobName, jobResource, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Пример #3
0
 /// <summary>
 /// Create a job.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='jobId'>
 /// Id of the job.
 /// </param>
 /// <param name='job'>
 /// The complete metadata of the job to submit.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <JobDetails> CreateAsync(this IJobsOperations operations, string jobId, JobDetails job, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CreateWithHttpMessagesAsync(jobId, job, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }