7. Appendices

7.1. Task Repository Schema

This appendix provides an ERD for the database schema used in the task repository.spring-doc.cn

task schema

7.1.1. Table Information

TASK_EXECUTION

Stores the task execution information.spring-doc.cn

Column Name Required Type Field Length Notes

TASK_EXECUTION_IDspring-doc.cn

TRUEspring-doc.cn

BIGINTspring-doc.cn

Xspring-doc.cn

Spring Cloud Task Framework at app startup establishes the next available id as obtained from the TASK_SEQ. Or if the record is created outside of task then the value must be populated at record creation time.spring-doc.cn

START_TIMEspring-doc.cn

FALSEspring-doc.cn

DATETIMEspring-doc.cn

Xspring-doc.cn

Spring Cloud Task Framework at app startup establishes the value.spring-doc.cn

END_TIMEspring-doc.cn

FALSEspring-doc.cn

DATETIMEspring-doc.cn

Xspring-doc.cn

Spring Cloud Task Framework at app exit establishes the value.spring-doc.cn

TASK_NAMEspring-doc.cn

FALSEspring-doc.cn

VARCHARspring-doc.cn

100spring-doc.cn

Spring Cloud Task Framework at app startup will set this to "Application" unless user establish the name using the spring.cloud.task.name as discussed herespring-doc.cn

EXIT_CODEspring-doc.cn

FALSEspring-doc.cn

INTEGERspring-doc.cn

Xspring-doc.cn

Follows Spring Boot defaults unless overridden by the user as discussed here.spring-doc.cn

EXIT_MESSAGEspring-doc.cn

FALSEspring-doc.cn

VARCHARspring-doc.cn

2500spring-doc.cn

User Defined as discussed here.spring-doc.cn

ERROR_MESSAGEspring-doc.cn

FALSEspring-doc.cn

VARCHARspring-doc.cn

2500spring-doc.cn

Spring Cloud Task Framework at app exit establishes the value.spring-doc.cn

LAST_UPDATEDspring-doc.cn

TRUEspring-doc.cn

DATETIMEspring-doc.cn

Xspring-doc.cn

Spring Cloud Task Framework at app startup establishes the value. Or if the record is created outside of task then the value must be populated at record creation time.spring-doc.cn

EXTERNAL_EXECUTION_IDspring-doc.cn

FALSEspring-doc.cn

VARCHARspring-doc.cn

250spring-doc.cn

If the spring.cloud.task.external-execution-id property is set then Spring Cloud Task Framework at app startup will set this to the value specified. More information can be found herespring-doc.cn

PARENT_TASK_EXECUTION_IDspring-doc.cn

FALSEspring-doc.cn

BIGINTspring-doc.cn

Xspring-doc.cn

If the spring.cloud.task.parent-execution-id property is set then Spring Cloud Task Framework at app startup will set this to the value specified. More information can be found herespring-doc.cn

TASK_EXECUTION_PARAMS

Stores the parameters used for a task executionspring-doc.cn

Column Name Required Type Field Length

TASK_EXECUTION_IDspring-doc.cn

TRUEspring-doc.cn

BIGINTspring-doc.cn

Xspring-doc.cn

TASK_PARAMspring-doc.cn

FALSEspring-doc.cn

VARCHARspring-doc.cn

2500spring-doc.cn

TASK_TASK_BATCH

Used to link the task execution to the batch execution.spring-doc.cn

Column Name Required Type Field Length

TASK_EXECUTION_IDspring-doc.cn

TRUEspring-doc.cn

BIGINTspring-doc.cn

Xspring-doc.cn

JOB_EXECUTION_IDspring-doc.cn

TRUEspring-doc.cn

BIGINTspring-doc.cn

Xspring-doc.cn

TASK_LOCK

Used for the single-instance-enabled feature discussed here.spring-doc.cn

Column Name Required Type Field Length Notes

LOCK_KEYspring-doc.cn

TRUEspring-doc.cn

CHARspring-doc.cn

36spring-doc.cn

UUID for the this lockspring-doc.cn

REGIONspring-doc.cn

TRUEspring-doc.cn

VARCHARspring-doc.cn

100spring-doc.cn

User can establish a group of locks using this field.spring-doc.cn

CLIENT_IDspring-doc.cn

TRUEspring-doc.cn

CHARspring-doc.cn

36spring-doc.cn

The task execution id that contains the name of the app to lock.spring-doc.cn

CREATED_DATEspring-doc.cn

TRUEspring-doc.cn

DATETIMEspring-doc.cn

Xspring-doc.cn

The date that the entry was createdspring-doc.cn

The DDL for setting up tables for each database type can be found here.

7.2. Building This Documentation

This project uses Maven to generate this documentation. To generate it for yourself, run the following command: $ ./mvnw clean package -P full.spring-doc.cn

7.3. Running a Task App on Cloud Foundry

The simplest way to launch a Spring Cloud Task application as a task on Cloud Foundry is to use Spring Cloud Data Flow. Via Spring Cloud Data Flow you can register your task application, create a definition for it and then launch it. You then can track the task execution(s) via a RESTful API, the Spring Cloud Data Flow Shell, or the UI. To learn out to get started installing Data Flow follow the instructions in the Getting Started section of the reference documentation. For info on how to register and launch tasks, see the Lifecycle of a Task documentation.spring-doc.cn