/// <summary> /// Submits a Sqoop job to an HDInsight cluster. /// </summary> /// <param name='operations'> /// Reference to the /// Microsoft.Azure.Management.HDInsight.Job.IJobOperations. /// </param> /// <param name='parameters'> /// Required. Sqoop job parameters. /// </param> /// <returns> /// The Create Job operation response. /// </returns> public static JobSubmissionResponse SubmitSqoopJob(this IJobOperations operations, JobSubmissionParameters parameters) { return(Task.Factory.StartNew((object s) => { return ((IJobOperations)s).SubmitSqoopJobAsync(parameters); } , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult()); }
/// <summary> /// Submits a Sqoop job to an HDInsight cluster. /// </summary> /// <param name='operations'> /// Reference to the /// Microsoft.Azure.Management.HDInsight.Job.IJobOperations. /// </param> /// <param name='parameters'> /// Required. Sqoop job parameters. /// </param> /// <returns> /// The Create Job operation response. /// </returns> public static Task <JobSubmissionResponse> SubmitSqoopJobAsync(this IJobOperations operations, JobSubmissionParameters parameters) { return(operations.SubmitSqoopJobAsync(parameters, CancellationToken.None)); }
/// <summary> /// Submits a MapReduce streaming job to an HDINSIGHT cluster. /// </summary> /// <param name='operations'> /// Reference to the /// Microsoft.Azure.Management.HDInsight.Job.IJobOperations. /// </param> /// <param name='parameters'> /// Required. MapReduce job parameters. /// </param> /// <returns> /// The Create Job operation response. /// </returns> internal static Task <JobSubmissionResponse> SubmitMapReduceStreamingJobAsync(this IJobOperations operations, JobSubmissionParameters parameters) { return(operations.SubmitMapReduceStreamingJobAsync(parameters, CancellationToken.None)); }