GithubHelp home page GithubHelp logo

yadsyah / cadence-api-example Goto Github PK

View Code? Open in Web Editor NEW

This project forked from nndd91/cadence-api-example

0.0 0.0 0.0 24 KB

The full source code for the article Building your first Cadence Workflow. Check out the article for a detailed walk-through of this repository.

Home Page: https://medium.com/stashaway-engineering/building-your-first-cadence-workflow-e61a0b29785

Makefile 1.60% Go 98.40%

cadence-api-example's Introduction

Readme

The full source code for the article Building your first Cadence Workflow. Check out the article for a detailed walk-through of this repository.

Running the Server

  1. cd cadenceservice
  2. docker-compose up
  3. Register the simple-domain with docker run --network=host --rm ubercadence/cli:master --do simple-domain domain register --rd 10

Worker and API Server

Navigate back to the project root folder. Make sure go is installed in system.

  • HttpServer

    1. make httpserver
    2. ./bins/httpserver
  • Worker

    1. make worker
    2. ./bins/worker

Endpoints

  1. To start workflow

    • POST request to http://localhost:3030/api/start-hello-world
    • Note down the workflow id so you can use it to signal
  2. To signal workflow

    • Copy the workflow id from the previous response or check Cadence UI for the WorkflowID
    • POST Request to http://localhost:3030/api/signal-hello-world?workflowId=<workflowId>&age=25
    • Make sure to replace with the id retrieved from cadence web ui

cadence-api-example's People

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.