Documentation
¶
Index ¶
- type Configuration
- type SampleHelper
- func (h *SampleHelper) CancelWorkflow(workflowID string)
- func (h *SampleHelper) QueryWorkflow(workflowID, runID, queryType string, args ...interface{})
- func (h *SampleHelper) SetupServiceConfig()
- func (h *SampleHelper) SignalWorkflow(workflowID, signal string, data interface{})
- func (h *SampleHelper) StartWorkers(domainName, groupName string, options worker.Options)
- func (h *SampleHelper) StartWorkflow(options client.StartWorkflowOptions, workflow interface{}, args ...interface{})
- type WorkflowClientBuilder
- func (b *WorkflowClientBuilder) BuildCadenceClient() (client.Client, error)
- func (b *WorkflowClientBuilder) BuildCadenceDomainClient() (client.DomainClient, error)
- func (b *WorkflowClientBuilder) BuildServiceClient() (workflowserviceclient.Interface, error)
- func (b *WorkflowClientBuilder) SetClientIdentity(identity string) *WorkflowClientBuilder
- func (b *WorkflowClientBuilder) SetDispatcher(dispatcher *yarpc.Dispatcher) *WorkflowClientBuilder
- func (b *WorkflowClientBuilder) SetDomain(domain string) *WorkflowClientBuilder
- func (b *WorkflowClientBuilder) SetHostPort(hostport string) *WorkflowClientBuilder
- func (b *WorkflowClientBuilder) SetMetricsScope(metricsScope tally.Scope) *WorkflowClientBuilder
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Configuration ¶
type Configuration struct { DomainName string `yaml:"domain"` ServiceName string `yaml:"service"` HostNameAndPort string `yaml:"host"` }
Configuration for running samples.
type SampleHelper ¶
type SampleHelper struct { Service workflowserviceclient.Interface Scope tally.Scope Logger *zap.Logger Config Configuration Builder *WorkflowClientBuilder }
SampleHelper class for workflow sample helper.
func (*SampleHelper) CancelWorkflow ¶
func (h *SampleHelper) CancelWorkflow(workflowID string)
func (*SampleHelper) QueryWorkflow ¶
func (h *SampleHelper) QueryWorkflow(workflowID, runID, queryType string, args ...interface{})
func (*SampleHelper) SetupServiceConfig ¶
func (h *SampleHelper) SetupServiceConfig()
SetupServiceConfig setup the config for the sample code run
func (*SampleHelper) SignalWorkflow ¶
func (h *SampleHelper) SignalWorkflow(workflowID, signal string, data interface{})
func (*SampleHelper) StartWorkers ¶
func (h *SampleHelper) StartWorkers(domainName, groupName string, options worker.Options)
StartWorkers starts workflow worker and activity worker based on configured options.
func (*SampleHelper) StartWorkflow ¶
func (h *SampleHelper) StartWorkflow(options client.StartWorkflowOptions, workflow interface{}, args ...interface{})
StartWorkflow starts a workflow
type WorkflowClientBuilder ¶
WorkflowClientBuilder build client to cadence service
func NewBuilder ¶
func NewBuilder(logger *zap.Logger) *WorkflowClientBuilder
NewBuilder creates a new WorkflowClientBuilder
func (*WorkflowClientBuilder) BuildCadenceClient ¶
func (b *WorkflowClientBuilder) BuildCadenceClient() (client.Client, error)
BuildCadenceClient builds a client to cadence service
func (*WorkflowClientBuilder) BuildCadenceDomainClient ¶
func (b *WorkflowClientBuilder) BuildCadenceDomainClient() (client.DomainClient, error)
BuildCadenceDomainClient builds a domain client to cadence service
func (*WorkflowClientBuilder) BuildServiceClient ¶
func (b *WorkflowClientBuilder) BuildServiceClient() (workflowserviceclient.Interface, error)
BuildServiceClient builds a rpc service client to cadence service
func (*WorkflowClientBuilder) SetClientIdentity ¶
func (b *WorkflowClientBuilder) SetClientIdentity(identity string) *WorkflowClientBuilder
SetClientIdentity sets the identity for the builder
func (*WorkflowClientBuilder) SetDispatcher ¶
func (b *WorkflowClientBuilder) SetDispatcher(dispatcher *yarpc.Dispatcher) *WorkflowClientBuilder
SetDispatcher sets the dispatcher for the builder
func (*WorkflowClientBuilder) SetDomain ¶
func (b *WorkflowClientBuilder) SetDomain(domain string) *WorkflowClientBuilder
SetDomain sets the domain for the builder
func (*WorkflowClientBuilder) SetHostPort ¶
func (b *WorkflowClientBuilder) SetHostPort(hostport string) *WorkflowClientBuilder
SetHostPort sets the hostport for the builder
func (*WorkflowClientBuilder) SetMetricsScope ¶
func (b *WorkflowClientBuilder) SetMetricsScope(metricsScope tally.Scope) *WorkflowClientBuilder
SetMetricsScope sets the metrics scope for the builder