Categorygithub.com/indeedeng/iwf-golang-samples
module
0.0.0-20240102190251-992cee951de1
Repository: https://github.com/indeedeng/iwf-golang-samples.git
Documentation: pkg.go.dev

# README

iwf-golang-samples

Samples for iWF Golang SDK that runs against iWF server

Setup

  1. Start a iWF server following the instructions
  2. Run this project
  • To build the binary, run make bins
  • To run the sample service: run ./iwf-samples start

Note that by default this project will listen on 8803 port(default worker port for iWF Golang SDK)

Product Use case samples

Money Transfer Workflow/SAGA Patten

This example shows how to transfer money from one account to another account. The transfer involves multiple steps. When any step fails, the whole transfer is canceled with some compensation steps.

Microservice orchestration

This is the code that is shown in iWF server as an example of microservice orchestration.

JobSeeker Engagement workflow

Screenshot 2023-04-21 at 8 53 25 AM This engagement workflow is for:
  • An engagement is initiated by an employer to reach out to a jobSeeker(via email/SMS/etc)
  • The jobSeeker could respond with decline or accept
  • If jobSeeker doesn't respond, it will get reminder
  • An engagement can change from declined to accepted, but cannot change from accepted to declined

Subscription workflow

This Subscription workflow (with unit tests) is to match the use case described in

Task orchestration with polling & signal

Orchestrating three services:

  • Task A: receive a signal when completing
  • Task B: receive a signal when completing
  • Task C: polling until completion

# Packages

No description provided by the author
No description provided by the author