Home

Awesome

iwf-java-samples

Samples for iWF Java SDK that runs against iWF server.

We also have smaller code snippets (also known as mini demos) that demonstrate how to utilize iWF to perform a minimum funcion.

Setup

  1. Start a iWF server following the instructions
  2. Run this project by using gradle task bootRun.

_Note that by default this project will listen on 8803 port

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.

User sign-up/registry workflow

A common use case that is almost everywhere -- new user sign-up/register a new account in a website/system. E.g. Amazon/Linkedin/Google/etc...

Microservice ochestration

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

JobSeeker Engagement workflow

<img width="709" alt="Screenshot 2023-04-21 at 8 53 25 AM" src="https://user-images.githubusercontent.com/4523955/233680837-6a6267a0-4b31-419e-87f0-667bb48582d1.png">

See Engagement for how to build an jobSeeker engagement workflow.

Job Post System (a mini Indeed.com)

See JobPost for how to build an JobPost system like Indeed.com

Support typical CRUD operations:

And also

Subscription workflow

See Subscription with unit tests for the use case also described in:

In additional, iWF provides "Auto-ContinueAsNew feature to allow running the workflow infinitely

Shortlist Candidates workflow

<img width="709" alt="Candidate Shortlisting Use Case" src="src/main/java/io/iworkflow/workflow/shortlistcandidates/use_case.png">

See ShortlistCandidates for how to build a workflow to automatically establish connections with shortlisted candidates on behalf of an employer.