package service import ( "context" "git.5iot.com/iotlcm-public/iotlcm-admin-svr/internal/model" ) // IImeiQueue publishes the additive IMEI-sync queue protocol. It is separate // from the status queue so the two full-sync chains can be enabled, scoped and // retried independently. type IImeiQueue interface { // StartImeiRun starts a full run and returns its runId. StartImeiRun(context.Context) (string, error) // StartImeiRunScoped narrows the run to a channel whitelist; a nil or empty // scope is a full sync. StartImeiRunScoped(context.Context, *model.SyncScope) (string, error) } var localImeiQueue IImeiQueue func ImeiQueue() IImeiQueue { if localImeiQueue == nil { panic("implement not found for interface IImeiQueue, forgot register?") } return localImeiQueue } func RegisterImeiQueue(i IImeiQueue) { localImeiQueue = i }