| object | | |
| RequestId | string | | 01CF26C7-00A3-4AA6-BA76-7E95F2A3**** |
| Message | string | | success |
| TraceId | string | The trace ID that is used to query the details of the request. | ac1a0b2215622246421415014e**** |
| Data | object | The information of the job template. | |
| VpcId | string | The ID of the virtual private cloud (VPC). | vpc-2ze0i263cnn311nvj**** |
| ConfigMapMountDesc | array<object> | The details of the ConfigMap. | |
| ConfigMapMountDesc | object | The details of the ConfigMap. | |
| Key | string | The key-value pair that is stored in the ConfigMap. | k1 |
| ConfigMapName | string | | test |
| MountPath | string | The path on which the ConfigMap is mounted. | /tmp |
| ConfigMapId | long | | 1 |
| SecurityGroupId | string | The ID of the security group. | sg-wz969ngg2e49q5i4**** |
| Jdk | string | The version of the Java Development Kit (JDK) on which the deployment package of the application depends. The following versions are supported:
- Open JDK 8
- Open JDK 7
- Dragonwell 11
- Dragonwell 8
- openjdk-8u191-jdk-alpine3.9
- openjdk-7u201-jdk-alpine3.9
This parameter is not returned if PackageType is set to Image. | Open JDK 8 |
| ImageUrl | string | The URL of the image. This parameter is returned only if PackageType is set to Image. | docker.io/library/nginx:1.14.2 |
| SlsConfigs | string | The logging configurations of Log Service.
- To use Log Service resources that are automatically created by SAE, set this parameter to
[{"logDir":"","logType":"stdout"},{"logDir":"/tmp/a.log"}].
- To use custom Log Service resources, set this parameter to
[{"projectName":"test-sls","logType":"stdout","logDir":"","logstoreName":"sae","logtailName":""},{"projectName":"test","logDir":"/tmp/a.log","logstoreName":"sae","logtailName":""}].
Parameter description:
- projectName: the name of the Log Service project.
- logDir: the path in which logs are stored.
- logType: the log type. stdout: the standard output (stdout) log of the container. Only one stdout value for this parameter can be specified. If this parameter is not configured, file logs are collected.
- logstoreName: the name of the Logstore in Log Service.
- logtailName: the name of the Logtail in Log Service. If this parameter is not configured, a new Logtail is created.
If you do not need to modify the logging configurations when you deploy the application, configure SlsConfigs only in the first request. If you no longer need to use Log Service, leave SlsConfigs empty in the request. | [{"logDir":"","logType":"stdout"},{"logDir":"/tmp/a.log"}] |
| Tags | array<object> | | |
| Tag | object | The information about the tag. | |
| Key | string | | k1 |
| Value | string | | v1 |
| PackageUrl | string | The URL of the deployment package. This parameter is returned only if PackageType is set to FatJar or War. | https://edas-bj.oss-cn-beijing.aliyuncs.com/apps/K8s_APP_ID/d4c97c37-aba3-403e-ae1e-6f7d8742****/hello-sae.war |
| PackageType | string | The type of the deployment package. Valid values:
-
If you deploy a Java job template, you can set this parameter to FatJar, War, or Image.
-
If you deploy a PHP job template, the following types are available:
- PhpZip
- IMAGE_PHP_5_4
- IMAGE_PHP_5_4_ALPINE
- IMAGE_PHP_5_5
- IMAGE_PHP_5_5_ALPINE
- IMAGE_PHP_5_6
- IMAGE_PHP_5_6_ALPINE
- IMAGE_PHP_7_0
- IMAGE_PHP_7_0_ALPINE
- IMAGE_PHP_7_1
- IMAGE_PHP_7_1_ALPINE
- IMAGE_PHP_7_2
- IMAGE_PHP_7_2_ALPINE
- IMAGE_PHP_7_3
- IMAGE_PHP_7_3_ALPINE
-
If you deploy a Python job template, you can set this parameter to PythonZip or Image.
| War |
| PreStop | string | The script that is run before the container is stopped. Example: {"exec":{"command":\["cat","/etc/group"\]}} | {"exec":{"command":["cat","/etc/group"]}} |
| PackageVersion | string | The version of the deployment package. This parameter is required only if PackageType is set to FatJar or War. | 1.0 |
| JarStartArgs | string | The arguments in the JAR package. The arguments are used to start the job. The default startup command is $JAVA_HOME/bin/java $JarStartOptions -jar $CATALINA_OPTS "$package_path" $JarStartArgs. | start |
| AppName | string | The name of the job template. | demo-app |
| AppId | string | The ID of the job template. | 7171a6ca-d1cd-4928-8642-7d5cfe69**** |
| JarStartOptions | string | The option settings in the JAR package. The settings are used to start the job. The default startup command is $JAVA_HOME/bin/java $JarStartOptions -jar $CATALINA_OPTS "$package_path" $JarStartArgs. | -Dtest=true |
| Replicas | integer | The number of job instances. | 2 |
| Memory | integer | The size of memory that is required by each instance. Unit: MB. This parameter cannot be set to 0. The values of this parameter correspond to the values of the Cpu parameter:
- This parameter is set to 1024 if the Cpu parameter is set to 500 or 1000.
- This parameter is set to 2048 if the Cpu parameter is set to 500, 1000, or 2000.
- This parameter is set to 4096 if the Cpu parameter is set to 1000, 2000, or 4000.
- This parameter is set to 8192 if the Cpu parameter is set to 2000, 4000, or 8000.
- This parameter is set to 12288 if the Cpu parameter is set to 12000.
- This parameter is set to 16384 if the Cpu parameter is set to 4000, 8000, or 16000.
- This parameter is set to 24567 if the Cpu parameter is set to 12000.
- This parameter is set to 32768 if the Cpu parameter is set to 16000.
- This parameter is set to 65536 if the Cpu parameter is set to 8000, 16000, or 32000.
- This parameter is set to 131072 if the Cpu parameter is set to 32000.
| 2048 |
| PhpConfig | string | The details of the PHP configuration file. | k1=v1 |
| PhpConfigLocation | string | The path on which the PHP configuration file for job startup is mounted. Make sure that the PHP server uses this configuration file during the startup. | /usr/local/etc/php/php.ini |
| PostStart | string | The script that is run immediately after the container is started. Example: {"exec":{"command":\["cat","/etc/group"\]}} | {"exec":{"command":["cat","/etc/group"]}} |
| TerminationGracePeriodSeconds | integer | The timeout period for a graceful shutdown. Default value: 30. Unit: seconds. Valid values: 1 to 300. | 10 |
| CommandArgs | string | The arguments of the image startup command. This parameter contains the arguments that are required for Command. Format:
["a","b"]
In the preceding Command example, the CommandArgs parameter is set to CommandArgs=["abc", ">", "file0"]. The data type of ["abc", ">", "file0"] must be an array of strings in the JSON format. If this parameter does not exist in the Command parameter, you do not need to configure it. | ["a","b"] |
| NamespaceId | string | | cn-beijing:test |
| MountHost | string | The mount target of the Apsara File Storage NAS (NAS) file system in the virtual private cloud (VPC) where the job template is deployed. If you do not need to modify the NAS configurations when you deploy the job template, configure the MountHost parameter only in the first request. You do not need to include this parameter in subsequent requests. If you no longer need to use NAS, leave the MountHost parameter empty in the request. | example.com |
| TomcatConfig | string | The Tomcat configuration. If you want to delete the configuration, set this parameter to {} or leave this parameter empty. Parameter description:
- port: the port number. Valid values: 1024 to 65535. The root permissions are required to perform operations on ports whose number is smaller than 1024. Enter a value that ranges from 1025 to 65535 because the container has only the admin permissions. If this parameter is not configured, the default value 8080 is used.
- contextPath: the path. Default value: /. The value indicates the root directory.
- maxThreads: the maximum number of connections in the connection pool. Default value: 400.
- uriEncoding: the URI encoding scheme in the Tomcat container. Valid values: UTF-8, ISO-8859-1, GBK, and GB2312. If this parameter is not configured, the default value ISO-8859-1 is used.
- useBodyEncoding: indicates whether to use the encoding scheme that is specified by BodyEncoding for URL. Default value: true.
| {"port":8080,"contextPath":"/","maxThreads":400,"uriEncoding":"ISO-8859-1","useBodyEncodingForUri":true} |
| RegionId | string | | cn-beijing |
| VSwitchId | string | | vsw-2ze559r1z1bpwqxwp**** |
| Cpu | integer | The CPU specifications required for each instance. Unit: millicore. This parameter cannot be set to 0. Valid values:
- 500
- 1000
- 2000
- 4000
- 8000
- 16000
- 32000
| 1000 |
| Envs | string | The environment variables. You can configure custom environment variables or reference a ConfigMap. If you want to reference a ConfigMap, you must first create a ConfigMap. For more information, see CreateConfigMap . Valid values:
-
Custom configuration
- name: the name of the environment variable.
- value: the value of the environment variable.
-
Reference a ConfigMap
- name: the name of the environment variable. You can reference one or all keys. To reference all keys, specify
sae-sys-configmap-all-<ConfigMap name>. Example: sae-sys-configmap-all-test1.
- valueFrom: the reference of the environment variable. Set the value to
configMapRef.
- configMapId: the ID of the ConfigMap.
- key: the key. If you want to reference all keys, you do not need to configure this parameter.
| [{"name":"TEST_ENV_KEY","value":"TEST_ENV_VAR"}] |
| MountDesc | array<object> | The details of the mounted NAS file system. | |
| MountDesc | object | The details of the mounted NAS file system. | |
| MountPath | string | The path on which the NAS file system is mounted. | /tmp |
| NasPath | string | The directory in the NAS file system. | / |
| CustomHostAlias | string | The custom mapping between the hostname and IP address in the container. Valid values:
- hostName: the domain name or hostname.
- ip: the IP address.
| [{"hostName":"test.host.name","ip":"0.0.0.0"}] |
| WebContainer | string | The version of the Tomcat container on which the deployment package depends. The following versions are supported:
- apache-tomcat-7.0.91
- apache-tomcat-8.5.42
This parameter is not returned if PackageType is set to Image. | apache-tomcat-7.0.91 |
| Command | string | The command that is used to start the image. The command must be an existing executable object in the container. Example:
command:
- echo
- abc
- >
- file0
In this example, the Command parameter is set to Command="echo", CommandArgs=["abc", ">", "file0"]. | echo |
| WarStartOptions | string | The option settings in the WAR package. The settings are used to start the job. The default startup command is java $JAVA_OPTS $CATALINA_OPTS -Options org.apache.catalina.startup.Bootstrap "$@" start. | custom-option |
| NasId | string | The ID of the NAS file system. | AKSN89** |
| OssAkId | string | The AccessKey ID that is used to read data from and write data to Object Storage Service (OSS). | xxxxxx |
| OssAkSecret | string | The AccessKey secret that is used to read data from and write data to OSS. | xxxxxx |
| OssMountDescs | array<object> | The description of mounted OSS buckets. | |
| ossMountDesc | object | The description of the mounted OSS bucket. | |
| bucketName | string | | oss-bucket |
| bucketPath | string | The directory or object in OSS. If the specified directory or object does not exist, an error is returned. | data/user.data |
| mountPath | string | The path of the container in SAE. The parameter value that you specified overwrites the original value. If the specified path does not exist, SAE automatically creates the path. | /usr/data/user.data |
| readOnly | boolean | Indicates whether the job template can use the container directory to read data from or write data to resources in the directory of the OSS bucket. Valid values:
- true: The job template has the read-only permissions.
- false: The job template has the read and write permissions.
| true |
| EdasContainerVersion | string | The version of the container, such as Ali-Tomcat, in which a job that is developed based on High-speed Service Framework (HSF) is deployed. | 3.5.3 |
| Timezone | string | The time zone. Default value: Asia/Shanghai. | Asia/Shanghai |
| AppDescription | string | The description of the job template. | Sample application
|
| AcrInstanceId | string | The ID of the Container Registry Enterprise Edition instance. | cri-xxxxxx |
| AcrAssumeRoleArn | string | | acs:ram::123456789012****:role/adminrole |
| ImagePullSecrets | string | The ID of the corresponding secret. | 10 |
| TriggerConfig | string | The trigger configuration. This parameter is configured based on the job type.
- Scheduled job: Set type to time, config to a specific CRON expression, and timezone to a specified time zone.
Example: {"type":"time","config":"0 1 */1 * ?","timezone":"GMT+8:00"}
- One-time job: Set type to http and configure a specific HTTP trigger rule for config. For more information, see SourceHttpEventParameters .
Example: {"type":"http","config":{"type":"HTTPS","method",["GET"],"ip":[],"referer":[],"securityConfig":"none"}} | {"type":"time","config":"0 1 */1 * ?","timezone":"GMT+8:00"} |
| ConcurrencyPolicy | string | The concurrency policy of the job. Valid values:
- Forbid: Concurrent running is prohibited. If the previous job is not completed, no new job is created.
- Allow: Concurrent running is allowed.
- Replace: If the previous job is not completed when the time to create a new job is reached, the new job replaces the previous job.
| Allow |
| Suspend | boolean | Indicates whether the job template is suspended. | false |
| Timeout | long | The timeout period of the job. Unit: seconds. | 3600 |
| BackoffLimit | long | The number of times that the job was retried. | 3 |
| Slice | boolean | Indicates whether job sharding is enabled. | true |
| SliceEnvs | string | The parameters of job sharding. | SliceEnvs |
| RefAppId | string | The ID of the job template that you reference. | 7171a6ca-d1cd-4928-8642-7d5cfe69**** |
| RefedAppIds | array | The IDs of the referenced job templates. | |
| appId | string | The ID of the job template. | 8621a6ca-d1cd-4928-8642-7d5cfe69**** |
| PublicWebHookUrls | array | The Internet request URLs of one-time jobs. | |
| publicWebHookUrl | string | | http://***/webhook/putEvents?token=*** |
| VpcWebHookUrls | array | The internal request URLs for one-time jobs. | |
| vpcWebHookUrl | string | | http://***/webhook/putEvents?token=*** |
| ProgrammingLanguage | string | The programming language in which the job template is created. Valid values:
- java: Java
- php: PHP
- python: Python
- other: other programming languages, such as C++, Go, .NET, and Node.js
| java |
| NasConfigs | string | The configurations for mounting the NAS file system. | [{"mountPath":"/test1","readOnly":false,"nasId":"nasId1","mountDomain":"nasId1.cn-shenzhen.nas.aliyuncs.com","nasPath":"/test1"},{"nasId":"nasId2","mountDomain":"nasId2.cn-shenzhen.nas.aliyuncs.com","readOnly":false,"nasPath":"/test2","mountPath":"/test2"}] |
| Python | string | The Python environment. PYTHON 3.9.15 is supported. | PYTHON 3.9.15 |
| PythonModules | string | The configurations for installing custom module dependencies. By default, the dependencies defined by the requirements.txt file in the root directory are installed. If no software package is configured, you can specify dependencies based on your business requirements. | Flask==2.0 |
| ErrorCode | string | The error code returned. Take note of the following rules:
- If the call is successful, ErrorCode is not returned.
- If the call fails, ErrorCode is returned. For more information, see the "Error codes" section in this topic.
| Null
|
| Code | string | The HTTP status code. Valid values:
- 2xx: The call was successful.
- 3xx: The call was redirected.
- 4xx: The call failed.
- 5xx: A server error occurred.
| 200 |
| Success | boolean | Indicates whether the configurations of the job template were obtained. Valid values:
- true: The configurations were obtained.
- false: The configurations failed to be obtained.
| true |