feat: downloader task stats (#339)

This commit is contained in:
Tracey Lesley authored and GitHub committed 2024-01-22 11:43:12 +08:00
1 parent 38ff711ea9
commit 6d136604db
7 files changed
+43 -13

No files matched your search

+2
View File
@@ -7,6 +7,7 @@ import (
"github.com/GopeedLab/gopeed/internal/protocol/http"
"github.com/GopeedLab/gopeed/pkg/base"
"github.com/GopeedLab/gopeed/pkg/util"
gonanoid "github.com/matoous/go-nanoid/v2"
"net/url"
"sync"
@@ -22,6 +23,7 @@ type Task struct {
ID string `json:"id"`
Meta *fetcher.FetcherMeta `json:"meta"`
Status base.Status `json:"status"`
Protocol string `json:"protocol"`
Progress *Progress `json:"progress"`
CreatedAt time.Time `json:"createdAt"`
UpdatedAt time.Time `json:"updatedAt"`