GithubHelp home page GithubHelp logo

xiaomi / thain Goto Github PK

View Code? Open in Web Editor NEW
81.0 11.0 29.0 8.7 MB

Thain is a distributed flow schedule platform.

Home Page: https://xiaomi.github.io/thain

License: Apache License 2.0

Java 20.61% JavaScript 0.58% TypeScript 47.66% Kotlin 26.67% Less 3.73% EJS 0.75%
flows scheduler cron etl

thain's Introduction

Thain

Java CI badge Node CI badge

Thain Logo

Other language versions

简体中文

Introduction

Thain is a distributed flow schedule platform, it was invented at XiaoMi Technology and the project has been proven easily-learning, developed-rapidly, stable in the XiaoMi internal departments. Thain has completed backend management system which supports depending, re-run, roll-back and monitoring of the flows, contains bautiful and easily-manipulating web UI for users to maintain your jobs.

Quick Start

  1. Environmental Requirements

    • jdk >= 8
    • nodejs >= 8
  2. Clone Code

    git clone https://github.com/XiaoMi/thain.git
  3. Execute in order under the project root directory

    cd thain-fe
    npm install
    npm run build
    cd ..
    ./gradlew clean build
  4. Run

    java -jar thain-server/build/libs/thain-server-1.3.0-beta.0.jar
  5. Open localhost:9900 to see the effect

  6. Initial account password: admin, admin

Contributors

Help Us Do Better

Now Thain continues to be developed by xiaomi internal developers. If you have any questions, you can ask in the issues or send email to:

License

Apache License Version 2.0 © Xiaomi

thain's People

Contributors

anderson-liu avatar brucecavill avatar dependabot[bot] avatar godisjohnny avatar liangyongrui avatar poplp avatar zuojianguang avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

thain's Issues

发现一行代码错误

FlowServiceImpl.java 67行
addFlowRq.toBuilder().slaKill(true).slaDuration(3L * 60 * 60).build();

flow execution carries additional information

  1. 前端立即执行提供一个下拉箭头,填写执行变量
  2. x5添加参数
  3. flow execution 表增加执行变量字段
  4. 执行的时候加到FlowExecutionStorage中
  5. 配合shell
    • g_xxx (global, 表示全局一直有的变量) #107
  6. 适配重试机制
  7. flow execution 页上展示执行变量内容

Global variables

  1. 全局变量视为一个 job name 为g的任务产生的结果
  2. Built-in Global dynamic variables: like date, time ...
    • g_xxx
  3. Administrators can customize global variables in the management page
  4. flow 执行时候的临时变量,也存在全局中,并且覆盖之前指定的全局变量 #80

enhance http component

  1. http 节点失败策略

    • http支持正则表达式
    • 不匹配视为失败
  2. 配合 #15 进行重试

  3. http 节点 x5发送

    • 新的 http x5 component
    • 使用客户端提供的x5配置进行加密

machine monitoring

  1. 探测失效的机器,用于恢复数据
    • 现在的恢复机制在每日任务超过30w后可能会有一些异常
    • 减少对quartz的依赖

Thain return error detail

The message in the callback interface of the scheduling task I execute should be the details of the error, not the job [sql_name] exception

x5config bug flx

x5 config bug waht when access to /amdin/client data is not existed

Add queue status

  1. add queue status
  2. The flow in the queue can be executed with one click on the page.
  3. Perform flows manually without queuing.

Flow Retry

  1. 用户可以指定失败重试次数
  2. 用户可以指定失败重试的时间间隔
  3. 重试的触发条件只有执行失败
  4. (等待)重试时
    • flow last run status 为 running
      • 所以不能重叠执行
    • flow execution status 为 失败等待下一次重试
  5. 重试的flow execution trigger type为retry
  6. flow http callback的“结束callback” 只有最后一次重试才发送
  7. flow http callback的“开始callback” 只有第一次执行发送

发现一行代码错误

FlowServiceImpl.java 67行
addFlowRq.toBuilder().slaKill(true).slaDuration(3L * 60 * 60).build();

Enhance shell component

Shell 是重要且特殊的组件

  1. 用户可以直接在网页上输入shell脚本
  2. 每个用户有一个地方管理自己上传的shell脚本,方便多个脚本复用(这个需求待确认)
  3. shell 可以设置变量给下一个shell(不太好做)
  4. shell 变量命名
    • 当前的命名方式可能有兼容性问题
    • jobName_xxx

升级antd 4

  1. 重构前端login组件,和antd pro 保持一致

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.