Ask For Task Status Seperatly and logs incrementally
This commit is contained in:
parent
d185784cd1
commit
12e83aa8d2
4 changed files with 73 additions and 34 deletions
|
@ -2,6 +2,8 @@ package types
|
|||
|
||||
import (
|
||||
"encoding/json"
|
||||
|
||||
"git.lastassault.de/speatzle/morffix/constants"
|
||||
)
|
||||
|
||||
type TaskStart struct {
|
||||
|
@ -12,13 +14,18 @@ type TaskStart struct {
|
|||
}
|
||||
|
||||
type Task struct {
|
||||
ID int `json:"id"`
|
||||
FileID int `json:"file_id"`
|
||||
Type int `json:"type"`
|
||||
Status int `json:"status"`
|
||||
Log []string `json:"log"`
|
||||
ID int `json:"id"`
|
||||
FileID int `json:"file_id"`
|
||||
Type int `json:"type"`
|
||||
Status constants.TaskStatus `json:"status"`
|
||||
Log []string `json:"log"`
|
||||
}
|
||||
|
||||
type TaskStatus struct {
|
||||
Tasks []Task `json:"tasks"`
|
||||
Task Task `json:"task"`
|
||||
}
|
||||
|
||||
type TaskStatusRequest struct {
|
||||
ID int `json:"id" db:"id"`
|
||||
LogOffset int `json:"log_offset" db:"log_offset"`
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue