Skip to content

Commit cd48515

Browse files
committed
2 parents 1c561ed + 3cfe341 commit cd48515

File tree

5 files changed

+16
-6
lines changed

5 files changed

+16
-6
lines changed

src/ResourceManager/HDInsight/Commands.HDInsight/JobCommands/NewAzureHDInsightMapReduceJobDefinitionCommand.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,10 @@ public class NewAzureHDInsightMapReduceJobDefinitionCommand : HDInsightCmdletBas
3131

3232
#region Input Parameter Definitions
3333

34-
[Parameter(HelpMessage = "The hive arguments for the jobDetails.")]
34+
[Parameter(HelpMessage = "The arguments for the jobDetails.")]
3535
public string[] Arguments { get; set; }
3636

37-
[Parameter(HelpMessage = "The files for the jobDetails.")]
37+
[Parameter(HelpMessage = "List of files to be copied to the cluster.")]
3838
public string[] Files { get; set; }
3939

4040
[Parameter(HelpMessage = "The output location to use for the job.")]

src/ResourceManager/HDInsight/Commands.HDInsight/JobCommands/NewAzureHDInsightStreamingMapReduceJobDefinitionCommand.cs

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,16 +31,19 @@ public class NewAzureHDInsightStreamingMapReduceJobDefinitionCommand : HDInsight
3131

3232
#region Input Parameter Definitions
3333

34-
[Parameter(HelpMessage = "The hive arguments for the jobDetails.")]
34+
[Parameter(HelpMessage = "The arguments for the jobDetails.")]
3535
public string[] Arguments { get; set; }
3636

37-
[Parameter(HelpMessage = "The file for the jobDetails.")]
37+
[Parameter(HelpMessage = "Local file to be made available to tasks")]
3838
public string File
3939
{
4040
get { return job.File; }
4141
set { job.File = value; }
4242
}
4343

44+
[Parameter(HelpMessage = "List of files to be copied to the cluster.")]
45+
public string[] Files { get; set; }
46+
4447
[Parameter(HelpMessage = "The output location to use for the job.")]
4548
public string StatusFolder
4649
{
@@ -88,6 +91,7 @@ public string Reducer
8891
public NewAzureHDInsightStreamingMapReduceJobDefinitionCommand()
8992
{
9093
Arguments = new string[] {};
94+
Files = new string[] { };
9195
CommandEnvironment = new Hashtable();
9296
Defines = new Hashtable();
9397
job = new AzureHDInsightStreamingMapReduceJobDefinition();
@@ -112,6 +116,11 @@ public override void ExecuteCmdlet()
112116
job.Defines.Add(define.Key, define.Value.ToString());
113117
}
114118

119+
foreach (var file in Files)
120+
{
121+
job.Files.Add(file);
122+
}
123+
115124
WriteObject(job);
116125
}
117126
}

src/ResourceManager/HDInsight/Commands.HDInsight/Models/Job/AzureHDInsightJobDefinition.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ protected AzureHDInsightJobDefinition()
3636
public IList<string> Arguments { get; private set; }
3737

3838
/// <summary>
39-
/// Gets the resources for the jobDetails.
39+
/// Gets the files to be copied to the cluster
4040
/// </summary>
4141
public IList<string> Files { get; private set; }
4242

src/ResourceManager/HDInsight/Commands.HDInsight/Models/Job/AzureHDInsightStreamingMapReduceJobDefinition.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public class AzureHDInsightStreamingMapReduceJobDefinition : AzureHDInsightJobDe
4242
public string Reducer { get; set; }
4343

4444
/// <summary>
45-
/// Gets or sets an HDFS file to add to the distributed cache.
45+
/// Gets or sets a file to add to the distributed cache.
4646
/// </summary>
4747
public string File { get; set; }
4848

src/ResourceManager/HDInsight/Commands.HDInsight/Models/Job/AzureHdInsightJobManagementClient.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ public virtual JobSubmissionResponse SubmitStreamingJob(
9292
Mapper = streamingJobDef.Mapper,
9393
Reducer = streamingJobDef.Reducer,
9494
File = streamingJobDef.File,
95+
Files = streamingJobDef.Files,
9596
Defines = streamingJobDef.Defines,
9697
CmdEnv = streamingJobDef.CommandEnvironment,
9798
Arguments = streamingJobDef.Arguments,

0 commit comments

Comments
 (0)