GithubHelp home page GithubHelp logo

hhy5277 / faas Goto Github PK

View Code? Open in Web Editor NEW

This project forked from openfaas/faas

0.0 2.0 0.0 1.56 MB

Functions as a Service (on Docker Swarm)

Home Page: http://blog.alexellis.io/functions-as-a-service/

License: MIT License

Shell 7.79% HTML 18.55% Go 61.99% JavaScript 11.46% Makefile 0.22%

faas's Introduction

Functions As A Service (faas)

FaaS is a platform for building serverless functions on Docker Swarm Mode with first class metrics. Any UNIX process can be packaged as a function in FaaS enabling you to consume a range of web events without repetitive boiler-plate coding.

Concept

  • Each container has a watchdog process that hosts a web server allowing a JSON post request to be forwarded to a desired process via STDIN. The response is sent to the caller via STDOUT.
  • A gateway provides a view to the containers/functions to the public Internet and collects metrics for Prometheus and will manage replicas and auto-scale as throughput increases.

Read the story of FaaS on my blog or find out more about the project below.

Build Status

Minimum requirements:

  • Docker 1.13 (to support attachable overlay networks)
  • At least a single host in Swarm Mode. (run docker swarm init)

TestDrive

You can test-drive FaaS with a set of sample functions as defined in docker-compose.yml on play-with-docker.com for free, or on your own laptop.

Highlights:

  • Ease of use through UI portal

  • Setup a working environment with one script

  • Portable - runs on any hardware

  • Baked-in Prometheus metrics

  • Any container can be a function

  • Auto-scales as demand increases

Here is a screenshot of the API gateway portal - designed for ease of use.

Portal

Ongoing development/screenshots:

FaaS is still expanding and growing, check out the developments around:

Develop your own functions

Roadmap and contributing

Additional content

Would you prefer a video overview?

See how to deploy FaaS onto play-with-docker.com and Docker Swarm in 1-2 minutes. See the sample functions in action and watch the graphs in Prometheus as we ramp up the amount of requests.

Prometheus metrics are built-in

Prometheus is built into FaaS and the sample stack, so you can check throughput for each function individually with a rate function in the UI at port 9090 on your Swarm manager.

If you are new to Prometheus, you can start learning about metrics and monitoring on my blog:

Monitor your applications with Prometheus

Prometheus UI

faas's People

Contributors

alexellis avatar chanezon avatar tleyden avatar vegasbrianc avatar

Watchers

 avatar  avatar

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.