Documentation ¶
Index ¶
- func FinishStats(taskId string, resolution string, bitrate string) error
- func FinishStatsWithError(taskId string, error string) error
- func GetInstance() (*mgo.Session, *mgo.Database)
- func NewTaskStats(taskId string, url string, hash string) error
- func UpdateStatus(taskId string, status string) error
- type Stats
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FinishStatsWithError ¶
func GetInstance ¶
func GetInstance() (*mgo.Session, *mgo.Database)
func UpdateStatus ¶
Types ¶
type Stats ¶
type Stats struct { TaskId string `bson:"taskId" json:"taskId"` Url string `bson:"url" json:"url"` Hash string `bson:"hash" json:"hash"` Finished bool `bson:"finished" json:"finished"` Status string `bson:"status,omitempty" json:"status,omitempty"` Success bool `bson:"success" json:"success"` Resolution string `bson:"resolution,omitempty" json:"resolution,omitempty"` Bitrate string `bson:"bitrate,omitempty" json:"bitrate,omitempty"` Error string `bson:"error,omitempty" json:"error,omitempty"` Created time.Time `bson:"created" json:"created"` }
func GetAllStats ¶
func GetAllStats() (stats []*Stats)
Click to show internal directories.
Click to hide internal directories.