Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func UppercaseActivity ¶
UppercaseActivity uppercases the given string.
func UppercaseWorkflow ¶
UppercaseWorkflow is a workflow that accepts requests to uppercase strings via signals and provides responses via a callback response activity.
The "request" signal accepts a Request.
Types ¶
type Request ¶
type Request struct { // ID of the request, also set on the response. ID string `json:"id"` // String to be uppercased. Input string `json:"input"` // Required information on which activity to send response to. ResponseActivity string `json:"response_activity"` ResponseTaskQueue string `json:"response_task_queue"` }
Request is a request to uppercase a string, passed as a signal argument to UppercaseWorkflow.
type Requester ¶
type Requester struct {
// contains filtered or unexported fields
}
Requester can request uppercasing of strings and should be closed after use.
func NewRequester ¶
func NewRequester(options RequesterOptions) (*Requester, error)
NewRequester creates a new Requester for the given options.
type RequesterOptions ¶
type RequesterOptions struct { // Client to the Temporal server. Required. Not closed on Requester.Close. Client client.Client // ID of the workflow listening for signals to uppercase. Required. TargetWorkflowID string // Visible for testing. ExistingWorker interface { RegisterActivity(interface{}) Start() error Stop() } }
RequesterOptions are options for NewRequester.
Click to show internal directories.
Click to hide internal directories.