Versions in this module Expand all Collapse all v1 v1.1.0 Mar 15, 2024 v1.0.0 Jan 19, 2024 Changes in this version + const ModuleName + var FxWorkerModule = fx.Module(ModuleName, ...) + func AsWorker(w any, options ...worker.WorkerExecutionOption) fx.Option + func GetReturnType(target any) string + func GetType(target any) string + func NewFxWorkerPool(p FxWorkerPoolParam) (*worker.WorkerPool, error) + type FxWorkerModuleInfo struct + func NewFxWorkerModuleInfo(pool *worker.WorkerPool) *FxWorkerModuleInfo + func (i *FxWorkerModuleInfo) Data() map[string]interface{} + func (i *FxWorkerModuleInfo) Name() string + type FxWorkerPoolParam struct + Config *config.Config + Factory worker.WorkerPoolFactory + Generator uuid.UuidGenerator + LifeCycle fx.Lifecycle + Logger *log.Logger + MetricsRegistry *prometheus.Registry + Registry *WorkerRegistry + TracerProvider oteltrace.TracerProvider + type FxWorkerRegistryParam struct + Definitions []WorkerDefinition + Workers []worker.Worker + type WorkerDefinition interface + Options func() []worker.WorkerExecutionOption + ReturnType func() string + func NewWorkerDefinition(returnType string, options ...worker.WorkerExecutionOption) WorkerDefinition + type WorkerRegistry struct + func NewFxWorkerRegistry(p FxWorkerRegistryParam) *WorkerRegistry + func (r *WorkerRegistry) ResolveWorkersRegistrations() ([]*worker.WorkerRegistration, error)