Back to godoc.org
go.uber.org/cadence

Package cadence

v0.7.3
Latest Go to latest

The highest tagged major version is .

Published: Jul 30, 2018 | License: MIT | Module: go.uber.org/cadence

Overview

Package cadence and its subdirectories contain a Cadence client side framework.

The Cadence service is a task orchestrator for your application’s tasks. Applications using Cadence can execute a logical flow of tasks, especially long-running business logic, asynchronously or synchronously. and can scale runtime on distributed systems without you, the service owner, worrying about infrastructure needs.

A quick example illustrates its use case. Consider Uber Eats where Cadence manages the entire business flow from placing an order, accepting it, handling shopping cart processes (adding, updating, and calculating cart items), entering the order in a pipeline (for preparing food and coordinating delivery), to scheduling delivery as well as handling payments.

Cadence consists of a programming framework (or client library) and a managed service (or backend). The framework enables developers to author and coordinate tasks in Go code.

The root cadence package contains common data structures. The subpackages are:

workflow - functions used to implement workflows

activity - functions used to implement activities

client - functions used to create Cadence service client used to start and monitor workflow executions.

worker - functions used to create worker instance used to host workflow and activity code.

testsuite - unit testing framework for activity and workflow testing.

Index

Constants

const LibraryVersion = internal.LibraryVersion

LibraryVersion is a semver string that represents the version of this cadence client library it will be embedded as a "version" header in every rpc call made by this client to cadence server. In addition, the version string will be used by the server to enforce compatibility checks Update to this version number is typically done by the cadence team as part of a major feature or behavior change

Variables

var ErrNoData = internal.ErrNoData

ErrNoData is returned when trying to extract strong typed data while there is no data available.

func IsCanceledError

func IsCanceledError(err error) bool

IsCanceledError return if the err is a CanceledError

func IsCustomError

func IsCustomError(err error) bool

IsCustomError return if the err is a CustomError

func IsGenericError

func IsGenericError(err error) bool

IsGenericError return if the err is a GenericError

func IsPanicError

func IsPanicError(err error) bool

IsPanicError return if the err is a PanicError

func IsTerminatedError

func IsTerminatedError(err error) bool

IsTerminatedError return if the err is a TerminatedError

func IsTimeoutError

func IsTimeoutError(err error) bool

IsTimeoutError return if the err is a TimeoutError

type CanceledError

type CanceledError = internal.CanceledError

CanceledError returned when operation was canceled.

func NewCanceledError

func NewCanceledError(details ...interface{}) *CanceledError

NewCanceledError creates CanceledError instance. Return this error from activity or child workflow to indicate that it was successfully cancelled.

type CustomError

type CustomError = internal.CustomError

CustomError returned from workflow and activity implementations with reason and optional details.

func NewCustomError

func NewCustomError(reason string, details ...interface{}) *CustomError

NewCustomError create new instance of *CustomError with reason and optional details. Use CustomError for any use case specific errors that cross activity and child workflow boundaries.

Package Files

Documentation was rendered with GOOS=linux and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to identifier