flexibleengine.MrsJobV2
Explore with Pulumi AI
Manage a job resource within FlexibleEngine MRS.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as flexibleengine from "@pulumi/flexibleengine";
const config = new pulumi.Config();
const clusterId = config.requireObject("clusterId");
const jobName = config.requireObject("jobName");
const programPath = config.requireObject("programPath");
const accessKey = config.requireObject("accessKey");
const secretKey = config.requireObject("secretKey");
const test = new flexibleengine.MrsJobV2("test", {
clusterId: clusterId,
type: "SparkSubmit",
programPath: programPath,
parameters: `${accessKey} ${secretKey} 1 s3a://obs-demo-analysis/input s3a://obs-demo-analysis/output`,
programParameters: {
"--class": "com.orange.bigdata.spark.examples.DriverBehavior",
},
});
import pulumi
import pulumi_flexibleengine as flexibleengine
config = pulumi.Config()
cluster_id = config.require_object("clusterId")
job_name = config.require_object("jobName")
program_path = config.require_object("programPath")
access_key = config.require_object("accessKey")
secret_key = config.require_object("secretKey")
test = flexibleengine.MrsJobV2("test",
cluster_id=cluster_id,
type="SparkSubmit",
program_path=program_path,
parameters=f"{access_key} {secret_key} 1 s3a://obs-demo-analysis/input s3a://obs-demo-analysis/output",
program_parameters={
"--class": "com.orange.bigdata.spark.examples.DriverBehavior",
})
package main
import (
"fmt"
"github.com/pulumi/pulumi-terraform-provider/sdks/go/flexibleengine/flexibleengine"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
cfg := config.New(ctx, "")
clusterId := cfg.RequireObject("clusterId")
jobName := cfg.RequireObject("jobName")
programPath := cfg.RequireObject("programPath")
accessKey := cfg.RequireObject("accessKey")
secretKey := cfg.RequireObject("secretKey")
_, err := flexibleengine.NewMrsJobV2(ctx, "test", &flexibleengine.MrsJobV2Args{
ClusterId: pulumi.Any(clusterId),
Type: pulumi.String("SparkSubmit"),
ProgramPath: pulumi.Any(programPath),
Parameters: pulumi.Sprintf("%v %v 1 s3a://obs-demo-analysis/input s3a://obs-demo-analysis/output", accessKey, secretKey),
ProgramParameters: pulumi.StringMap{
"--class": pulumi.String("com.orange.bigdata.spark.examples.DriverBehavior"),
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Flexibleengine = Pulumi.Flexibleengine;
return await Deployment.RunAsync(() =>
{
var config = new Config();
var clusterId = config.RequireObject<dynamic>("clusterId");
var jobName = config.RequireObject<dynamic>("jobName");
var programPath = config.RequireObject<dynamic>("programPath");
var accessKey = config.RequireObject<dynamic>("accessKey");
var secretKey = config.RequireObject<dynamic>("secretKey");
var test = new Flexibleengine.MrsJobV2("test", new()
{
ClusterId = clusterId,
Type = "SparkSubmit",
ProgramPath = programPath,
Parameters = $"{accessKey} {secretKey} 1 s3a://obs-demo-analysis/input s3a://obs-demo-analysis/output",
ProgramParameters =
{
{ "--class", "com.orange.bigdata.spark.examples.DriverBehavior" },
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.flexibleengine.MrsJobV2;
import com.pulumi.flexibleengine.MrsJobV2Args;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var config = ctx.config();
final var clusterId = config.get("clusterId");
final var jobName = config.get("jobName");
final var programPath = config.get("programPath");
final var accessKey = config.get("accessKey");
final var secretKey = config.get("secretKey");
var test = new MrsJobV2("test", MrsJobV2Args.builder()
.clusterId(clusterId)
.type("SparkSubmit")
.programPath(programPath)
.parameters(String.format("%s %s 1 s3a://obs-demo-analysis/input s3a://obs-demo-analysis/output", accessKey,secretKey))
.programParameters(Map.of("--class", "com.orange.bigdata.spark.examples.DriverBehavior"))
.build());
}
}
configuration:
clusterId:
type: dynamic
jobName:
type: dynamic
programPath:
type: dynamic
accessKey:
type: dynamic
secretKey:
type: dynamic
resources:
test:
type: flexibleengine:MrsJobV2
properties:
clusterId: ${clusterId}
type: SparkSubmit
programPath: ${programPath}
parameters: ${accessKey} ${secretKey} 1 s3a://obs-demo-analysis/input s3a://obs-demo-analysis/output
programParameters:
--class: com.orange.bigdata.spark.examples.DriverBehavior
Create MrsJobV2 Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new MrsJobV2(name: string, args: MrsJobV2Args, opts?: CustomResourceOptions);
@overload
def MrsJobV2(resource_name: str,
args: MrsJobV2Args,
opts: Optional[ResourceOptions] = None)
@overload
def MrsJobV2(resource_name: str,
opts: Optional[ResourceOptions] = None,
cluster_id: Optional[str] = None,
type: Optional[str] = None,
mrs_job_v2_id: Optional[str] = None,
name: Optional[str] = None,
parameters: Optional[str] = None,
program_parameters: Optional[Mapping[str, str]] = None,
program_path: Optional[str] = None,
region: Optional[str] = None,
service_parameters: Optional[Mapping[str, str]] = None,
sql: Optional[str] = None,
timeouts: Optional[MrsJobV2TimeoutsArgs] = None)
func NewMrsJobV2(ctx *Context, name string, args MrsJobV2Args, opts ...ResourceOption) (*MrsJobV2, error)
public MrsJobV2(string name, MrsJobV2Args args, CustomResourceOptions? opts = null)
public MrsJobV2(String name, MrsJobV2Args args)
public MrsJobV2(String name, MrsJobV2Args args, CustomResourceOptions options)
type: flexibleengine:MrsJobV2
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args MrsJobV2Args
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args MrsJobV2Args
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args MrsJobV2Args
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args MrsJobV2Args
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args MrsJobV2Args
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var mrsJobV2Resource = new Flexibleengine.MrsJobV2("mrsJobV2Resource", new()
{
ClusterId = "string",
Type = "string",
MrsJobV2Id = "string",
Name = "string",
Parameters = "string",
ProgramParameters =
{
{ "string", "string" },
},
ProgramPath = "string",
Region = "string",
ServiceParameters =
{
{ "string", "string" },
},
Sql = "string",
Timeouts = new Flexibleengine.Inputs.MrsJobV2TimeoutsArgs
{
Create = "string",
},
});
example, err := flexibleengine.NewMrsJobV2(ctx, "mrsJobV2Resource", &flexibleengine.MrsJobV2Args{
ClusterId: pulumi.String("string"),
Type: pulumi.String("string"),
MrsJobV2Id: pulumi.String("string"),
Name: pulumi.String("string"),
Parameters: pulumi.String("string"),
ProgramParameters: pulumi.StringMap{
"string": pulumi.String("string"),
},
ProgramPath: pulumi.String("string"),
Region: pulumi.String("string"),
ServiceParameters: pulumi.StringMap{
"string": pulumi.String("string"),
},
Sql: pulumi.String("string"),
Timeouts: &flexibleengine.MrsJobV2TimeoutsArgs{
Create: pulumi.String("string"),
},
})
var mrsJobV2Resource = new MrsJobV2("mrsJobV2Resource", MrsJobV2Args.builder()
.clusterId("string")
.type("string")
.mrsJobV2Id("string")
.name("string")
.parameters("string")
.programParameters(Map.of("string", "string"))
.programPath("string")
.region("string")
.serviceParameters(Map.of("string", "string"))
.sql("string")
.timeouts(MrsJobV2TimeoutsArgs.builder()
.create("string")
.build())
.build());
mrs_job_v2_resource = flexibleengine.MrsJobV2("mrsJobV2Resource",
cluster_id="string",
type="string",
mrs_job_v2_id="string",
name="string",
parameters="string",
program_parameters={
"string": "string",
},
program_path="string",
region="string",
service_parameters={
"string": "string",
},
sql="string",
timeouts={
"create": "string",
})
const mrsJobV2Resource = new flexibleengine.MrsJobV2("mrsJobV2Resource", {
clusterId: "string",
type: "string",
mrsJobV2Id: "string",
name: "string",
parameters: "string",
programParameters: {
string: "string",
},
programPath: "string",
region: "string",
serviceParameters: {
string: "string",
},
sql: "string",
timeouts: {
create: "string",
},
});
type: flexibleengine:MrsJobV2
properties:
clusterId: string
mrsJobV2Id: string
name: string
parameters: string
programParameters:
string: string
programPath: string
region: string
serviceParameters:
string: string
sql: string
timeouts:
create: string
type: string
MrsJobV2 Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The MrsJobV2 resource accepts the following input properties:
- Cluster
Id string - Specifies an ID of the MRS cluster to which the job belongs to. Changing this will create a new MRS job resource.
- Type string
Specifies the job type. The valid values are MapReduce, Flink, HiveSql, HiveScript, SparkSubmit, SparkSql and SparkScript.
Changing this will create a new MRS job resource.
Spark, Hive, and Flink jobs can be added to only clusters that include Spark, Hive, and Flink components.
- Mrs
Job stringV2Id - ID of the MRS job in UUID format.
- Name string
- Specifies the name of the MRS job. The name can contain 1 to 64 characters, which may consist of letters, digits, underscores (_) and hyphens (-). Changing this will create a new MRS job resource.
- Parameters string
- Specifies the parameters for the MRS job. Add an at sign (@) before
each parameter can prevent the parameters being saved in plaintext format. Each parameters are separated with spaces.
This parameter can be set when
type
is Flink, MRS or SparkSubmit. Changing this will create a new MRS job resource. - Program
Parameters Dictionary<string, string> - Specifies the the key/value pairs of the program parameters, such as
thread, memory, and vCPUs, are used to optimize resource usage and improve job execution performance. This parameter
can be set when
type
is Flink, SparkSubmit, SparkSql, SparkScript, HiveSql or HiveScript. Changing this will create a new MRS job resource. - Program
Path string Specifies the .jar package path or .py file path for program execution. The parameter must meet the following requirements:
- Contains a maximum of 1023 characters, excluding special characters such as
;|&><'$
. - The address cannot be empty or full of spaces.
- The program support OBS or DHFS to storage program file or package. For OBS, starts with (OBS:) s3a:// and end with .jar or .py. For DHFS, starts with (DHFS:) /user.
Required if
type
is MapReduce or SparkSubmit. Changing this will create a new MRS job resource.- Contains a maximum of 1023 characters, excluding special characters such as
- Region string
- Specifies the region in which to create the MRS job resource. If omitted, the provider-level region will be used. Changing this will create a new MRS job resource.
- Service
Parameters Dictionary<string, string> - Specifies the key/value pairs used to modify service configuration. Parameter configurations of services are available on the Service Configuration tab page of MRS Manager. Changing this will create a new MRS job resource.
- Sql string
- Specifies the SQL command or file path. Only required if
type
is HiveSql or SparkSql. Changing this will create a new MRS job resource. - Timeouts
Mrs
Job V2Timeouts
- Cluster
Id string - Specifies an ID of the MRS cluster to which the job belongs to. Changing this will create a new MRS job resource.
- Type string
Specifies the job type. The valid values are MapReduce, Flink, HiveSql, HiveScript, SparkSubmit, SparkSql and SparkScript.
Changing this will create a new MRS job resource.
Spark, Hive, and Flink jobs can be added to only clusters that include Spark, Hive, and Flink components.
- Mrs
Job stringV2Id - ID of the MRS job in UUID format.
- Name string
- Specifies the name of the MRS job. The name can contain 1 to 64 characters, which may consist of letters, digits, underscores (_) and hyphens (-). Changing this will create a new MRS job resource.
- Parameters string
- Specifies the parameters for the MRS job. Add an at sign (@) before
each parameter can prevent the parameters being saved in plaintext format. Each parameters are separated with spaces.
This parameter can be set when
type
is Flink, MRS or SparkSubmit. Changing this will create a new MRS job resource. - Program
Parameters map[string]string - Specifies the the key/value pairs of the program parameters, such as
thread, memory, and vCPUs, are used to optimize resource usage and improve job execution performance. This parameter
can be set when
type
is Flink, SparkSubmit, SparkSql, SparkScript, HiveSql or HiveScript. Changing this will create a new MRS job resource. - Program
Path string Specifies the .jar package path or .py file path for program execution. The parameter must meet the following requirements:
- Contains a maximum of 1023 characters, excluding special characters such as
;|&><'$
. - The address cannot be empty or full of spaces.
- The program support OBS or DHFS to storage program file or package. For OBS, starts with (OBS:) s3a:// and end with .jar or .py. For DHFS, starts with (DHFS:) /user.
Required if
type
is MapReduce or SparkSubmit. Changing this will create a new MRS job resource.- Contains a maximum of 1023 characters, excluding special characters such as
- Region string
- Specifies the region in which to create the MRS job resource. If omitted, the provider-level region will be used. Changing this will create a new MRS job resource.
- Service
Parameters map[string]string - Specifies the key/value pairs used to modify service configuration. Parameter configurations of services are available on the Service Configuration tab page of MRS Manager. Changing this will create a new MRS job resource.
- Sql string
- Specifies the SQL command or file path. Only required if
type
is HiveSql or SparkSql. Changing this will create a new MRS job resource. - Timeouts
Mrs
Job V2Timeouts Args
- cluster
Id String - Specifies an ID of the MRS cluster to which the job belongs to. Changing this will create a new MRS job resource.
- type String
Specifies the job type. The valid values are MapReduce, Flink, HiveSql, HiveScript, SparkSubmit, SparkSql and SparkScript.
Changing this will create a new MRS job resource.
Spark, Hive, and Flink jobs can be added to only clusters that include Spark, Hive, and Flink components.
- mrs
Job StringV2Id - ID of the MRS job in UUID format.
- name String
- Specifies the name of the MRS job. The name can contain 1 to 64 characters, which may consist of letters, digits, underscores (_) and hyphens (-). Changing this will create a new MRS job resource.
- parameters String
- Specifies the parameters for the MRS job. Add an at sign (@) before
each parameter can prevent the parameters being saved in plaintext format. Each parameters are separated with spaces.
This parameter can be set when
type
is Flink, MRS or SparkSubmit. Changing this will create a new MRS job resource. - program
Parameters Map<String,String> - Specifies the the key/value pairs of the program parameters, such as
thread, memory, and vCPUs, are used to optimize resource usage and improve job execution performance. This parameter
can be set when
type
is Flink, SparkSubmit, SparkSql, SparkScript, HiveSql or HiveScript. Changing this will create a new MRS job resource. - program
Path String Specifies the .jar package path or .py file path for program execution. The parameter must meet the following requirements:
- Contains a maximum of 1023 characters, excluding special characters such as
;|&><'$
. - The address cannot be empty or full of spaces.
- The program support OBS or DHFS to storage program file or package. For OBS, starts with (OBS:) s3a:// and end with .jar or .py. For DHFS, starts with (DHFS:) /user.
Required if
type
is MapReduce or SparkSubmit. Changing this will create a new MRS job resource.- Contains a maximum of 1023 characters, excluding special characters such as
- region String
- Specifies the region in which to create the MRS job resource. If omitted, the provider-level region will be used. Changing this will create a new MRS job resource.
- service
Parameters Map<String,String> - Specifies the key/value pairs used to modify service configuration. Parameter configurations of services are available on the Service Configuration tab page of MRS Manager. Changing this will create a new MRS job resource.
- sql String
- Specifies the SQL command or file path. Only required if
type
is HiveSql or SparkSql. Changing this will create a new MRS job resource. - timeouts
Mrs
Job V2Timeouts
- cluster
Id string - Specifies an ID of the MRS cluster to which the job belongs to. Changing this will create a new MRS job resource.
- type string
Specifies the job type. The valid values are MapReduce, Flink, HiveSql, HiveScript, SparkSubmit, SparkSql and SparkScript.
Changing this will create a new MRS job resource.
Spark, Hive, and Flink jobs can be added to only clusters that include Spark, Hive, and Flink components.
- mrs
Job stringV2Id - ID of the MRS job in UUID format.
- name string
- Specifies the name of the MRS job. The name can contain 1 to 64 characters, which may consist of letters, digits, underscores (_) and hyphens (-). Changing this will create a new MRS job resource.
- parameters string
- Specifies the parameters for the MRS job. Add an at sign (@) before
each parameter can prevent the parameters being saved in plaintext format. Each parameters are separated with spaces.
This parameter can be set when
type
is Flink, MRS or SparkSubmit. Changing this will create a new MRS job resource. - program
Parameters {[key: string]: string} - Specifies the the key/value pairs of the program parameters, such as
thread, memory, and vCPUs, are used to optimize resource usage and improve job execution performance. This parameter
can be set when
type
is Flink, SparkSubmit, SparkSql, SparkScript, HiveSql or HiveScript. Changing this will create a new MRS job resource. - program
Path string Specifies the .jar package path or .py file path for program execution. The parameter must meet the following requirements:
- Contains a maximum of 1023 characters, excluding special characters such as
;|&><'$
. - The address cannot be empty or full of spaces.
- The program support OBS or DHFS to storage program file or package. For OBS, starts with (OBS:) s3a:// and end with .jar or .py. For DHFS, starts with (DHFS:) /user.
Required if
type
is MapReduce or SparkSubmit. Changing this will create a new MRS job resource.- Contains a maximum of 1023 characters, excluding special characters such as
- region string
- Specifies the region in which to create the MRS job resource. If omitted, the provider-level region will be used. Changing this will create a new MRS job resource.
- service
Parameters {[key: string]: string} - Specifies the key/value pairs used to modify service configuration. Parameter configurations of services are available on the Service Configuration tab page of MRS Manager. Changing this will create a new MRS job resource.
- sql string
- Specifies the SQL command or file path. Only required if
type
is HiveSql or SparkSql. Changing this will create a new MRS job resource. - timeouts
Mrs
Job V2Timeouts
- cluster_
id str - Specifies an ID of the MRS cluster to which the job belongs to. Changing this will create a new MRS job resource.
- type str
Specifies the job type. The valid values are MapReduce, Flink, HiveSql, HiveScript, SparkSubmit, SparkSql and SparkScript.
Changing this will create a new MRS job resource.
Spark, Hive, and Flink jobs can be added to only clusters that include Spark, Hive, and Flink components.
- mrs_
job_ strv2_ id - ID of the MRS job in UUID format.
- name str
- Specifies the name of the MRS job. The name can contain 1 to 64 characters, which may consist of letters, digits, underscores (_) and hyphens (-). Changing this will create a new MRS job resource.
- parameters str
- Specifies the parameters for the MRS job. Add an at sign (@) before
each parameter can prevent the parameters being saved in plaintext format. Each parameters are separated with spaces.
This parameter can be set when
type
is Flink, MRS or SparkSubmit. Changing this will create a new MRS job resource. - program_
parameters Mapping[str, str] - Specifies the the key/value pairs of the program parameters, such as
thread, memory, and vCPUs, are used to optimize resource usage and improve job execution performance. This parameter
can be set when
type
is Flink, SparkSubmit, SparkSql, SparkScript, HiveSql or HiveScript. Changing this will create a new MRS job resource. - program_
path str Specifies the .jar package path or .py file path for program execution. The parameter must meet the following requirements:
- Contains a maximum of 1023 characters, excluding special characters such as
;|&><'$
. - The address cannot be empty or full of spaces.
- The program support OBS or DHFS to storage program file or package. For OBS, starts with (OBS:) s3a:// and end with .jar or .py. For DHFS, starts with (DHFS:) /user.
Required if
type
is MapReduce or SparkSubmit. Changing this will create a new MRS job resource.- Contains a maximum of 1023 characters, excluding special characters such as
- region str
- Specifies the region in which to create the MRS job resource. If omitted, the provider-level region will be used. Changing this will create a new MRS job resource.
- service_
parameters Mapping[str, str] - Specifies the key/value pairs used to modify service configuration. Parameter configurations of services are available on the Service Configuration tab page of MRS Manager. Changing this will create a new MRS job resource.
- sql str
- Specifies the SQL command or file path. Only required if
type
is HiveSql or SparkSql. Changing this will create a new MRS job resource. - timeouts
Mrs
Job V2Timeouts Args
- cluster
Id String - Specifies an ID of the MRS cluster to which the job belongs to. Changing this will create a new MRS job resource.
- type String
Specifies the job type. The valid values are MapReduce, Flink, HiveSql, HiveScript, SparkSubmit, SparkSql and SparkScript.
Changing this will create a new MRS job resource.
Spark, Hive, and Flink jobs can be added to only clusters that include Spark, Hive, and Flink components.
- mrs
Job StringV2Id - ID of the MRS job in UUID format.
- name String
- Specifies the name of the MRS job. The name can contain 1 to 64 characters, which may consist of letters, digits, underscores (_) and hyphens (-). Changing this will create a new MRS job resource.
- parameters String
- Specifies the parameters for the MRS job. Add an at sign (@) before
each parameter can prevent the parameters being saved in plaintext format. Each parameters are separated with spaces.
This parameter can be set when
type
is Flink, MRS or SparkSubmit. Changing this will create a new MRS job resource. - program
Parameters Map<String> - Specifies the the key/value pairs of the program parameters, such as
thread, memory, and vCPUs, are used to optimize resource usage and improve job execution performance. This parameter
can be set when
type
is Flink, SparkSubmit, SparkSql, SparkScript, HiveSql or HiveScript. Changing this will create a new MRS job resource. - program
Path String Specifies the .jar package path or .py file path for program execution. The parameter must meet the following requirements:
- Contains a maximum of 1023 characters, excluding special characters such as
;|&><'$
. - The address cannot be empty or full of spaces.
- The program support OBS or DHFS to storage program file or package. For OBS, starts with (OBS:) s3a:// and end with .jar or .py. For DHFS, starts with (DHFS:) /user.
Required if
type
is MapReduce or SparkSubmit. Changing this will create a new MRS job resource.- Contains a maximum of 1023 characters, excluding special characters such as
- region String
- Specifies the region in which to create the MRS job resource. If omitted, the provider-level region will be used. Changing this will create a new MRS job resource.
- service
Parameters Map<String> - Specifies the key/value pairs used to modify service configuration. Parameter configurations of services are available on the Service Configuration tab page of MRS Manager. Changing this will create a new MRS job resource.
- sql String
- Specifies the SQL command or file path. Only required if
type
is HiveSql or SparkSql. Changing this will create a new MRS job resource. - timeouts Property Map
Outputs
All input properties are implicitly available as output properties. Additionally, the MrsJobV2 resource produces the following output properties:
- Finish
Time string - The completion time of the MRS job.
- Id string
- The provider-assigned unique ID for this managed resource.
- Start
Time string - The creation time of the MRS job.
- Status string
- Status of the MRS job.
- Submit
Time string - The submission time of the MRS job.
- Finish
Time string - The completion time of the MRS job.
- Id string
- The provider-assigned unique ID for this managed resource.
- Start
Time string - The creation time of the MRS job.
- Status string
- Status of the MRS job.
- Submit
Time string - The submission time of the MRS job.
- finish
Time String - The completion time of the MRS job.
- id String
- The provider-assigned unique ID for this managed resource.
- start
Time String - The creation time of the MRS job.
- status String
- Status of the MRS job.
- submit
Time String - The submission time of the MRS job.
- finish
Time string - The completion time of the MRS job.
- id string
- The provider-assigned unique ID for this managed resource.
- start
Time string - The creation time of the MRS job.
- status string
- Status of the MRS job.
- submit
Time string - The submission time of the MRS job.
- finish_
time str - The completion time of the MRS job.
- id str
- The provider-assigned unique ID for this managed resource.
- start_
time str - The creation time of the MRS job.
- status str
- Status of the MRS job.
- submit_
time str - The submission time of the MRS job.
- finish
Time String - The completion time of the MRS job.
- id String
- The provider-assigned unique ID for this managed resource.
- start
Time String - The creation time of the MRS job.
- status String
- Status of the MRS job.
- submit
Time String - The submission time of the MRS job.
Look up Existing MrsJobV2 Resource
Get an existing MrsJobV2 resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: MrsJobV2State, opts?: CustomResourceOptions): MrsJobV2
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
cluster_id: Optional[str] = None,
finish_time: Optional[str] = None,
mrs_job_v2_id: Optional[str] = None,
name: Optional[str] = None,
parameters: Optional[str] = None,
program_parameters: Optional[Mapping[str, str]] = None,
program_path: Optional[str] = None,
region: Optional[str] = None,
service_parameters: Optional[Mapping[str, str]] = None,
sql: Optional[str] = None,
start_time: Optional[str] = None,
status: Optional[str] = None,
submit_time: Optional[str] = None,
timeouts: Optional[MrsJobV2TimeoutsArgs] = None,
type: Optional[str] = None) -> MrsJobV2
func GetMrsJobV2(ctx *Context, name string, id IDInput, state *MrsJobV2State, opts ...ResourceOption) (*MrsJobV2, error)
public static MrsJobV2 Get(string name, Input<string> id, MrsJobV2State? state, CustomResourceOptions? opts = null)
public static MrsJobV2 get(String name, Output<String> id, MrsJobV2State state, CustomResourceOptions options)
resources: _: type: flexibleengine:MrsJobV2 get: id: ${id}
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Cluster
Id string - Specifies an ID of the MRS cluster to which the job belongs to. Changing this will create a new MRS job resource.
- Finish
Time string - The completion time of the MRS job.
- Mrs
Job stringV2Id - ID of the MRS job in UUID format.
- Name string
- Specifies the name of the MRS job. The name can contain 1 to 64 characters, which may consist of letters, digits, underscores (_) and hyphens (-). Changing this will create a new MRS job resource.
- Parameters string
- Specifies the parameters for the MRS job. Add an at sign (@) before
each parameter can prevent the parameters being saved in plaintext format. Each parameters are separated with spaces.
This parameter can be set when
type
is Flink, MRS or SparkSubmit. Changing this will create a new MRS job resource. - Program
Parameters Dictionary<string, string> - Specifies the the key/value pairs of the program parameters, such as
thread, memory, and vCPUs, are used to optimize resource usage and improve job execution performance. This parameter
can be set when
type
is Flink, SparkSubmit, SparkSql, SparkScript, HiveSql or HiveScript. Changing this will create a new MRS job resource. - Program
Path string Specifies the .jar package path or .py file path for program execution. The parameter must meet the following requirements:
- Contains a maximum of 1023 characters, excluding special characters such as
;|&><'$
. - The address cannot be empty or full of spaces.
- The program support OBS or DHFS to storage program file or package. For OBS, starts with (OBS:) s3a:// and end with .jar or .py. For DHFS, starts with (DHFS:) /user.
Required if
type
is MapReduce or SparkSubmit. Changing this will create a new MRS job resource.- Contains a maximum of 1023 characters, excluding special characters such as
- Region string
- Specifies the region in which to create the MRS job resource. If omitted, the provider-level region will be used. Changing this will create a new MRS job resource.
- Service
Parameters Dictionary<string, string> - Specifies the key/value pairs used to modify service configuration. Parameter configurations of services are available on the Service Configuration tab page of MRS Manager. Changing this will create a new MRS job resource.
- Sql string
- Specifies the SQL command or file path. Only required if
type
is HiveSql or SparkSql. Changing this will create a new MRS job resource. - Start
Time string - The creation time of the MRS job.
- Status string
- Status of the MRS job.
- Submit
Time string - The submission time of the MRS job.
- Timeouts
Mrs
Job V2Timeouts - Type string
Specifies the job type. The valid values are MapReduce, Flink, HiveSql, HiveScript, SparkSubmit, SparkSql and SparkScript.
Changing this will create a new MRS job resource.
Spark, Hive, and Flink jobs can be added to only clusters that include Spark, Hive, and Flink components.
- Cluster
Id string - Specifies an ID of the MRS cluster to which the job belongs to. Changing this will create a new MRS job resource.
- Finish
Time string - The completion time of the MRS job.
- Mrs
Job stringV2Id - ID of the MRS job in UUID format.
- Name string
- Specifies the name of the MRS job. The name can contain 1 to 64 characters, which may consist of letters, digits, underscores (_) and hyphens (-). Changing this will create a new MRS job resource.
- Parameters string
- Specifies the parameters for the MRS job. Add an at sign (@) before
each parameter can prevent the parameters being saved in plaintext format. Each parameters are separated with spaces.
This parameter can be set when
type
is Flink, MRS or SparkSubmit. Changing this will create a new MRS job resource. - Program
Parameters map[string]string - Specifies the the key/value pairs of the program parameters, such as
thread, memory, and vCPUs, are used to optimize resource usage and improve job execution performance. This parameter
can be set when
type
is Flink, SparkSubmit, SparkSql, SparkScript, HiveSql or HiveScript. Changing this will create a new MRS job resource. - Program
Path string Specifies the .jar package path or .py file path for program execution. The parameter must meet the following requirements:
- Contains a maximum of 1023 characters, excluding special characters such as
;|&><'$
. - The address cannot be empty or full of spaces.
- The program support OBS or DHFS to storage program file or package. For OBS, starts with (OBS:) s3a:// and end with .jar or .py. For DHFS, starts with (DHFS:) /user.
Required if
type
is MapReduce or SparkSubmit. Changing this will create a new MRS job resource.- Contains a maximum of 1023 characters, excluding special characters such as
- Region string
- Specifies the region in which to create the MRS job resource. If omitted, the provider-level region will be used. Changing this will create a new MRS job resource.
- Service
Parameters map[string]string - Specifies the key/value pairs used to modify service configuration. Parameter configurations of services are available on the Service Configuration tab page of MRS Manager. Changing this will create a new MRS job resource.
- Sql string
- Specifies the SQL command or file path. Only required if
type
is HiveSql or SparkSql. Changing this will create a new MRS job resource. - Start
Time string - The creation time of the MRS job.
- Status string
- Status of the MRS job.
- Submit
Time string - The submission time of the MRS job.
- Timeouts
Mrs
Job V2Timeouts Args - Type string
Specifies the job type. The valid values are MapReduce, Flink, HiveSql, HiveScript, SparkSubmit, SparkSql and SparkScript.
Changing this will create a new MRS job resource.
Spark, Hive, and Flink jobs can be added to only clusters that include Spark, Hive, and Flink components.
- cluster
Id String - Specifies an ID of the MRS cluster to which the job belongs to. Changing this will create a new MRS job resource.
- finish
Time String - The completion time of the MRS job.
- mrs
Job StringV2Id - ID of the MRS job in UUID format.
- name String
- Specifies the name of the MRS job. The name can contain 1 to 64 characters, which may consist of letters, digits, underscores (_) and hyphens (-). Changing this will create a new MRS job resource.
- parameters String
- Specifies the parameters for the MRS job. Add an at sign (@) before
each parameter can prevent the parameters being saved in plaintext format. Each parameters are separated with spaces.
This parameter can be set when
type
is Flink, MRS or SparkSubmit. Changing this will create a new MRS job resource. - program
Parameters Map<String,String> - Specifies the the key/value pairs of the program parameters, such as
thread, memory, and vCPUs, are used to optimize resource usage and improve job execution performance. This parameter
can be set when
type
is Flink, SparkSubmit, SparkSql, SparkScript, HiveSql or HiveScript. Changing this will create a new MRS job resource. - program
Path String Specifies the .jar package path or .py file path for program execution. The parameter must meet the following requirements:
- Contains a maximum of 1023 characters, excluding special characters such as
;|&><'$
. - The address cannot be empty or full of spaces.
- The program support OBS or DHFS to storage program file or package. For OBS, starts with (OBS:) s3a:// and end with .jar or .py. For DHFS, starts with (DHFS:) /user.
Required if
type
is MapReduce or SparkSubmit. Changing this will create a new MRS job resource.- Contains a maximum of 1023 characters, excluding special characters such as
- region String
- Specifies the region in which to create the MRS job resource. If omitted, the provider-level region will be used. Changing this will create a new MRS job resource.
- service
Parameters Map<String,String> - Specifies the key/value pairs used to modify service configuration. Parameter configurations of services are available on the Service Configuration tab page of MRS Manager. Changing this will create a new MRS job resource.
- sql String
- Specifies the SQL command or file path. Only required if
type
is HiveSql or SparkSql. Changing this will create a new MRS job resource. - start
Time String - The creation time of the MRS job.
- status String
- Status of the MRS job.
- submit
Time String - The submission time of the MRS job.
- timeouts
Mrs
Job V2Timeouts - type String
Specifies the job type. The valid values are MapReduce, Flink, HiveSql, HiveScript, SparkSubmit, SparkSql and SparkScript.
Changing this will create a new MRS job resource.
Spark, Hive, and Flink jobs can be added to only clusters that include Spark, Hive, and Flink components.
- cluster
Id string - Specifies an ID of the MRS cluster to which the job belongs to. Changing this will create a new MRS job resource.
- finish
Time string - The completion time of the MRS job.
- mrs
Job stringV2Id - ID of the MRS job in UUID format.
- name string
- Specifies the name of the MRS job. The name can contain 1 to 64 characters, which may consist of letters, digits, underscores (_) and hyphens (-). Changing this will create a new MRS job resource.
- parameters string
- Specifies the parameters for the MRS job. Add an at sign (@) before
each parameter can prevent the parameters being saved in plaintext format. Each parameters are separated with spaces.
This parameter can be set when
type
is Flink, MRS or SparkSubmit. Changing this will create a new MRS job resource. - program
Parameters {[key: string]: string} - Specifies the the key/value pairs of the program parameters, such as
thread, memory, and vCPUs, are used to optimize resource usage and improve job execution performance. This parameter
can be set when
type
is Flink, SparkSubmit, SparkSql, SparkScript, HiveSql or HiveScript. Changing this will create a new MRS job resource. - program
Path string Specifies the .jar package path or .py file path for program execution. The parameter must meet the following requirements:
- Contains a maximum of 1023 characters, excluding special characters such as
;|&><'$
. - The address cannot be empty or full of spaces.
- The program support OBS or DHFS to storage program file or package. For OBS, starts with (OBS:) s3a:// and end with .jar or .py. For DHFS, starts with (DHFS:) /user.
Required if
type
is MapReduce or SparkSubmit. Changing this will create a new MRS job resource.- Contains a maximum of 1023 characters, excluding special characters such as
- region string
- Specifies the region in which to create the MRS job resource. If omitted, the provider-level region will be used. Changing this will create a new MRS job resource.
- service
Parameters {[key: string]: string} - Specifies the key/value pairs used to modify service configuration. Parameter configurations of services are available on the Service Configuration tab page of MRS Manager. Changing this will create a new MRS job resource.
- sql string
- Specifies the SQL command or file path. Only required if
type
is HiveSql or SparkSql. Changing this will create a new MRS job resource. - start
Time string - The creation time of the MRS job.
- status string
- Status of the MRS job.
- submit
Time string - The submission time of the MRS job.
- timeouts
Mrs
Job V2Timeouts - type string
Specifies the job type. The valid values are MapReduce, Flink, HiveSql, HiveScript, SparkSubmit, SparkSql and SparkScript.
Changing this will create a new MRS job resource.
Spark, Hive, and Flink jobs can be added to only clusters that include Spark, Hive, and Flink components.
- cluster_
id str - Specifies an ID of the MRS cluster to which the job belongs to. Changing this will create a new MRS job resource.
- finish_
time str - The completion time of the MRS job.
- mrs_
job_ strv2_ id - ID of the MRS job in UUID format.
- name str
- Specifies the name of the MRS job. The name can contain 1 to 64 characters, which may consist of letters, digits, underscores (_) and hyphens (-). Changing this will create a new MRS job resource.
- parameters str
- Specifies the parameters for the MRS job. Add an at sign (@) before
each parameter can prevent the parameters being saved in plaintext format. Each parameters are separated with spaces.
This parameter can be set when
type
is Flink, MRS or SparkSubmit. Changing this will create a new MRS job resource. - program_
parameters Mapping[str, str] - Specifies the the key/value pairs of the program parameters, such as
thread, memory, and vCPUs, are used to optimize resource usage and improve job execution performance. This parameter
can be set when
type
is Flink, SparkSubmit, SparkSql, SparkScript, HiveSql or HiveScript. Changing this will create a new MRS job resource. - program_
path str Specifies the .jar package path or .py file path for program execution. The parameter must meet the following requirements:
- Contains a maximum of 1023 characters, excluding special characters such as
;|&><'$
. - The address cannot be empty or full of spaces.
- The program support OBS or DHFS to storage program file or package. For OBS, starts with (OBS:) s3a:// and end with .jar or .py. For DHFS, starts with (DHFS:) /user.
Required if
type
is MapReduce or SparkSubmit. Changing this will create a new MRS job resource.- Contains a maximum of 1023 characters, excluding special characters such as
- region str
- Specifies the region in which to create the MRS job resource. If omitted, the provider-level region will be used. Changing this will create a new MRS job resource.
- service_
parameters Mapping[str, str] - Specifies the key/value pairs used to modify service configuration. Parameter configurations of services are available on the Service Configuration tab page of MRS Manager. Changing this will create a new MRS job resource.
- sql str
- Specifies the SQL command or file path. Only required if
type
is HiveSql or SparkSql. Changing this will create a new MRS job resource. - start_
time str - The creation time of the MRS job.
- status str
- Status of the MRS job.
- submit_
time str - The submission time of the MRS job.
- timeouts
Mrs
Job V2Timeouts Args - type str
Specifies the job type. The valid values are MapReduce, Flink, HiveSql, HiveScript, SparkSubmit, SparkSql and SparkScript.
Changing this will create a new MRS job resource.
Spark, Hive, and Flink jobs can be added to only clusters that include Spark, Hive, and Flink components.
- cluster
Id String - Specifies an ID of the MRS cluster to which the job belongs to. Changing this will create a new MRS job resource.
- finish
Time String - The completion time of the MRS job.
- mrs
Job StringV2Id - ID of the MRS job in UUID format.
- name String
- Specifies the name of the MRS job. The name can contain 1 to 64 characters, which may consist of letters, digits, underscores (_) and hyphens (-). Changing this will create a new MRS job resource.
- parameters String
- Specifies the parameters for the MRS job. Add an at sign (@) before
each parameter can prevent the parameters being saved in plaintext format. Each parameters are separated with spaces.
This parameter can be set when
type
is Flink, MRS or SparkSubmit. Changing this will create a new MRS job resource. - program
Parameters Map<String> - Specifies the the key/value pairs of the program parameters, such as
thread, memory, and vCPUs, are used to optimize resource usage and improve job execution performance. This parameter
can be set when
type
is Flink, SparkSubmit, SparkSql, SparkScript, HiveSql or HiveScript. Changing this will create a new MRS job resource. - program
Path String Specifies the .jar package path or .py file path for program execution. The parameter must meet the following requirements:
- Contains a maximum of 1023 characters, excluding special characters such as
;|&><'$
. - The address cannot be empty or full of spaces.
- The program support OBS or DHFS to storage program file or package. For OBS, starts with (OBS:) s3a:// and end with .jar or .py. For DHFS, starts with (DHFS:) /user.
Required if
type
is MapReduce or SparkSubmit. Changing this will create a new MRS job resource.- Contains a maximum of 1023 characters, excluding special characters such as
- region String
- Specifies the region in which to create the MRS job resource. If omitted, the provider-level region will be used. Changing this will create a new MRS job resource.
- service
Parameters Map<String> - Specifies the key/value pairs used to modify service configuration. Parameter configurations of services are available on the Service Configuration tab page of MRS Manager. Changing this will create a new MRS job resource.
- sql String
- Specifies the SQL command or file path. Only required if
type
is HiveSql or SparkSql. Changing this will create a new MRS job resource. - start
Time String - The creation time of the MRS job.
- status String
- Status of the MRS job.
- submit
Time String - The submission time of the MRS job.
- timeouts Property Map
- type String
Specifies the job type. The valid values are MapReduce, Flink, HiveSql, HiveScript, SparkSubmit, SparkSql and SparkScript.
Changing this will create a new MRS job resource.
Spark, Hive, and Flink jobs can be added to only clusters that include Spark, Hive, and Flink components.
Supporting Types
MrsJobV2Timeouts, MrsJobV2TimeoutsArgs
- Create string
- Create string
- create String
- create string
- create str
- create String
Import
MRS jobs can be imported using their id
and the IDs of the MRS cluster to which the job belongs, separated
by a slash, e.g.
$ pulumi import flexibleengine:index/mrsJobV2:MrsJobV2 test <cluster_id>/<id>
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- flexibleengine flexibleenginecloud/terraform-provider-flexibleengine
- License
- Notes
- This Pulumi package is based on the
flexibleengine
Terraform Provider.