childthread

package
v0.0.0-...-0f879ca Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2023 License: Apache-2.0 Imports: 2 Imported by: 0

README

Child Threads

This is a simple example of a workflow that launches a Child Thread and waits for its completion.

Start the Task Worker

We have two TaskDef's and thus two Task Functions. Note that worker/main.go kicks off two threads, one for each Task Worker.

go run ./interrupt/worker

Register the WfSpec

In another terminal, run:

go run ./interrupt/deploy

Run a WfRun

Let's run the WfRun:

lhctl run child-thread input "this is the input!"

You can see both ThreadRuns when you inspect the WfRun:

lhctl get wfRun <wfRunId>

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ChildThreadTask

func ChildThreadTask(input string) string

func ChildThreadWorkflow

func ChildThreadWorkflow(thread *wflib.ThreadBuilder)

func ParentThreadTask

func ParentThreadTask() string

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