12345678910111213141516171819202122232425262728293031323334353637383940 |
- from pydantic import BaseModel
- from typing import List
- from app.schemas import AirflowTask
- class AirflowJobBase(BaseModel):
- tasks: List[AirflowTask]
- name: str
- dependence: List=[]
- cron: str
- desc: str
- route_strategy: str
- block_strategy: str
- executor_timeout: int
- executor_fail_retry_count: int
- trigger_status: int
- class AirflowJobCreate(AirflowJobBase):
- job_type: int
- job_mode: int
- user_id: int
- class AirflowJobUpdate(AirflowJobBase):
- pass
- # update_time: int
- class AirflowJob(AirflowJobBase):
- id: int
- create_time: int
- update_time: int
- user_id: int
- job_type: int
- job_mode: int
- class Config:
- orm_mode = True
|