2023-05-16 22:46:08 +00:00
|
|
|
package shared
|
|
|
|
|
|
|
|
import (
|
2023-05-22 23:05:38 +00:00
|
|
|
"git.lumeweb.com/LumeWeb/portal/tusstore"
|
2023-05-16 22:46:08 +00:00
|
|
|
"github.com/golang-queue/queue"
|
|
|
|
tusd "github.com/tus/tusd/pkg/handler"
|
2023-05-17 17:34:44 +00:00
|
|
|
_ "go.uber.org/zap"
|
2023-05-16 22:46:08 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
var tusQueue *queue.Queue
|
2023-05-22 23:05:38 +00:00
|
|
|
var tusStore *tusstore.DbFileStore
|
2023-05-16 22:46:08 +00:00
|
|
|
var tusComposer *tusd.StoreComposer
|
|
|
|
|
|
|
|
func SetTusQueue(q *queue.Queue) {
|
|
|
|
tusQueue = q
|
|
|
|
}
|
|
|
|
|
|
|
|
func GetTusQueue() *queue.Queue {
|
|
|
|
return tusQueue
|
|
|
|
}
|
|
|
|
|
2023-05-22 23:05:38 +00:00
|
|
|
func SetTusStore(s *tusstore.DbFileStore) {
|
2023-05-16 22:46:08 +00:00
|
|
|
tusStore = s
|
|
|
|
}
|
|
|
|
|
2023-05-22 23:05:38 +00:00
|
|
|
func GetTusStore() *tusstore.DbFileStore {
|
2023-05-16 22:46:08 +00:00
|
|
|
return tusStore
|
|
|
|
}
|
|
|
|
|
|
|
|
func SetTusComposer(c *tusd.StoreComposer) {
|
|
|
|
tusComposer = c
|
|
|
|
}
|
|
|
|
|
|
|
|
func GetTusComposer() *tusd.StoreComposer {
|
|
|
|
return tusComposer
|
|
|
|
}
|