All Projects → serverlessworkflow → sdk-go

serverlessworkflow / sdk-go

Licence: Apache-2.0 license
Go SDK for Serverless Workflow

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to sdk-go

sdk-java
Java SDK for Serverless Workflow
Stars: ✭ 48 (-15.79%)
Mutual labels:  cncf, serverless-workflow
sdk-typescript
Typescript SDK for Serverless Workflow
Stars: ✭ 42 (-26.32%)
Mutual labels:  cncf, serverless-workflow
velocity
🚅Track development velocity
Stars: ✭ 112 (+96.49%)
Mutual labels:  cncf
awards
🏆 CNCF Community Awards
Stars: ✭ 15 (-73.68%)
Mutual labels:  cncf
sdk-python
Python SDK for CloudEvents
Stars: ✭ 149 (+161.4%)
Mutual labels:  cncf
CKA-Exercises
A set of curated exercises to help prepare you for the Certified Kubernetes Administrator Exam by the Cloud Native Computing Foundation
Stars: ✭ 51 (-10.53%)
Mutual labels:  cncf
techdocs
CNCF TechDocs Team
Stars: ✭ 24 (-57.89%)
Mutual labels:  cncf
meshery.io
Site for Meshery, the cloud native management plane
Stars: ✭ 135 (+136.84%)
Mutual labels:  cncf
website
vitess.io website and other project management related content
Stars: ✭ 25 (-56.14%)
Mutual labels:  cncf
gryllidae
Opinionated CNCF-based, Docker Compose setup for everything needed to develop a 12factor app
Stars: ✭ 18 (-68.42%)
Mutual labels:  cncf
wg-networking
📡📶CNCF Networking WG
Stars: ✭ 26 (-54.39%)
Mutual labels:  cncf
cla
✍CLAs for CNCF
Stars: ✭ 24 (-57.89%)
Mutual labels:  cncf
gsoc-meta-k8s
Project tracker for my GSoC project - Improve TPRs - for the Kubernetes organization (CNCF).
Stars: ✭ 23 (-59.65%)
Mutual labels:  cncf
chronus
Chronus是360数科技术团队基于阿里开源项目TBSchedule重写的分布式调度。
Stars: ✭ 174 (+205.26%)
Mutual labels:  cncf
Kubernetes-and-Cloud-Native-Associate-KCNA
Useful notes for the KCNA - Kubernetes and Cloud Native Associate
Stars: ✭ 162 (+184.21%)
Mutual labels:  cncf
kubernetes the easy way
Automating Kubernetes the hard way with Vagrant and scripts
Stars: ✭ 22 (-61.4%)
Mutual labels:  cncf
opentelemetry-js-api
OpenTelemetry Javascript API
Stars: ✭ 75 (+31.58%)
Mutual labels:  cncf
python-tuf
Python reference implementation of The Update Framework (TUF)
Stars: ✭ 1,425 (+2400%)
Mutual labels:  cncf
tag-storage
🗄CNCF Storage TAG
Stars: ✭ 94 (+64.91%)
Mutual labels:  cncf
incubator-eventmesh
EventMesh is a dynamic event-driven application runtime used to decouple the application and backend middleware layer, which supports a wide range of use cases that encompass complex multi-cloud, widely distributed topologies using diverse technology stacks.
Stars: ✭ 939 (+1547.37%)
Mutual labels:  serverless-workflow

Go SDK for Serverless Workflow

Here you will find all the specification types defined by our Json Schemas, in Go.

Current status of features implemented in the SDK is listed in the table below:

Feature Status
Parse workflow JSON and YAML definitions ✔️
Programmatically build workflow definitions 🚫
Validate workflow definitions (Schema) ✔️
Validate workflow definitions (Integrity) ✔️
Generate workflow diagram (SVG) 🚫

Status

Latest Releases Conformance to spec version
v1.0.0 v0.5
v2.0.1 v0.6
v2.1.x v0.7

How to use

Run the following command in the root of your Go's project:

$ go get github.com/serverlessworkflow/sdk-go/v2

Your go.mod file should be updated to add a dependency from the Serverless Workflow specification.

To use the generated types, import the package in your go file like this:

import "github.com/serverlessworkflow/sdk-go/v2/model"

Then just reference the package in your Go file like myfunction := model.Function{}.

Parsing Serverless Workflow files

Serverless Workflow Specification supports YAML and JSON files for Workflow definitions. To transform such files into a Go data structure, use:

package sw

import (
    "github.com/serverlessworkflow/sdk-go/v2/model"
    "github.com/serverlessworkflow/sdk-go/v2/parser"
)

func ParseWorkflow(filePath string) (*model.Workflow, error) {
    workflow, err := parser.FromFile(filePath)
    if err != nil {
        return nil, err
    } 
    return workflow, nil
} 

The Workflow structure then can be used in your application.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].