Documentation ¶
Index ¶
- Variables
- type MultiRegisterer
- type Option
- func WithBackgroundActivityContext(ctx context.Context) Option
- func WithClient(client client.Client) Option
- func WithInterceptors(interceptors ...interceptor.WorkerInterceptor) Option
- func WithName(name string) Option
- func WithOnFatalError(onFatalError func(error)) Option
- func WithTaskQueue(taskQueue string) Option
- type PlatformConfig
- type Registerer
- type RegistererFnc
- type Worker
- type WorkflowPanicPolicy
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrClientRequired = errors.New("client required: use WithClient to set the client")
)
View Source
var (
ErrUnknownWorkflowPanicPolicy = errors.New("unknown workflow panic policy")
)
Functions ¶
This section is empty.
Types ¶
type MultiRegisterer ¶
type MultiRegisterer []Registerer
MultiRegisterer is a Registerer that registers to multiple Registerer instances.
func (MultiRegisterer) Register ¶
func (m MultiRegisterer) Register(workerInterface worker.Registry)
Register calls Register in sequence of all items of the slice.
type Option ¶
type Option func(*config)
func WithClient ¶
func WithInterceptors ¶
func WithInterceptors(interceptors ...interceptor.WorkerInterceptor) Option
func WithOnFatalError ¶
func WithTaskQueue ¶
type PlatformConfig ¶
type PlatformConfig struct { MaxConcurrentActivityExecutionSize int `config:"max_concurrent_activity_execution_size"` WorkerActivitiesPerSecond float64 `config:"worker_activities_per_second"` MaxConcurrentLocalActivityExecutionSize int `config:"max_concurrent_local_activity_execution_size"` WorkerLocalActivitiesPerSecond float64 `config:"worker_local_activities_per_second"` TaskQueueActivitiesPerSecond float64 `config:"task_queue_activities_per_second"` MaxConcurrentActivityTaskPollers int `config:"max_concurrent_activity_task_pollers"` MaxConcurrentWorkflowTaskExecutionSize int `config:"max_concurrent_workflow_task_execution_size"` MaxConcurrentWorkflowTaskPollers int `config:"max_concurrent_workflow_task_pollers"` EnableLoggingInReplay bool `config:"enable_logging_in_replay"` StickyScheduleToStartTimeout time.Duration `config:"sticky_schedule_to_start_timeout"` WorkflowPanicPolicy WorkflowPanicPolicy `config:"workflow_panic_policy"` WorkerStopTimeout time.Duration `config:"worker_stop_timeout"` EnableSessionWorker bool `config:"enable_session_worker"` MaxConcurrentSessionExecutionSize int `config:"max_concurrent_session_execution_size"` DisableWorkflowWorker bool `config:"disable_workflow_worker"` LocalActivityWorkerOnly bool `config:"local_activity_worker_only"` Identity string `config:"identity"` DeadlockDetectionTimeout time.Duration `config:"deadlock_detection_timeout"` MaxHeartbeatThrottleInterval time.Duration `config:"max_heartbeat_throttle_interval"` DefaultHeartbeatThrottleInterval time.Duration `config:"default_heartbeat_throttle_interval"` DisableEagerActivities bool `config:"disable_eager_activities"` MaxConcurrentEagerActivityExecutionSize int `config:"max_concurrent_eager_activity_execution_size"` DisableRegistrationAliasing bool `config:"disable_registration_aliasing"` BuildID string `config:"build_id"` UseBuildIDForVersioning bool `config:"use_build_id_for_versioning"` }
type Registerer ¶
Registerer is the entity that registers workflows and activities.
type RegistererFnc ¶
RegistererFnc is a function that implements Registerer.
func (RegistererFnc) Register ¶
func (r RegistererFnc) Register(workerInterface worker.Registry)
Register implements Registerer for a RegistererFnc.
type Worker ¶
type Worker struct {
// contains filtered or unexported fields
}
Worker is a services.Server that is able to initialize and manage the temporal Worker together with the github.com/jamillosantos/application.
func NewWorker ¶
func NewWorker(registerer Registerer, cfg PlatformConfig, options ...Option) (Worker, error)
NewWorker implements
type WorkflowPanicPolicy ¶
type WorkflowPanicPolicy worker.WorkflowPanicPolicy
func (*WorkflowPanicPolicy) UnmarshalText ¶
func (w *WorkflowPanicPolicy) UnmarshalText(text []byte) error
Click to show internal directories.
Click to hide internal directories.