• This repository has been archived on 05/Feb/2021
  • Stars
    star
    194
  • Rank 196,014 (Top 4 %)
  • Language
    Go
  • License
    Apache License 2.0
  • Created over 5 years ago
  • Updated over 3 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Build run and manage code-first composites on Kubernetes

Cellery Logo

Build Status codecov GitHub (pre-)release GitHub (Pre-)Release Date GitHub last commit License

Build, run, and manage code-first composites on Kubernetes.

In this README:

In addition, here are some other documents you may wish to read:

Introduction

Cellery is a code-first approach to building, integrating, running and managing composite microservice applications on Kubernetes. Build, push/pull, run, scale and observe composites. Create secure APIs by default, code components in any language.


Why Cellery?

The use of microservices and/or serverless functions is exploding as organisations aim to get better agility and speed of development. This quickly gets out of control, resulting in tens or hundreds of microservices in a highly connected network. There is a strong need for an approach that helps create higher-level constructs from multiple microservices and serverless functions. Cellery aims to create composites with well-defined boundaries that fit with CI/CD pipelines and modern development and DevOps practices. You can read more about this approach here

Cellery intro

Cellery provides a developer tooling, runtime and a management plane. This allows you to develop, run and manage your composite microservice applications on Kubernetes.

  • Cellery SDK

    The SDK allows developers to write, build, run & manage cells. A cell description file is written using the Ballerina programming language. In a nutshell, this file declares the microservice components that have to be included in the cell, the relationship between those components, dependencies to other cells, and it also declares the API that need to be exposed.

    A CLI is also part of this SDK, which allows you to build, run, test and manage your cells.

  • Cellery Mesh

    The mesh provides the wiring & communications medium between cells. Components in a cell cannot invoke components in other cells directly. Only APIs exposed by the cells are invokable. These interactions are strictly governed by security policies.

  • Cellery Management

    This consists of a management plane, which allows you to observe your cells in the runtime, as well as other runtime aspects, and it also allows you to manage security and other policies.


Quickstart Guide

The easiest way to setup Cellery is using the 'local' mode which creates Cellery runtime on Minikube.

Kindly note that if you freshly installed minikube, you would have to execute minikube start, create a temporary cluster and remove it. This is due to a known issue in minikube (kubernetes/minikube#5716).

For other installation approaches including GCP and Docker for Desktop see here

Prerequisites

Download Cellery

Linux

Download the latest Cellery(.deb) installer and install it using dpkg command as shown below.

dpkg -i cellery-ubuntu-x64-<version>.deb

Mac OS

  • Download latest Cellery(.pkg) installer and install it by following macOS package installation steps.

  • Cellery is avaialbe as a Brew Cask. Run below to install through Brew

    brew cask install cellery
    

Setup Cellery runtime

Once Cellery has been installed, verify the installation is working by executing cellery version.

In this quickstart guide, we will install a basic local Cellery runtime by running the following command:

  1. Run the local setup command.

    cellery setup create local -y
    

    This may take a few minutes. If the setup was successful, you should see the following message:

    ✔ Runtime status (Cellery)...OK
    
  2. Once the setup completes, run the following command to check the status:

    cellery list instances
    

    You shouldn't see any errors.

Now that we have installed Cellery let's validate that it is running using a simple cell.

Hello world with Cellery

Let's quickly run a sample hello world cell as shown in the diagram below.

Hello world cell

The hello-world-cell contains one component hello. The hello component is defined by a container image which is written in Node.js and it is a simple webapp. In the quick start we will be deploying the hello-world-cell.

Now let's look at the steps required to run this cell.

  1. Execute the cellery run command that will download the hello-world cell from the wso2cellery organization in cellery hub and run the cell.

    $ cellery run wso2cellery/hello-world-cell:latest -n hello-world-cell
    

    You should see the following output:

    ✔ Connecting to registry.hub.cellery.io
    ✔ Fetching metadata
    ✔ Pulling image wso2cellery/hello-world-cell:latest
    ✔ Saving new Image to the Local Repository
    
    Image Digest : sha256:2d5659e5787df7e7ae0f58671c0b9d857b5a19e5fbdb02fccbc98a64016a97f6
    
    ✔ Extracting Cell Image wso2cellery/hello-world-cell:latest
    ✔ Reading Image wso2cellery/hello-world-cell:latest
    Info: Main Instance: hello-world-cell
    Info: Validating dependencies
    Info: Instances to be Used
    ------------------------------------------------------------------------------------------------------------------------
    INSTANCE NAME                  CELL IMAGE                          USED INSTANCE             KIND            SHARED
    ------------------------------------------------------------------------------------------------------------------------
    hello-world-cell               wso2cellery/hello-world-cell:latest To be Created             Cell            -
    ------------------------------------------------------------------------------------------------------------------------
    Info: Dependency Tree to be Used
    
    No Dependencies
    ✔ Starting main instance hello-world-cell
    
    
    ✔ Successfully deployed cell image: wso2cellery/hello-world-cell:latest
    
    What's next?
    --------------------------------------------------------
    Execute the following command to list running cells:
      $ cellery list instances
    --------------------------------------------------------
    

    Please allow a few minutes for completion.

  2. Execute cellery list instances to check the status of your cell.

    $ cellery list instances
             INSTANCE        CELL IMAGE                           STATUS        GATEWAY               COMPONENTS          AGE
     ---------------------- ------------------------------------ -------- -------------------------- ------------ -----------------------
      hello-world            wso2cellery/hello-world-cell:latest   Ready    hello--gateway-service        1          30 minutes 48 seconds
    
  3. Execute the following command and get the minikube ip address of cellery-local-setup

      minikube ip --profile cellery-local-setup
    

    Add the following line to the /etc/hosts file.

      <MINIKUBE_IP> hello-world.com
    

    Note: The above provided value host entry is for Cellery local setup. If you are using a Cellery on,

    • Existing kubernetes cluster (e.g.: Docker for Mac, Kubeadm, Minikube, etc) - Configure the host entry as explained here.
    • GCP - Configure the host entry as explained /etc/hosts as mentioned here.
  4. Now browse to http://hello-world.com/ and you should see the web page.

    Congratulations! You have successfully got your first cell running!

  5. Finally, terminate the cell instance that you started using the cellery terminate command.

    $ cellery terminate hello-world-cell
    

What's next?

Learn about full lifecycle of cells in Cellery from,

More Repositories

1

reference-architecture

The Reference Architecture for Agility is a technology-neutral logical architecture based on a disaggregated cloud-based model.
1,680
star
2

product-apim

Welcome to the WSO2 API Manager source code! For info on working with the WSO2 API Manager repository and contributing code, click the link below.
Java
759
star
3

product-is

Welcome to the WSO2 Identity Server source code! For info on working with the WSO2 Identity Server repository and contributing code, click the link below.
Java
657
star
4

msf4j

WSO2 Microservices Framework for Java (MSF4J)
Java
401
star
5

product-ei

An open source, a high-performance hybrid integration platform that allows developers quick integration with any application, data, or system.
Java
316
star
6

product-microgateway

Choreo Connect is a cloud-native, open-source, and developer-centric API gateway.
Java
286
star
7

micro-integrator

The cloud-native configuration driven runtime that helps developers implement composite microservices.
Java
193
star
8

product-iots

Welcome to the WSO2 IoT Server source code! For info on working with the WSO2 IoT Server repository and contributing code, click the link below.
Java
174
star
9

carbon-apimgt

Java
159
star
10

apk

Official Repository for APK distribution
Java
149
star
11

WSO2-Training

142
star
12

carbon-kernel

Java
138
star
13

docker-apim

Docker and Docker Compose resources for WSO2 API Manager
Jinja
130
star
14

ETAC

A one-page, Visual Canvas for Emerging Technology Evaluation, in the style of “the Business model Canvas".
127
star
15

k8s-api-operator

API Operator for Kubernetes
Go
114
star
16

balana

Java
113
star
17

streaming-integrator

A stream processing runtime that allows connecting any streaming data source to any destination and act on it
Python
112
star
18

jaggery

The delicious Javascript framework
Java
112
star
19

kubernetes-apim

Kubernetes and Helm resources for WSO2 API Manager
Smarty
105
star
20

charon

Java
102
star
21

carbon-identity-framework

Java
101
star
22

wso2-synapse

Java
98
star
23

docker-is

Docker and Docker Compose resources for WSO2 Identity Server
Dockerfile
86
star
24

reference-methodology

Integration projects today follow a time-consuming waterfall model, ill-suited to solving complex integration challenges. In response, WSO2 has developed organizational, project management, and technical expertise to help IT organizations transform integration projects to a more efficient and scalable continuous agile approach.
85
star
25

product-sp

An open source, cloud-native streaming data integration and analytics product optimized for agile digital businesses
Python
82
star
26

cdmf-agent-android

Java
76
star
27

ballerina-integrator

A powerful, simple-to-learn, code-driven approach to programming integrations
Java
70
star
28

docs-apim

Java
70
star
29

identity-apps

TypeScript
67
star
30

istio-apim

Java
65
star
31

carbon-mediation

Java
65
star
32

kubernetes-is

Kubernetes and Helm resources for WSO2 Identity Server
Shell
64
star
33

carbon-analytics

JavaScript
63
star
34

docs-ei

CSS
63
star
35

docs-is

CSS
62
star
36

integration-studio

WSO2 Integration Studio is a development environment used to design integration scenarios and develop them.
Java
60
star
37

product-app-manager

Welcome to the WSO2 App Manager source code! For info on working with the WSO2 App Manager repository and contributing code, click the link below.
HTML
56
star
38

k8s-wso2am-operator

WSO2 API Manager Operator for Kubernetes
Go
55
star
39

analytics-apim

Analytics for APIM
JavaScript
52
star
40

cellery-spec

52
star
41

Linux-training

Host Linux Training public documents
Shell
52
star
42

carbon-device-mgt

Java
51
star
43

developer-studio

WSO2 Developer Studio IDE Public Repository
Java
51
star
44

carbon-dashboards

JavaScript
51
star
45

caramel

A bootstrap project to create fully dynamic websites using jaggery
JavaScript
50
star
46

carbon-commons

Java
49
star
47

identity-api-server

Java
49
star
48

soap-to-rest

Library capable of converting SOAP backend service to REST backends
Java
48
star
49

security-tools

Java
48
star
50

product-es

Welcome to the WSO2 Enterprise Store source code! For info on working with the WSO2 Enterprise Store repository and contributing code, click the link below.
Java
48
star
51

apim-apps

WSO2 API Manager portals web UI apps
JavaScript
47
star
52

kubernetes-pipeline

This project contains the Helm resources required to deploy CI/CD Pipeline in a Kubernetes environment for WSO2 products.
Dockerfile
47
star
53

cellery-controller

Go
46
star
54

carbon-business-process

Java
46
star
55

carbon-data

Data services and related components
Java
46
star
56

streaming-integrator-tooling

Java
45
star
57

carbon-analytics-common

Java
45
star
58

cellery-samples

JavaScript
45
star
59

cellery-observability

JavaScript
45
star
60

wso2-axis2

Java
44
star
61

cellery-distribution

Java
44
star
62

orbit

Java
44
star
63

carbon-appmgt

JavaScript
44
star
64

wso2-axis2-transports

Java
44
star
65

samples-is

JavaScript
43
star
66

mule-conversion-samples

Sample projects to help migrate from Mulesoft Anypoint Platform
43
star
67

carbon-governance

jagery
Java
43
star
68

k8s-wso2is-operator

Identity Server Kubernetes Controller
Go
43
star
69

jaggery-extensions

Extensions repository for Jaggery
JavaScript
43
star
70

carbon-registry

Java
43
star
71

product-mi-tooling

Tooling for Micro Integrator
Java
43
star
72

VizGrammar

Interactive Generic Visualization library for Javascript that is based on d3.js
JavaScript
43
star
73

carbon-ml

Java
42
star
74

code-quality-tools

42
star
75

ansible-ei

Jinja
42
star
76

product-as

Welcome to the WSO2 Application Server source code! For info on working with the WSO2 Application Server repository and contributing code, click the link below.
Java
42
star
77

analytics-solutions

JavaScript
42
star
78

oxygen-ui

The Design System powering WSO2 products.
TypeScript
42
star
79

carbon-device-mgt-plugins

JavaScript
42
star
80

cdmf-agent-ios

Objective-C
42
star
81

carbon-deployment

Java
42
star
82

identity-api-user

Java
41
star
83

product-apim-tooling

Go
41
star
84

wso2-commons-vfs

Java
41
star
85

cellery-security

Java
41
star
86

carbon-event-processing

JavaScript
41
star
87

carbon-platform-integration

Java
41
star
88

container-guide

The Guide of Best Practices for Running WSO2 Products on Containerized Platforms
41
star
89

ballerina-vscode

To keep Ballerina VSCode plugin related issues, discussions, etc.
41
star
90

devstudio-tooling-esb

Java
40
star
91

choreo-samples

This will contain integration and service samples displayed in choreo.
TypeScript
40
star
92

identity-rest-dispatcher

Java
40
star
93

ob-conformance-suite

CSS
40
star
94

maven-tools

Java
40
star
95

carbon-transports

Java
40
star
96

andes

Java
39
star
97

docs-open-banking

CSS
39
star
98

docs-choreo-dev

Choreo documentation repository for ongoing dev tasks.
HTML
39
star
99

puppet-apim

Shell
39
star
100

carbon-business-messaging

Java
39
star