child_workflow_continue_as_new

package
v1.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 7, 2021 License: Apache-2.0 Imports: 3 Imported by: 2

README

Child Workflow calling Continue As New

This sample demonstrates that a child workflow calling continue as new is not visible by a parent. Parent receives notification about a child completion only when a child completes, fails or times out.

This is a useful feature when there is a need to process a large set of data. The child can iterate over the data set calling continue as new periodically without polluting the parents' history.

Steps to run this sample:

  1. You need a Temporal service running. See details in README.md
  2. Run the following command to start the worker
go run child-workflow-continue-as-new/worker/main.go
  1. Run the following command to start the example
go run child-workflow-continue-as-new/starter/main.go

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SampleChildWorkflow

func SampleChildWorkflow(ctx workflow.Context, totalCount, runCount int) (string, error)

SampleChildWorkflow workflow definition

func SampleParentWorkflow

func SampleParentWorkflow(ctx workflow.Context) error

SampleParentWorkflow workflow definition

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL