Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add Real-time task report function #1001

Merged
merged 71 commits into from
Jul 11, 2024
Merged

Conversation

NeganZhao
Copy link
Contributor

增加了任务根据心跳间隔实时上报日志功能

@@ -20,7 +20,7 @@ func (lt *LocalTasksT) ReportTasks() []types.ReportTask {
rt := types.ReportTask{Id: id, Clock: t.Clock}

rt.Status = t.GetStatus()
if rt.Status == "running" || rt.Status == "killing" {
if rt.Status == "killing" {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里running为什么去掉了?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

原本的日志上报如果是在running状态的话是不会上报的,这里去掉了可以每次心跳上报一次

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

running的日志是否有必要上报?只上报错误日志是否就够了?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

如果任务运行的时间过长,比如一两天,但是并不知道该任务运行到哪一步了。实时的话就方便查看

@kongfei605
Copy link
Collaborator

Thank you @NeganZhao

@kongfei605 kongfei605 merged commit b643390 into flashcatcloud:main Jul 11, 2024
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants