alicloud.schedulerx.Job
Explore with Pulumi AI
Provides a Schedulerx Job resource.
For information about Schedulerx Job and how to use it, see What is Job.
NOTE: Available since v1.240.0.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const config = new pulumi.Config();
const name = config.get("name") || "terraform-example";
const createNameSpace = new alicloud.schedulerx.Namespace("CreateNameSpace", {
namespaceName: name,
description: name,
});
const _default = new alicloud.schedulerx.AppGroup("default", {
maxJobs: 100,
monitorContactsJson: JSON.stringify([
{
userName: "name1",
userPhone: "89756******",
},
{
userName: "name2",
ding: "http://www.example.com",
},
]),
deleteJobs: false,
appType: 1,
namespaceSource: "schedulerx",
groupId: "example-appgroup-pop-autoexample",
namespaceName: "default",
description: name,
monitorConfigJson: JSON.stringify({
sendChannel: "sms,ding",
}),
appVersion: "1",
appName: "example-appgroup-pop-autoexample",
namespace: createNameSpace.namespaceUid,
enableLog: false,
scheduleBusyWorkers: false,
});
const defaultJob = new alicloud.schedulerx.Job("default", {
timezone: "GTM+7",
status: "Enable",
maxAttempt: 0,
description: name,
parameters: "hello word",
jobName: name,
maxConcurrency: "1",
timeConfig: {
dataOffset: 1,
timeExpression: "100000",
timeType: 3,
calendar: "workday",
},
mapTaskXattrs: {
taskMaxAttempt: 1,
taskAttemptInterval: 1,
consumerSize: 5,
queueSize: 10000,
dispatcherSize: 5,
pageSize: 100,
},
namespace: createNameSpace.namespaceUid,
groupId: _default.groupId,
jobType: "java",
jobMonitorInfo: {
contactInfos: [
{
userPhone: "12345678910",
userName: "tangtao-1",
ding: "https://alidocs.dingtalk.com",
userMail: "12345678@xx.com",
},
{
userPhone: "12345678910",
userName: "tangtao-2",
ding: "https://alidocs.dingtalk.com1",
userMail: "123456789@xx.com",
},
],
monitorConfig: {
timeout: 7200,
sendChannel: "sms",
timeoutKillEnable: true,
timeoutEnable: true,
failEnable: true,
missWorkerEnable: true,
},
},
className: "com.aliyun.schedulerx.example.processor.SimpleJob",
namespaceSource: "schedulerx",
attemptInterval: 30,
failTimes: 1,
executeMode: "batch",
});
import pulumi
import json
import pulumi_alicloud as alicloud
config = pulumi.Config()
name = config.get("name")
if name is None:
name = "terraform-example"
create_name_space = alicloud.schedulerx.Namespace("CreateNameSpace",
namespace_name=name,
description=name)
default = alicloud.schedulerx.AppGroup("default",
max_jobs=100,
monitor_contacts_json=json.dumps([
{
"userName": "name1",
"userPhone": "89756******",
},
{
"userName": "name2",
"ding": "http://www.example.com",
},
]),
delete_jobs=False,
app_type=1,
namespace_source="schedulerx",
group_id="example-appgroup-pop-autoexample",
namespace_name="default",
description=name,
monitor_config_json=json.dumps({
"sendChannel": "sms,ding",
}),
app_version="1",
app_name="example-appgroup-pop-autoexample",
namespace=create_name_space.namespace_uid,
enable_log=False,
schedule_busy_workers=False)
default_job = alicloud.schedulerx.Job("default",
timezone="GTM+7",
status="Enable",
max_attempt=0,
description=name,
parameters="hello word",
job_name=name,
max_concurrency="1",
time_config={
"data_offset": 1,
"time_expression": "100000",
"time_type": 3,
"calendar": "workday",
},
map_task_xattrs={
"task_max_attempt": 1,
"task_attempt_interval": 1,
"consumer_size": 5,
"queue_size": 10000,
"dispatcher_size": 5,
"page_size": 100,
},
namespace=create_name_space.namespace_uid,
group_id=default.group_id,
job_type="java",
job_monitor_info={
"contact_infos": [
{
"user_phone": "12345678910",
"user_name": "tangtao-1",
"ding": "https://alidocs.dingtalk.com",
"user_mail": "12345678@xx.com",
},
{
"user_phone": "12345678910",
"user_name": "tangtao-2",
"ding": "https://alidocs.dingtalk.com1",
"user_mail": "123456789@xx.com",
},
],
"monitor_config": {
"timeout": 7200,
"send_channel": "sms",
"timeout_kill_enable": True,
"timeout_enable": True,
"fail_enable": True,
"miss_worker_enable": True,
},
},
class_name="com.aliyun.schedulerx.example.processor.SimpleJob",
namespace_source="schedulerx",
attempt_interval=30,
fail_times=1,
execute_mode="batch")
package main
import (
"encoding/json"
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/schedulerx"
"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, "")
name := "terraform-example"
if param := cfg.Get("name"); param != "" {
name = param
}
createNameSpace, err := schedulerx.NewNamespace(ctx, "CreateNameSpace", &schedulerx.NamespaceArgs{
NamespaceName: pulumi.String(name),
Description: pulumi.String(name),
})
if err != nil {
return err
}
tmpJSON0, err := json.Marshal([]interface{}{
map[string]interface{}{
"userName": "name1",
"userPhone": "89756******",
},
map[string]interface{}{
"userName": "name2",
"ding": "http://www.example.com",
},
})
if err != nil {
return err
}
json0 := string(tmpJSON0)
tmpJSON1, err := json.Marshal(map[string]interface{}{
"sendChannel": "sms,ding",
})
if err != nil {
return err
}
json1 := string(tmpJSON1)
_default, err := schedulerx.NewAppGroup(ctx, "default", &schedulerx.AppGroupArgs{
MaxJobs: pulumi.Int(100),
MonitorContactsJson: pulumi.String(json0),
DeleteJobs: pulumi.Bool(false),
AppType: pulumi.Int(1),
NamespaceSource: pulumi.String("schedulerx"),
GroupId: pulumi.String("example-appgroup-pop-autoexample"),
NamespaceName: pulumi.String("default"),
Description: pulumi.String(name),
MonitorConfigJson: pulumi.String(json1),
AppVersion: pulumi.String("1"),
AppName: pulumi.String("example-appgroup-pop-autoexample"),
Namespace: createNameSpace.NamespaceUid,
EnableLog: pulumi.Bool(false),
ScheduleBusyWorkers: pulumi.Bool(false),
})
if err != nil {
return err
}
_, err = schedulerx.NewJob(ctx, "default", &schedulerx.JobArgs{
Timezone: pulumi.String("GTM+7"),
Status: pulumi.String("Enable"),
MaxAttempt: pulumi.Int(0),
Description: pulumi.String(name),
Parameters: pulumi.String("hello word"),
JobName: pulumi.String(name),
MaxConcurrency: pulumi.String("1"),
TimeConfig: &schedulerx.JobTimeConfigArgs{
DataOffset: pulumi.Int(1),
TimeExpression: pulumi.String("100000"),
TimeType: pulumi.Int(3),
Calendar: pulumi.String("workday"),
},
MapTaskXattrs: &schedulerx.JobMapTaskXattrsArgs{
TaskMaxAttempt: pulumi.Int(1),
TaskAttemptInterval: pulumi.Int(1),
ConsumerSize: pulumi.Int(5),
QueueSize: pulumi.Int(10000),
DispatcherSize: pulumi.Int(5),
PageSize: pulumi.Int(100),
},
Namespace: createNameSpace.NamespaceUid,
GroupId: _default.GroupId,
JobType: pulumi.String("java"),
JobMonitorInfo: &schedulerx.JobJobMonitorInfoArgs{
ContactInfos: schedulerx.JobJobMonitorInfoContactInfoArray{
&schedulerx.JobJobMonitorInfoContactInfoArgs{
UserPhone: pulumi.String("12345678910"),
UserName: pulumi.String("tangtao-1"),
Ding: pulumi.String("https://alidocs.dingtalk.com"),
UserMail: pulumi.String("12345678@xx.com"),
},
&schedulerx.JobJobMonitorInfoContactInfoArgs{
UserPhone: pulumi.String("12345678910"),
UserName: pulumi.String("tangtao-2"),
Ding: pulumi.String("https://alidocs.dingtalk.com1"),
UserMail: pulumi.String("123456789@xx.com"),
},
},
MonitorConfig: &schedulerx.JobJobMonitorInfoMonitorConfigArgs{
Timeout: pulumi.Int(7200),
SendChannel: pulumi.String("sms"),
TimeoutKillEnable: pulumi.Bool(true),
TimeoutEnable: pulumi.Bool(true),
FailEnable: pulumi.Bool(true),
MissWorkerEnable: pulumi.Bool(true),
},
},
ClassName: pulumi.String("com.aliyun.schedulerx.example.processor.SimpleJob"),
NamespaceSource: pulumi.String("schedulerx"),
AttemptInterval: pulumi.Int(30),
FailTimes: pulumi.Int(1),
ExecuteMode: pulumi.String("batch"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using System.Text.Json;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var config = new Config();
var name = config.Get("name") ?? "terraform-example";
var createNameSpace = new AliCloud.SchedulerX.Namespace("CreateNameSpace", new()
{
NamespaceName = name,
Description = name,
});
var @default = new AliCloud.SchedulerX.AppGroup("default", new()
{
MaxJobs = 100,
MonitorContactsJson = JsonSerializer.Serialize(new[]
{
new Dictionary<string, object?>
{
["userName"] = "name1",
["userPhone"] = "89756******",
},
new Dictionary<string, object?>
{
["userName"] = "name2",
["ding"] = "http://www.example.com",
},
}),
DeleteJobs = false,
AppType = 1,
NamespaceSource = "schedulerx",
GroupId = "example-appgroup-pop-autoexample",
NamespaceName = "default",
Description = name,
MonitorConfigJson = JsonSerializer.Serialize(new Dictionary<string, object?>
{
["sendChannel"] = "sms,ding",
}),
AppVersion = "1",
AppName = "example-appgroup-pop-autoexample",
Namespace = createNameSpace.NamespaceUid,
EnableLog = false,
ScheduleBusyWorkers = false,
});
var defaultJob = new AliCloud.SchedulerX.Job("default", new()
{
Timezone = "GTM+7",
Status = "Enable",
MaxAttempt = 0,
Description = name,
Parameters = "hello word",
JobName = name,
MaxConcurrency = "1",
TimeConfig = new AliCloud.SchedulerX.Inputs.JobTimeConfigArgs
{
DataOffset = 1,
TimeExpression = "100000",
TimeType = 3,
Calendar = "workday",
},
MapTaskXattrs = new AliCloud.SchedulerX.Inputs.JobMapTaskXattrsArgs
{
TaskMaxAttempt = 1,
TaskAttemptInterval = 1,
ConsumerSize = 5,
QueueSize = 10000,
DispatcherSize = 5,
PageSize = 100,
},
Namespace = createNameSpace.NamespaceUid,
GroupId = @default.GroupId,
JobType = "java",
JobMonitorInfo = new AliCloud.SchedulerX.Inputs.JobJobMonitorInfoArgs
{
ContactInfos = new[]
{
new AliCloud.SchedulerX.Inputs.JobJobMonitorInfoContactInfoArgs
{
UserPhone = "12345678910",
UserName = "tangtao-1",
Ding = "https://alidocs.dingtalk.com",
UserMail = "12345678@xx.com",
},
new AliCloud.SchedulerX.Inputs.JobJobMonitorInfoContactInfoArgs
{
UserPhone = "12345678910",
UserName = "tangtao-2",
Ding = "https://alidocs.dingtalk.com1",
UserMail = "123456789@xx.com",
},
},
MonitorConfig = new AliCloud.SchedulerX.Inputs.JobJobMonitorInfoMonitorConfigArgs
{
Timeout = 7200,
SendChannel = "sms",
TimeoutKillEnable = true,
TimeoutEnable = true,
FailEnable = true,
MissWorkerEnable = true,
},
},
ClassName = "com.aliyun.schedulerx.example.processor.SimpleJob",
NamespaceSource = "schedulerx",
AttemptInterval = 30,
FailTimes = 1,
ExecuteMode = "batch",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.schedulerx.Namespace;
import com.pulumi.alicloud.schedulerx.NamespaceArgs;
import com.pulumi.alicloud.schedulerx.AppGroup;
import com.pulumi.alicloud.schedulerx.AppGroupArgs;
import com.pulumi.alicloud.schedulerx.Job;
import com.pulumi.alicloud.schedulerx.JobArgs;
import com.pulumi.alicloud.schedulerx.inputs.JobTimeConfigArgs;
import com.pulumi.alicloud.schedulerx.inputs.JobMapTaskXattrsArgs;
import com.pulumi.alicloud.schedulerx.inputs.JobJobMonitorInfoArgs;
import com.pulumi.alicloud.schedulerx.inputs.JobJobMonitorInfoMonitorConfigArgs;
import static com.pulumi.codegen.internal.Serialization.*;
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 name = config.get("name").orElse("terraform-example");
var createNameSpace = new Namespace("createNameSpace", NamespaceArgs.builder()
.namespaceName(name)
.description(name)
.build());
var default_ = new AppGroup("default", AppGroupArgs.builder()
.maxJobs("100")
.monitorContactsJson(serializeJson(
jsonArray(
jsonObject(
jsonProperty("userName", "name1"),
jsonProperty("userPhone", "89756******")
),
jsonObject(
jsonProperty("userName", "name2"),
jsonProperty("ding", "http://www.example.com")
)
)))
.deleteJobs("false")
.appType("1")
.namespaceSource("schedulerx")
.groupId("example-appgroup-pop-autoexample")
.namespaceName("default")
.description(name)
.monitorConfigJson(serializeJson(
jsonObject(
jsonProperty("sendChannel", "sms,ding")
)))
.appVersion("1")
.appName("example-appgroup-pop-autoexample")
.namespace(createNameSpace.namespaceUid())
.enableLog("false")
.scheduleBusyWorkers("false")
.build());
var defaultJob = new Job("defaultJob", JobArgs.builder()
.timezone("GTM+7")
.status("Enable")
.maxAttempt("0")
.description(name)
.parameters("hello word")
.jobName(name)
.maxConcurrency("1")
.timeConfig(JobTimeConfigArgs.builder()
.dataOffset("1")
.timeExpression("100000")
.timeType("3")
.calendar("workday")
.build())
.mapTaskXattrs(JobMapTaskXattrsArgs.builder()
.taskMaxAttempt("1")
.taskAttemptInterval("1")
.consumerSize("5")
.queueSize("10000")
.dispatcherSize("5")
.pageSize("100")
.build())
.namespace(createNameSpace.namespaceUid())
.groupId(default_.groupId())
.jobType("java")
.jobMonitorInfo(JobJobMonitorInfoArgs.builder()
.contactInfos(
JobJobMonitorInfoContactInfoArgs.builder()
.userPhone("12345678910")
.userName("tangtao-1")
.ding("https://alidocs.dingtalk.com")
.userMail("12345678@xx.com")
.build(),
JobJobMonitorInfoContactInfoArgs.builder()
.userPhone("12345678910")
.userName("tangtao-2")
.ding("https://alidocs.dingtalk.com1")
.userMail("123456789@xx.com")
.build())
.monitorConfig(JobJobMonitorInfoMonitorConfigArgs.builder()
.timeout("7200")
.sendChannel("sms")
.timeoutKillEnable(true)
.timeoutEnable(true)
.failEnable(true)
.missWorkerEnable(true)
.build())
.build())
.className("com.aliyun.schedulerx.example.processor.SimpleJob")
.namespaceSource("schedulerx")
.attemptInterval("30")
.failTimes("1")
.executeMode("batch")
.build());
}
}
configuration:
name:
type: string
default: terraform-example
resources:
createNameSpace:
type: alicloud:schedulerx:Namespace
name: CreateNameSpace
properties:
namespaceName: ${name}
description: ${name}
default:
type: alicloud:schedulerx:AppGroup
properties:
maxJobs: '100'
monitorContactsJson:
fn::toJSON:
- userName: name1
userPhone: 89756******
- userName: name2
ding: http://www.example.com
deleteJobs: 'false'
appType: '1'
namespaceSource: schedulerx
groupId: example-appgroup-pop-autoexample
namespaceName: default
description: ${name}
monitorConfigJson:
fn::toJSON:
sendChannel: sms,ding
appVersion: '1'
appName: example-appgroup-pop-autoexample
namespace: ${createNameSpace.namespaceUid}
enableLog: 'false'
scheduleBusyWorkers: 'false'
defaultJob:
type: alicloud:schedulerx:Job
name: default
properties:
timezone: GTM+7
status: Enable
maxAttempt: '0'
description: ${name}
parameters: hello word
jobName: ${name}
maxConcurrency: '1'
timeConfig:
dataOffset: '1'
timeExpression: '100000'
timeType: '3'
calendar: workday
mapTaskXattrs:
taskMaxAttempt: '1'
taskAttemptInterval: '1'
consumerSize: '5'
queueSize: '10000'
dispatcherSize: '5'
pageSize: '100'
namespace: ${createNameSpace.namespaceUid}
groupId: ${default.groupId}
jobType: java
jobMonitorInfo:
contactInfos:
- userPhone: '12345678910'
userName: tangtao-1
ding: https://alidocs.dingtalk.com
userMail: 12345678@xx.com
- userPhone: '12345678910'
userName: tangtao-2
ding: https://alidocs.dingtalk.com1
userMail: 123456789@xx.com
monitorConfig:
timeout: '7200'
sendChannel: sms
timeoutKillEnable: true
timeoutEnable: true
failEnable: true
missWorkerEnable: true
className: com.aliyun.schedulerx.example.processor.SimpleJob
namespaceSource: schedulerx
attemptInterval: '30'
failTimes: '1'
executeMode: batch
Create Job Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Job(name: string, args: JobArgs, opts?: CustomResourceOptions);
@overload
def Job(resource_name: str,
args: JobArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Job(resource_name: str,
opts: Optional[ResourceOptions] = None,
group_id: Optional[str] = None,
time_config: Optional[JobTimeConfigArgs] = None,
namespace: Optional[str] = None,
job_type: Optional[str] = None,
execute_mode: Optional[str] = None,
job_name: Optional[str] = None,
map_task_xattrs: Optional[JobMapTaskXattrsArgs] = None,
parameters: Optional[str] = None,
fail_times: Optional[int] = None,
description: Optional[str] = None,
attempt_interval: Optional[int] = None,
max_attempt: Optional[int] = None,
max_concurrency: Optional[str] = None,
content: Optional[str] = None,
namespace_source: Optional[str] = None,
job_monitor_info: Optional[JobJobMonitorInfoArgs] = None,
status: Optional[str] = None,
success_notice_enable: Optional[bool] = None,
task_dispatch_mode: Optional[str] = None,
template: Optional[str] = None,
class_name: Optional[str] = None,
timezone: Optional[str] = None,
x_attrs: Optional[str] = None)
func NewJob(ctx *Context, name string, args JobArgs, opts ...ResourceOption) (*Job, error)
public Job(string name, JobArgs args, CustomResourceOptions? opts = null)
type: alicloud:schedulerx:Job
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 JobArgs
- 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 JobArgs
- 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 JobArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args JobArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args JobArgs
- 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 jobResource = new AliCloud.SchedulerX.Job("jobResource", new()
{
GroupId = "string",
TimeConfig = new AliCloud.SchedulerX.Inputs.JobTimeConfigArgs
{
TimeType = 0,
Calendar = "string",
DataOffset = 0,
TimeExpression = "string",
},
Namespace = "string",
JobType = "string",
ExecuteMode = "string",
JobName = "string",
MapTaskXattrs = new AliCloud.SchedulerX.Inputs.JobMapTaskXattrsArgs
{
ConsumerSize = 0,
DispatcherSize = 0,
PageSize = 0,
QueueSize = 0,
TaskAttemptInterval = 0,
TaskMaxAttempt = 0,
},
Parameters = "string",
FailTimes = 0,
Description = "string",
AttemptInterval = 0,
MaxAttempt = 0,
MaxConcurrency = "string",
Content = "string",
NamespaceSource = "string",
JobMonitorInfo = new AliCloud.SchedulerX.Inputs.JobJobMonitorInfoArgs
{
ContactInfos = new[]
{
new AliCloud.SchedulerX.Inputs.JobJobMonitorInfoContactInfoArgs
{
Ding = "string",
UserMail = "string",
UserName = "string",
UserPhone = "string",
},
},
MonitorConfig = new AliCloud.SchedulerX.Inputs.JobJobMonitorInfoMonitorConfigArgs
{
FailEnable = false,
MissWorkerEnable = false,
SendChannel = "string",
Timeout = 0,
TimeoutEnable = false,
TimeoutKillEnable = false,
},
},
Status = "string",
SuccessNoticeEnable = false,
TaskDispatchMode = "string",
Template = "string",
ClassName = "string",
Timezone = "string",
XAttrs = "string",
});
example, err := schedulerx.NewJob(ctx, "jobResource", &schedulerx.JobArgs{
GroupId: pulumi.String("string"),
TimeConfig: &schedulerx.JobTimeConfigArgs{
TimeType: pulumi.Int(0),
Calendar: pulumi.String("string"),
DataOffset: pulumi.Int(0),
TimeExpression: pulumi.String("string"),
},
Namespace: pulumi.String("string"),
JobType: pulumi.String("string"),
ExecuteMode: pulumi.String("string"),
JobName: pulumi.String("string"),
MapTaskXattrs: &schedulerx.JobMapTaskXattrsArgs{
ConsumerSize: pulumi.Int(0),
DispatcherSize: pulumi.Int(0),
PageSize: pulumi.Int(0),
QueueSize: pulumi.Int(0),
TaskAttemptInterval: pulumi.Int(0),
TaskMaxAttempt: pulumi.Int(0),
},
Parameters: pulumi.String("string"),
FailTimes: pulumi.Int(0),
Description: pulumi.String("string"),
AttemptInterval: pulumi.Int(0),
MaxAttempt: pulumi.Int(0),
MaxConcurrency: pulumi.String("string"),
Content: pulumi.String("string"),
NamespaceSource: pulumi.String("string"),
JobMonitorInfo: &schedulerx.JobJobMonitorInfoArgs{
ContactInfos: schedulerx.JobJobMonitorInfoContactInfoArray{
&schedulerx.JobJobMonitorInfoContactInfoArgs{
Ding: pulumi.String("string"),
UserMail: pulumi.String("string"),
UserName: pulumi.String("string"),
UserPhone: pulumi.String("string"),
},
},
MonitorConfig: &schedulerx.JobJobMonitorInfoMonitorConfigArgs{
FailEnable: pulumi.Bool(false),
MissWorkerEnable: pulumi.Bool(false),
SendChannel: pulumi.String("string"),
Timeout: pulumi.Int(0),
TimeoutEnable: pulumi.Bool(false),
TimeoutKillEnable: pulumi.Bool(false),
},
},
Status: pulumi.String("string"),
SuccessNoticeEnable: pulumi.Bool(false),
TaskDispatchMode: pulumi.String("string"),
Template: pulumi.String("string"),
ClassName: pulumi.String("string"),
Timezone: pulumi.String("string"),
XAttrs: pulumi.String("string"),
})
var jobResource = new Job("jobResource", JobArgs.builder()
.groupId("string")
.timeConfig(JobTimeConfigArgs.builder()
.timeType(0)
.calendar("string")
.dataOffset(0)
.timeExpression("string")
.build())
.namespace("string")
.jobType("string")
.executeMode("string")
.jobName("string")
.mapTaskXattrs(JobMapTaskXattrsArgs.builder()
.consumerSize(0)
.dispatcherSize(0)
.pageSize(0)
.queueSize(0)
.taskAttemptInterval(0)
.taskMaxAttempt(0)
.build())
.parameters("string")
.failTimes(0)
.description("string")
.attemptInterval(0)
.maxAttempt(0)
.maxConcurrency("string")
.content("string")
.namespaceSource("string")
.jobMonitorInfo(JobJobMonitorInfoArgs.builder()
.contactInfos(JobJobMonitorInfoContactInfoArgs.builder()
.ding("string")
.userMail("string")
.userName("string")
.userPhone("string")
.build())
.monitorConfig(JobJobMonitorInfoMonitorConfigArgs.builder()
.failEnable(false)
.missWorkerEnable(false)
.sendChannel("string")
.timeout(0)
.timeoutEnable(false)
.timeoutKillEnable(false)
.build())
.build())
.status("string")
.successNoticeEnable(false)
.taskDispatchMode("string")
.template("string")
.className("string")
.timezone("string")
.xAttrs("string")
.build());
job_resource = alicloud.schedulerx.Job("jobResource",
group_id="string",
time_config={
"time_type": 0,
"calendar": "string",
"data_offset": 0,
"time_expression": "string",
},
namespace="string",
job_type="string",
execute_mode="string",
job_name="string",
map_task_xattrs={
"consumer_size": 0,
"dispatcher_size": 0,
"page_size": 0,
"queue_size": 0,
"task_attempt_interval": 0,
"task_max_attempt": 0,
},
parameters="string",
fail_times=0,
description="string",
attempt_interval=0,
max_attempt=0,
max_concurrency="string",
content="string",
namespace_source="string",
job_monitor_info={
"contact_infos": [{
"ding": "string",
"user_mail": "string",
"user_name": "string",
"user_phone": "string",
}],
"monitor_config": {
"fail_enable": False,
"miss_worker_enable": False,
"send_channel": "string",
"timeout": 0,
"timeout_enable": False,
"timeout_kill_enable": False,
},
},
status="string",
success_notice_enable=False,
task_dispatch_mode="string",
template="string",
class_name="string",
timezone="string",
x_attrs="string")
const jobResource = new alicloud.schedulerx.Job("jobResource", {
groupId: "string",
timeConfig: {
timeType: 0,
calendar: "string",
dataOffset: 0,
timeExpression: "string",
},
namespace: "string",
jobType: "string",
executeMode: "string",
jobName: "string",
mapTaskXattrs: {
consumerSize: 0,
dispatcherSize: 0,
pageSize: 0,
queueSize: 0,
taskAttemptInterval: 0,
taskMaxAttempt: 0,
},
parameters: "string",
failTimes: 0,
description: "string",
attemptInterval: 0,
maxAttempt: 0,
maxConcurrency: "string",
content: "string",
namespaceSource: "string",
jobMonitorInfo: {
contactInfos: [{
ding: "string",
userMail: "string",
userName: "string",
userPhone: "string",
}],
monitorConfig: {
failEnable: false,
missWorkerEnable: false,
sendChannel: "string",
timeout: 0,
timeoutEnable: false,
timeoutKillEnable: false,
},
},
status: "string",
successNoticeEnable: false,
taskDispatchMode: "string",
template: "string",
className: "string",
timezone: "string",
xAttrs: "string",
});
type: alicloud:schedulerx:Job
properties:
attemptInterval: 0
className: string
content: string
description: string
executeMode: string
failTimes: 0
groupId: string
jobMonitorInfo:
contactInfos:
- ding: string
userMail: string
userName: string
userPhone: string
monitorConfig:
failEnable: false
missWorkerEnable: false
sendChannel: string
timeout: 0
timeoutEnable: false
timeoutKillEnable: false
jobName: string
jobType: string
mapTaskXattrs:
consumerSize: 0
dispatcherSize: 0
pageSize: 0
queueSize: 0
taskAttemptInterval: 0
taskMaxAttempt: 0
maxAttempt: 0
maxConcurrency: string
namespace: string
namespaceSource: string
parameters: string
status: string
successNoticeEnable: false
taskDispatchMode: string
template: string
timeConfig:
calendar: string
dataOffset: 0
timeExpression: string
timeType: 0
timezone: string
xAttrs: string
Job 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 Job resource accepts the following input properties:
- Execute
Mode string - Task execution mode, the possible results are as follows:
- Group
Id string - The application ID, which is obtained from the application management page of the console.
- Job
Name string - JobName
- Job
Type string - Job Type
- Namespace string
- Namespace, which is obtained on the
Namespace
page of the console. - Time
Config Pulumi.Ali Cloud. Scheduler X. Inputs. Job Time Config - Time configuration information See
time_config
below. - Attempt
Interval int - Error retry interval, unit s, default value 30.
- Class
Name string Full path of the task interface class.
This field is available only when your task is of the Java task type.
- Content string
- The script code of the python, shell, and go task types.
- Description string
- Task description.
- Fail
Times int - Number of consecutive failed alarms
- Job
Monitor Pulumi.Info Ali Cloud. Scheduler X. Inputs. Job Job Monitor Info - Task monitoring information See
job_monitor_info
below. - Map
Task Pulumi.Xattrs Ali Cloud. Scheduler X. Inputs. Job Map Task Xattrs - Advanced configuration, limited to parallel computing, memory grid, and grid computing. See
map_task_xattrs
below. - Max
Attempt int - The maximum number of error retries, which is set based on business requirements. The default value is 0.
- Max
Concurrency string - The maximum number of instances running at the same time. The default value is 1, that is, the last trigger is not completed, and the next trigger will not be performed even at the running time.
- Namespace
Source string - Special third parties are required.
- Parameters string
- User-defined parameters, which can be obtained at runtime.
- Status string
- Task status. The values are as follows:
- Success
Notice boolEnable - Success Notification Switch
- Task
Dispatch stringMode - Advanced configuration of parallel grid tasks, push model or pull model
- Template string
- K8s task type custom task template
- Timezone string
- Time Zone
- XAttrs string
- Task Extension Field
- Execute
Mode string - Task execution mode, the possible results are as follows:
- Group
Id string - The application ID, which is obtained from the application management page of the console.
- Job
Name string - JobName
- Job
Type string - Job Type
- Namespace string
- Namespace, which is obtained on the
Namespace
page of the console. - Time
Config JobTime Config Args - Time configuration information See
time_config
below. - Attempt
Interval int - Error retry interval, unit s, default value 30.
- Class
Name string Full path of the task interface class.
This field is available only when your task is of the Java task type.
- Content string
- The script code of the python, shell, and go task types.
- Description string
- Task description.
- Fail
Times int - Number of consecutive failed alarms
- Job
Monitor JobInfo Job Monitor Info Args - Task monitoring information See
job_monitor_info
below. - Map
Task JobXattrs Map Task Xattrs Args - Advanced configuration, limited to parallel computing, memory grid, and grid computing. See
map_task_xattrs
below. - Max
Attempt int - The maximum number of error retries, which is set based on business requirements. The default value is 0.
- Max
Concurrency string - The maximum number of instances running at the same time. The default value is 1, that is, the last trigger is not completed, and the next trigger will not be performed even at the running time.
- Namespace
Source string - Special third parties are required.
- Parameters string
- User-defined parameters, which can be obtained at runtime.
- Status string
- Task status. The values are as follows:
- Success
Notice boolEnable - Success Notification Switch
- Task
Dispatch stringMode - Advanced configuration of parallel grid tasks, push model or pull model
- Template string
- K8s task type custom task template
- Timezone string
- Time Zone
- XAttrs string
- Task Extension Field
- execute
Mode String - Task execution mode, the possible results are as follows:
- group
Id String - The application ID, which is obtained from the application management page of the console.
- job
Name String - JobName
- job
Type String - Job Type
- namespace String
- Namespace, which is obtained on the
Namespace
page of the console. - time
Config JobTime Config - Time configuration information See
time_config
below. - attempt
Interval Integer - Error retry interval, unit s, default value 30.
- class
Name String Full path of the task interface class.
This field is available only when your task is of the Java task type.
- content String
- The script code of the python, shell, and go task types.
- description String
- Task description.
- fail
Times Integer - Number of consecutive failed alarms
- job
Monitor JobInfo Job Monitor Info - Task monitoring information See
job_monitor_info
below. - map
Task JobXattrs Map Task Xattrs - Advanced configuration, limited to parallel computing, memory grid, and grid computing. See
map_task_xattrs
below. - max
Attempt Integer - The maximum number of error retries, which is set based on business requirements. The default value is 0.
- max
Concurrency String - The maximum number of instances running at the same time. The default value is 1, that is, the last trigger is not completed, and the next trigger will not be performed even at the running time.
- namespace
Source String - Special third parties are required.
- parameters String
- User-defined parameters, which can be obtained at runtime.
- status String
- Task status. The values are as follows:
- success
Notice BooleanEnable - Success Notification Switch
- task
Dispatch StringMode - Advanced configuration of parallel grid tasks, push model or pull model
- template String
- K8s task type custom task template
- timezone String
- Time Zone
- x
Attrs String - Task Extension Field
- execute
Mode string - Task execution mode, the possible results are as follows:
- group
Id string - The application ID, which is obtained from the application management page of the console.
- job
Name string - JobName
- job
Type string - Job Type
- namespace string
- Namespace, which is obtained on the
Namespace
page of the console. - time
Config JobTime Config - Time configuration information See
time_config
below. - attempt
Interval number - Error retry interval, unit s, default value 30.
- class
Name string Full path of the task interface class.
This field is available only when your task is of the Java task type.
- content string
- The script code of the python, shell, and go task types.
- description string
- Task description.
- fail
Times number - Number of consecutive failed alarms
- job
Monitor JobInfo Job Monitor Info - Task monitoring information See
job_monitor_info
below. - map
Task JobXattrs Map Task Xattrs - Advanced configuration, limited to parallel computing, memory grid, and grid computing. See
map_task_xattrs
below. - max
Attempt number - The maximum number of error retries, which is set based on business requirements. The default value is 0.
- max
Concurrency string - The maximum number of instances running at the same time. The default value is 1, that is, the last trigger is not completed, and the next trigger will not be performed even at the running time.
- namespace
Source string - Special third parties are required.
- parameters string
- User-defined parameters, which can be obtained at runtime.
- status string
- Task status. The values are as follows:
- success
Notice booleanEnable - Success Notification Switch
- task
Dispatch stringMode - Advanced configuration of parallel grid tasks, push model or pull model
- template string
- K8s task type custom task template
- timezone string
- Time Zone
- x
Attrs string - Task Extension Field
- execute_
mode str - Task execution mode, the possible results are as follows:
- group_
id str - The application ID, which is obtained from the application management page of the console.
- job_
name str - JobName
- job_
type str - Job Type
- namespace str
- Namespace, which is obtained on the
Namespace
page of the console. - time_
config JobTime Config Args - Time configuration information See
time_config
below. - attempt_
interval int - Error retry interval, unit s, default value 30.
- class_
name str Full path of the task interface class.
This field is available only when your task is of the Java task type.
- content str
- The script code of the python, shell, and go task types.
- description str
- Task description.
- fail_
times int - Number of consecutive failed alarms
- job_
monitor_ Jobinfo Job Monitor Info Args - Task monitoring information See
job_monitor_info
below. - map_
task_ Jobxattrs Map Task Xattrs Args - Advanced configuration, limited to parallel computing, memory grid, and grid computing. See
map_task_xattrs
below. - max_
attempt int - The maximum number of error retries, which is set based on business requirements. The default value is 0.
- max_
concurrency str - The maximum number of instances running at the same time. The default value is 1, that is, the last trigger is not completed, and the next trigger will not be performed even at the running time.
- namespace_
source str - Special third parties are required.
- parameters str
- User-defined parameters, which can be obtained at runtime.
- status str
- Task status. The values are as follows:
- success_
notice_ boolenable - Success Notification Switch
- task_
dispatch_ strmode - Advanced configuration of parallel grid tasks, push model or pull model
- template str
- K8s task type custom task template
- timezone str
- Time Zone
- x_
attrs str - Task Extension Field
- execute
Mode String - Task execution mode, the possible results are as follows:
- group
Id String - The application ID, which is obtained from the application management page of the console.
- job
Name String - JobName
- job
Type String - Job Type
- namespace String
- Namespace, which is obtained on the
Namespace
page of the console. - time
Config Property Map - Time configuration information See
time_config
below. - attempt
Interval Number - Error retry interval, unit s, default value 30.
- class
Name String Full path of the task interface class.
This field is available only when your task is of the Java task type.
- content String
- The script code of the python, shell, and go task types.
- description String
- Task description.
- fail
Times Number - Number of consecutive failed alarms
- job
Monitor Property MapInfo - Task monitoring information See
job_monitor_info
below. - map
Task Property MapXattrs - Advanced configuration, limited to parallel computing, memory grid, and grid computing. See
map_task_xattrs
below. - max
Attempt Number - The maximum number of error retries, which is set based on business requirements. The default value is 0.
- max
Concurrency String - The maximum number of instances running at the same time. The default value is 1, that is, the last trigger is not completed, and the next trigger will not be performed even at the running time.
- namespace
Source String - Special third parties are required.
- parameters String
- User-defined parameters, which can be obtained at runtime.
- status String
- Task status. The values are as follows:
- success
Notice BooleanEnable - Success Notification Switch
- task
Dispatch StringMode - Advanced configuration of parallel grid tasks, push model or pull model
- template String
- K8s task type custom task template
- timezone String
- Time Zone
- x
Attrs String - Task Extension Field
Outputs
All input properties are implicitly available as output properties. Additionally, the Job resource produces the following output properties:
Look up Existing Job Resource
Get an existing Job 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?: JobState, opts?: CustomResourceOptions): Job
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
attempt_interval: Optional[int] = None,
class_name: Optional[str] = None,
content: Optional[str] = None,
description: Optional[str] = None,
execute_mode: Optional[str] = None,
fail_times: Optional[int] = None,
group_id: Optional[str] = None,
job_id: Optional[int] = None,
job_monitor_info: Optional[JobJobMonitorInfoArgs] = None,
job_name: Optional[str] = None,
job_type: Optional[str] = None,
map_task_xattrs: Optional[JobMapTaskXattrsArgs] = None,
max_attempt: Optional[int] = None,
max_concurrency: Optional[str] = None,
namespace: Optional[str] = None,
namespace_source: Optional[str] = None,
parameters: Optional[str] = None,
status: Optional[str] = None,
success_notice_enable: Optional[bool] = None,
task_dispatch_mode: Optional[str] = None,
template: Optional[str] = None,
time_config: Optional[JobTimeConfigArgs] = None,
timezone: Optional[str] = None,
x_attrs: Optional[str] = None) -> Job
func GetJob(ctx *Context, name string, id IDInput, state *JobState, opts ...ResourceOption) (*Job, error)
public static Job Get(string name, Input<string> id, JobState? state, CustomResourceOptions? opts = null)
public static Job get(String name, Output<String> id, JobState state, CustomResourceOptions options)
resources: _: type: alicloud:schedulerx:Job 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.
- Attempt
Interval int - Error retry interval, unit s, default value 30.
- Class
Name string Full path of the task interface class.
This field is available only when your task is of the Java task type.
- Content string
- The script code of the python, shell, and go task types.
- Description string
- Task description.
- Execute
Mode string - Task execution mode, the possible results are as follows:
- Fail
Times int - Number of consecutive failed alarms
- Group
Id string - The application ID, which is obtained from the application management page of the console.
- Job
Id int - JobId
- Job
Monitor Pulumi.Info Ali Cloud. Scheduler X. Inputs. Job Job Monitor Info - Task monitoring information See
job_monitor_info
below. - Job
Name string - JobName
- Job
Type string - Job Type
- Map
Task Pulumi.Xattrs Ali Cloud. Scheduler X. Inputs. Job Map Task Xattrs - Advanced configuration, limited to parallel computing, memory grid, and grid computing. See
map_task_xattrs
below. - Max
Attempt int - The maximum number of error retries, which is set based on business requirements. The default value is 0.
- Max
Concurrency string - The maximum number of instances running at the same time. The default value is 1, that is, the last trigger is not completed, and the next trigger will not be performed even at the running time.
- Namespace string
- Namespace, which is obtained on the
Namespace
page of the console. - Namespace
Source string - Special third parties are required.
- Parameters string
- User-defined parameters, which can be obtained at runtime.
- Status string
- Task status. The values are as follows:
- Success
Notice boolEnable - Success Notification Switch
- Task
Dispatch stringMode - Advanced configuration of parallel grid tasks, push model or pull model
- Template string
- K8s task type custom task template
- Time
Config Pulumi.Ali Cloud. Scheduler X. Inputs. Job Time Config - Time configuration information See
time_config
below. - Timezone string
- Time Zone
- XAttrs string
- Task Extension Field
- Attempt
Interval int - Error retry interval, unit s, default value 30.
- Class
Name string Full path of the task interface class.
This field is available only when your task is of the Java task type.
- Content string
- The script code of the python, shell, and go task types.
- Description string
- Task description.
- Execute
Mode string - Task execution mode, the possible results are as follows:
- Fail
Times int - Number of consecutive failed alarms
- Group
Id string - The application ID, which is obtained from the application management page of the console.
- Job
Id int - JobId
- Job
Monitor JobInfo Job Monitor Info Args - Task monitoring information See
job_monitor_info
below. - Job
Name string - JobName
- Job
Type string - Job Type
- Map
Task JobXattrs Map Task Xattrs Args - Advanced configuration, limited to parallel computing, memory grid, and grid computing. See
map_task_xattrs
below. - Max
Attempt int - The maximum number of error retries, which is set based on business requirements. The default value is 0.
- Max
Concurrency string - The maximum number of instances running at the same time. The default value is 1, that is, the last trigger is not completed, and the next trigger will not be performed even at the running time.
- Namespace string
- Namespace, which is obtained on the
Namespace
page of the console. - Namespace
Source string - Special third parties are required.
- Parameters string
- User-defined parameters, which can be obtained at runtime.
- Status string
- Task status. The values are as follows:
- Success
Notice boolEnable - Success Notification Switch
- Task
Dispatch stringMode - Advanced configuration of parallel grid tasks, push model or pull model
- Template string
- K8s task type custom task template
- Time
Config JobTime Config Args - Time configuration information See
time_config
below. - Timezone string
- Time Zone
- XAttrs string
- Task Extension Field
- attempt
Interval Integer - Error retry interval, unit s, default value 30.
- class
Name String Full path of the task interface class.
This field is available only when your task is of the Java task type.
- content String
- The script code of the python, shell, and go task types.
- description String
- Task description.
- execute
Mode String - Task execution mode, the possible results are as follows:
- fail
Times Integer - Number of consecutive failed alarms
- group
Id String - The application ID, which is obtained from the application management page of the console.
- job
Id Integer - JobId
- job
Monitor JobInfo Job Monitor Info - Task monitoring information See
job_monitor_info
below. - job
Name String - JobName
- job
Type String - Job Type
- map
Task JobXattrs Map Task Xattrs - Advanced configuration, limited to parallel computing, memory grid, and grid computing. See
map_task_xattrs
below. - max
Attempt Integer - The maximum number of error retries, which is set based on business requirements. The default value is 0.
- max
Concurrency String - The maximum number of instances running at the same time. The default value is 1, that is, the last trigger is not completed, and the next trigger will not be performed even at the running time.
- namespace String
- Namespace, which is obtained on the
Namespace
page of the console. - namespace
Source String - Special third parties are required.
- parameters String
- User-defined parameters, which can be obtained at runtime.
- status String
- Task status. The values are as follows:
- success
Notice BooleanEnable - Success Notification Switch
- task
Dispatch StringMode - Advanced configuration of parallel grid tasks, push model or pull model
- template String
- K8s task type custom task template
- time
Config JobTime Config - Time configuration information See
time_config
below. - timezone String
- Time Zone
- x
Attrs String - Task Extension Field
- attempt
Interval number - Error retry interval, unit s, default value 30.
- class
Name string Full path of the task interface class.
This field is available only when your task is of the Java task type.
- content string
- The script code of the python, shell, and go task types.
- description string
- Task description.
- execute
Mode string - Task execution mode, the possible results are as follows:
- fail
Times number - Number of consecutive failed alarms
- group
Id string - The application ID, which is obtained from the application management page of the console.
- job
Id number - JobId
- job
Monitor JobInfo Job Monitor Info - Task monitoring information See
job_monitor_info
below. - job
Name string - JobName
- job
Type string - Job Type
- map
Task JobXattrs Map Task Xattrs - Advanced configuration, limited to parallel computing, memory grid, and grid computing. See
map_task_xattrs
below. - max
Attempt number - The maximum number of error retries, which is set based on business requirements. The default value is 0.
- max
Concurrency string - The maximum number of instances running at the same time. The default value is 1, that is, the last trigger is not completed, and the next trigger will not be performed even at the running time.
- namespace string
- Namespace, which is obtained on the
Namespace
page of the console. - namespace
Source string - Special third parties are required.
- parameters string
- User-defined parameters, which can be obtained at runtime.
- status string
- Task status. The values are as follows:
- success
Notice booleanEnable - Success Notification Switch
- task
Dispatch stringMode - Advanced configuration of parallel grid tasks, push model or pull model
- template string
- K8s task type custom task template
- time
Config JobTime Config - Time configuration information See
time_config
below. - timezone string
- Time Zone
- x
Attrs string - Task Extension Field
- attempt_
interval int - Error retry interval, unit s, default value 30.
- class_
name str Full path of the task interface class.
This field is available only when your task is of the Java task type.
- content str
- The script code of the python, shell, and go task types.
- description str
- Task description.
- execute_
mode str - Task execution mode, the possible results are as follows:
- fail_
times int - Number of consecutive failed alarms
- group_
id str - The application ID, which is obtained from the application management page of the console.
- job_
id int - JobId
- job_
monitor_ Jobinfo Job Monitor Info Args - Task monitoring information See
job_monitor_info
below. - job_
name str - JobName
- job_
type str - Job Type
- map_
task_ Jobxattrs Map Task Xattrs Args - Advanced configuration, limited to parallel computing, memory grid, and grid computing. See
map_task_xattrs
below. - max_
attempt int - The maximum number of error retries, which is set based on business requirements. The default value is 0.
- max_
concurrency str - The maximum number of instances running at the same time. The default value is 1, that is, the last trigger is not completed, and the next trigger will not be performed even at the running time.
- namespace str
- Namespace, which is obtained on the
Namespace
page of the console. - namespace_
source str - Special third parties are required.
- parameters str
- User-defined parameters, which can be obtained at runtime.
- status str
- Task status. The values are as follows:
- success_
notice_ boolenable - Success Notification Switch
- task_
dispatch_ strmode - Advanced configuration of parallel grid tasks, push model or pull model
- template str
- K8s task type custom task template
- time_
config JobTime Config Args - Time configuration information See
time_config
below. - timezone str
- Time Zone
- x_
attrs str - Task Extension Field
- attempt
Interval Number - Error retry interval, unit s, default value 30.
- class
Name String Full path of the task interface class.
This field is available only when your task is of the Java task type.
- content String
- The script code of the python, shell, and go task types.
- description String
- Task description.
- execute
Mode String - Task execution mode, the possible results are as follows:
- fail
Times Number - Number of consecutive failed alarms
- group
Id String - The application ID, which is obtained from the application management page of the console.
- job
Id Number - JobId
- job
Monitor Property MapInfo - Task monitoring information See
job_monitor_info
below. - job
Name String - JobName
- job
Type String - Job Type
- map
Task Property MapXattrs - Advanced configuration, limited to parallel computing, memory grid, and grid computing. See
map_task_xattrs
below. - max
Attempt Number - The maximum number of error retries, which is set based on business requirements. The default value is 0.
- max
Concurrency String - The maximum number of instances running at the same time. The default value is 1, that is, the last trigger is not completed, and the next trigger will not be performed even at the running time.
- namespace String
- Namespace, which is obtained on the
Namespace
page of the console. - namespace
Source String - Special third parties are required.
- parameters String
- User-defined parameters, which can be obtained at runtime.
- status String
- Task status. The values are as follows:
- success
Notice BooleanEnable - Success Notification Switch
- task
Dispatch StringMode - Advanced configuration of parallel grid tasks, push model or pull model
- template String
- K8s task type custom task template
- time
Config Property Map - Time configuration information See
time_config
below. - timezone String
- Time Zone
- x
Attrs String - Task Extension Field
Supporting Types
JobJobMonitorInfo, JobJobMonitorInfoArgs
- Contact
Infos List<Pulumi.Ali Cloud. Scheduler X. Inputs. Job Job Monitor Info Contact Info> - Contact information. See
contact_info
below. - Monitor
Config Pulumi.Ali Cloud. Scheduler X. Inputs. Job Job Monitor Info Monitor Config - Alarm switch and threshold configuration. See
monitor_config
below.
- Contact
Infos []JobJob Monitor Info Contact Info - Contact information. See
contact_info
below. - Monitor
Config JobJob Monitor Info Monitor Config - Alarm switch and threshold configuration. See
monitor_config
below.
- contact
Infos List<JobJob Monitor Info Contact Info> - Contact information. See
contact_info
below. - monitor
Config JobJob Monitor Info Monitor Config - Alarm switch and threshold configuration. See
monitor_config
below.
- contact
Infos JobJob Monitor Info Contact Info[] - Contact information. See
contact_info
below. - monitor
Config JobJob Monitor Info Monitor Config - Alarm switch and threshold configuration. See
monitor_config
below.
- contact_
infos Sequence[JobJob Monitor Info Contact Info] - Contact information. See
contact_info
below. - monitor_
config JobJob Monitor Info Monitor Config - Alarm switch and threshold configuration. See
monitor_config
below.
- contact
Infos List<Property Map> - Contact information. See
contact_info
below. - monitor
Config Property Map - Alarm switch and threshold configuration. See
monitor_config
below.
JobJobMonitorInfoContactInfo, JobJobMonitorInfoContactInfoArgs
- ding str
- DingTalk swarm robot webhook address
- user_
mail str - User Email Address
- user_
name str - The user name
- user_
phone str - The user's mobile phone number
JobJobMonitorInfoMonitorConfig, JobJobMonitorInfoMonitorConfigArgs
- Fail
Enable bool - Enable failure alarm
- Miss
Worker boolEnable - Whether no available Machine alarm is on
- Send
Channel string - Alarm sending form
- sms: sms alarm
- phone: phone alarm
- mail: mail alarm
- webhook:webhook alarm
- Timeout int
- Timeout threshold, unit s, default 7200.
- Timeout
Enable bool - Time-out alarm switch. The values are as follows:
- Timeout
Kill boolEnable - The trigger switch is terminated by timeout and is turned off by default.
- Fail
Enable bool - Enable failure alarm
- Miss
Worker boolEnable - Whether no available Machine alarm is on
- Send
Channel string - Alarm sending form
- sms: sms alarm
- phone: phone alarm
- mail: mail alarm
- webhook:webhook alarm
- Timeout int
- Timeout threshold, unit s, default 7200.
- Timeout
Enable bool - Time-out alarm switch. The values are as follows:
- Timeout
Kill boolEnable - The trigger switch is terminated by timeout and is turned off by default.
- fail
Enable Boolean - Enable failure alarm
- miss
Worker BooleanEnable - Whether no available Machine alarm is on
- send
Channel String - Alarm sending form
- sms: sms alarm
- phone: phone alarm
- mail: mail alarm
- webhook:webhook alarm
- timeout Integer
- Timeout threshold, unit s, default 7200.
- timeout
Enable Boolean - Time-out alarm switch. The values are as follows:
- timeout
Kill BooleanEnable - The trigger switch is terminated by timeout and is turned off by default.
- fail
Enable boolean - Enable failure alarm
- miss
Worker booleanEnable - Whether no available Machine alarm is on
- send
Channel string - Alarm sending form
- sms: sms alarm
- phone: phone alarm
- mail: mail alarm
- webhook:webhook alarm
- timeout number
- Timeout threshold, unit s, default 7200.
- timeout
Enable boolean - Time-out alarm switch. The values are as follows:
- timeout
Kill booleanEnable - The trigger switch is terminated by timeout and is turned off by default.
- fail_
enable bool - Enable failure alarm
- miss_
worker_ boolenable - Whether no available Machine alarm is on
- send_
channel str - Alarm sending form
- sms: sms alarm
- phone: phone alarm
- mail: mail alarm
- webhook:webhook alarm
- timeout int
- Timeout threshold, unit s, default 7200.
- timeout_
enable bool - Time-out alarm switch. The values are as follows:
- timeout_
kill_ boolenable - The trigger switch is terminated by timeout and is turned off by default.
- fail
Enable Boolean - Enable failure alarm
- miss
Worker BooleanEnable - Whether no available Machine alarm is on
- send
Channel String - Alarm sending form
- sms: sms alarm
- phone: phone alarm
- mail: mail alarm
- webhook:webhook alarm
- timeout Number
- Timeout threshold, unit s, default 7200.
- timeout
Enable Boolean - Time-out alarm switch. The values are as follows:
- timeout
Kill BooleanEnable - The trigger switch is terminated by timeout and is turned off by default.
JobMapTaskXattrs, JobMapTaskXattrsArgs
- Consumer
Size int - The number of threads to execute a single trigger. The default value is 5.
- Dispatcher
Size int - The number of subtask distribution threads. The default value is 5.
- Page
Size int - The number of sub-tasks pulled by a parallel task at a time. The default value is 100.
- Queue
Size int - The upper limit of the sub-task queue cache. The default value is 10000.
- Task
Attempt intInterval - Subtask failure retry interval.
- Task
Max intAttempt - The number of failed sub-task retries.
- Consumer
Size int - The number of threads to execute a single trigger. The default value is 5.
- Dispatcher
Size int - The number of subtask distribution threads. The default value is 5.
- Page
Size int - The number of sub-tasks pulled by a parallel task at a time. The default value is 100.
- Queue
Size int - The upper limit of the sub-task queue cache. The default value is 10000.
- Task
Attempt intInterval - Subtask failure retry interval.
- Task
Max intAttempt - The number of failed sub-task retries.
- consumer
Size Integer - The number of threads to execute a single trigger. The default value is 5.
- dispatcher
Size Integer - The number of subtask distribution threads. The default value is 5.
- page
Size Integer - The number of sub-tasks pulled by a parallel task at a time. The default value is 100.
- queue
Size Integer - The upper limit of the sub-task queue cache. The default value is 10000.
- task
Attempt IntegerInterval - Subtask failure retry interval.
- task
Max IntegerAttempt - The number of failed sub-task retries.
- consumer
Size number - The number of threads to execute a single trigger. The default value is 5.
- dispatcher
Size number - The number of subtask distribution threads. The default value is 5.
- page
Size number - The number of sub-tasks pulled by a parallel task at a time. The default value is 100.
- queue
Size number - The upper limit of the sub-task queue cache. The default value is 10000.
- task
Attempt numberInterval - Subtask failure retry interval.
- task
Max numberAttempt - The number of failed sub-task retries.
- consumer_
size int - The number of threads to execute a single trigger. The default value is 5.
- dispatcher_
size int - The number of subtask distribution threads. The default value is 5.
- page_
size int - The number of sub-tasks pulled by a parallel task at a time. The default value is 100.
- queue_
size int - The upper limit of the sub-task queue cache. The default value is 10000.
- task_
attempt_ intinterval - Subtask failure retry interval.
- task_
max_ intattempt - The number of failed sub-task retries.
- consumer
Size Number - The number of threads to execute a single trigger. The default value is 5.
- dispatcher
Size Number - The number of subtask distribution threads. The default value is 5.
- page
Size Number - The number of sub-tasks pulled by a parallel task at a time. The default value is 100.
- queue
Size Number - The upper limit of the sub-task queue cache. The default value is 10000.
- task
Attempt NumberInterval - Subtask failure retry interval.
- task
Max NumberAttempt - The number of failed sub-task retries.
JobTimeConfig, JobTimeConfigArgs
- Time
Type int - Time configuration type. Currently, the following time types are supported:
- Calendar string
- The cron type can optionally fill in a custom calendar.
- Data
Offset int - Cron type can choose time offset, unit s.
- Time
Expression string - Time expressions. Currently, the following types of time expressions are supported:
- Time
Type int - Time configuration type. Currently, the following time types are supported:
- Calendar string
- The cron type can optionally fill in a custom calendar.
- Data
Offset int - Cron type can choose time offset, unit s.
- Time
Expression string - Time expressions. Currently, the following types of time expressions are supported:
- time
Type Integer - Time configuration type. Currently, the following time types are supported:
- calendar String
- The cron type can optionally fill in a custom calendar.
- data
Offset Integer - Cron type can choose time offset, unit s.
- time
Expression String - Time expressions. Currently, the following types of time expressions are supported:
- time
Type number - Time configuration type. Currently, the following time types are supported:
- calendar string
- The cron type can optionally fill in a custom calendar.
- data
Offset number - Cron type can choose time offset, unit s.
- time
Expression string - Time expressions. Currently, the following types of time expressions are supported:
- time_
type int - Time configuration type. Currently, the following time types are supported:
- calendar str
- The cron type can optionally fill in a custom calendar.
- data_
offset int - Cron type can choose time offset, unit s.
- time_
expression str - Time expressions. Currently, the following types of time expressions are supported:
- time
Type Number - Time configuration type. Currently, the following time types are supported:
- calendar String
- The cron type can optionally fill in a custom calendar.
- data
Offset Number - Cron type can choose time offset, unit s.
- time
Expression String - Time expressions. Currently, the following types of time expressions are supported:
Import
Schedulerx Job can be imported using the id, e.g.
$ pulumi import alicloud:schedulerx/job:Job example <namespace>:<group_id>:<job_id>
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.