Files
query-orchestration/internal/job/collector/service.go
T

36 lines
696 B
Go
Raw Normal View History

2024-12-20 17:35:33 +00:00
package collector
2025-01-06 12:26:28 +00:00
import (
cleanversion "queryorchestration/internal/document/clean/version"
textversion "queryorchestration/internal/document/text/version"
"queryorchestration/internal/serviceconfig"
"github.com/google/uuid"
2025-01-06 12:26:28 +00:00
)
2024-12-20 17:35:33 +00:00
type Collector struct {
JobID uuid.UUID
MinCleanVersion int32
MinTextVersion int32
ActiveVersion int32
LatestVersion int32
Fields map[string]uuid.UUID
}
2025-01-23 14:56:20 +00:00
type Services struct {
CleanVersion *cleanversion.Service
TextVersion *textversion.Service
2025-01-23 14:56:20 +00:00
}
2024-12-23 16:01:54 +00:00
type Service struct {
cfg serviceconfig.ConfigProvider
2025-01-23 14:56:20 +00:00
svc *Services
2024-12-20 17:35:33 +00:00
}
func New(cfg serviceconfig.ConfigProvider, svc *Services) *Service {
2025-01-06 12:26:28 +00:00
return &Service{
cfg,
2025-01-23 14:56:20 +00:00
svc,
2025-01-06 12:26:28 +00:00
}
2024-12-20 17:35:33 +00:00
}