Signed-off-by: Hannah Hunter <hannahhunter@microsoft.com>
This commit is contained in:
Hannah Hunter 2022-11-08 11:24:26 -06:00
parent 3a70766a0c
commit 303acb3dea
5 changed files with 111 additions and 39 deletions

View File

@ -1,45 +1,57 @@
---
type: docs
title: "How to: Set up a workflow"
title: "How to: Set up a built-in workflow"
linkTitle: "How to: Set up workflows"
weight: 2000
description: Integrate, manage, and expose workflows with the built-in workflow runtime component
---
<!-- Introductory paragraph
Required. Light intro that briefly describes what the how-to will cover and any default Dapr characteristics. Link off to the appropriate concept or overview docs to provide context. -->
Intro
<!--
Include a diagram or image, if possible.
-->
## Built-in workflow
<!--
If applicable, link to the related quickstart in a shortcode note or alert with text like:
If you haven't already, [try out the <topic> quickstart](link) for a quick walk-through on how to use <topic>.
-->
### Create the built-in workflow
<!--
Make sure the how-to includes examples for multiple programming languages, OS, or deployment targets, if applicable.
-->
Write a block of code
## <Action or task>
```go
insert code snippet
```
<!--
Unlike quickstarts, do not use "Step 1", "Step 2", etc.
-->
### Start using the API
## <Action or task>
Link
<!--
Each H2 step should start with a verb/action word.
-->
## External workflow engine
### Create an external workflow engine
Write a block of code
```go
insert code snippet
```
### Register an external workflow engine
Register code
```bash
<command>
```
For external workfow engines, there's an additional step to make sure workers for that engine are up and running
Currently two supported workflow engines are Temporal.io and Logic Apps, both of which follow the same set up steps outlined below
Two external workflows:
- Temporal.io
- Logic Apps
<!--
Include code snippets where possible.
-->
## Next steps
<!--
Link to related pages and examples. For example, the building block overview, the related tutorial, API reference, etc.
-->
- [Workflow API]()
- [Use the workflow via the workflow SDK]()

View File

@ -1,12 +1,62 @@
---
type: docs
title: "Invoking workflows: HTTP vs gRPC"
linkTitle: "Invoke with HTTP vs gRPC"
title: "How to: Set up a workflow with an SDK"
linkTitle: "How to: Set up workflow with SDK"
weight: 3000
description: Learn how to invoke the workflow API using either HTTP or gRPC
description: Learn how to set up the workflow API with an SDK
---
Intro
## Built-in workflow
### Create the built-in workflow
Write a block of code
```go
insert code snippet
```
### Start using the API
Link
## External workflow engine
### Create an external workflow engine
Write a block of code
```go
insert code snippet
```
### Register an external workflow engine
Register code
```bash
<command>
```
For external workfow engines, there's an additional step to make sure workers for that engine are up and running
Currently two supported workflow engines are Temporal.io and Logic Apps, both of which follow the same set up steps outlined below
Two external workflows:
- Temporal.io
- Logic Apps
## Next steps
- [Workflow API]()
- [Use the workflow via the workflow SDK]()
## Next steps
<!--

View File

@ -169,6 +169,9 @@ This call results in workflow instance metadata, such as its:
- Completion time (if completed)
- Custom or runtime-specific status
Temporal.io also includes metadata for:
- Task queue
## Purge Workflow Metadata
When using the embedded workflow component, this will delete all state stored by the workflows underlying actor(s).

View File

@ -13,11 +13,15 @@ To set up the built-in workflow engine, create a component of type `todo`. See [
apiVersion: dapr.io/v1alpha1
kind: Component
metadata:
name: <NAME>
name: temporal
spec:
type: todo
type: workflow.temporal
version: v1
metadata:
- name: hostport
value: localhost:7233
- name: identity
value: "WF Identity"
```
## Spec metadata fields

View File

@ -13,20 +13,23 @@ To set up the Temporal.io workflow, create a component of type `todo`. See [this
apiVersion: dapr.io/v1alpha1
kind: Component
metadata:
name: <NAME>
name: temporal
spec:
type: todo
type: workflow.temporal
version: v1
metadata:
- name: hostport
value: <HOST>
- name: identity
value: "WF Identity"
```
## Spec metadata fields
| Field | Required | Details | Example |
|-------|:--------:|---------|---------|
| | | | |
| | | | |
| | | | |
| Field | Required | Details | Example |
|-------|:--------:|---------------------------------------------------|------------------|
| name | Y | Connection string for the Temporal.io host | `localhost:6379` |
| name | Y | Unique ID of the workflow | ` |
## Setup Temporal.io