4. Disclaimer
● The following contents are a product of tinkering and running
into walls constantly. By no means am I an expert or even a
fledgling at the topics being discussed but I hope to showcase
something perhaps new and hopefully also interesting.
7. Microservice
A more specific thing
Another more specific thing
Yet another more specific thing
Result
● Moderately sized
● Single Purposed
● Can test in isolation
● Communication
between different
services can be
complicated
8. Serverless
A very small specific thing
Result of a
function
A very small specific thing
A very small specific thing
A very small specific thing● Small (function)
sized
● Super single
purposed
● Can test in isolation
● No need to manage
the infrastructure
10. Container Features
● Environment isolation
● Runs ‘anywhere’ and runs ‘anything’
● Lightweight virtual machines
● Lightens the load of needing to manage
infrastructure / dependencies for the dev
11. Container Features cont’d
● Ephemeral (cattle vs pets) - State isn’t
persistent
● Built in layers
● Networking can be complicated (though tooling
has eased this docker-compose)
13. Containers on their own lack:
● Scheduling
● Persistence / Health checks
● Autoscaling
● Metrics
● Consistent Networking
Things provided by container orchestration:
15. Pods
● Abstraction
● Groups one or more containers which share the
same contexts (storage, networking, etc)
● Akin to living in the same physical / virtual
machine
● Are ephemeral
17. Services
● Provides a north star to find the place of our
applications / pods even if they perish and enter
the cycle of samsara
● The IP of a pod may not be stable as they live
and die, services allow for a consistent way to
find the pods which offer that functionality
23. API Gateway / UI Portal
● Your API Gateway will scale functions according to demand
by altering the number of replicas of your services / functions
● A UI is baked in allowing you to invoke functions in your
browser and create new ones as needed.
24. How to interact (create functions) in
openfaas
1. faas CLI
2. Gateway UI
25. faas-cli
1. Create a handler (from a template)
2. Build the docker container
3. Push it up to a repo
4. Deploy the container
28. Sources of more information
● https://github.com/openfaas/faas - Main repo
● http://docs.openfaas.com/ - Documentation
● https://github.com/openfaas/workshop - Tutorial series
● https://gist.github.com/alexellis/fdbc90de7691a1b9edb545c1
7da2d975 - Gist on setting up Kubernetes on RPI
● https://blog.alexellis.io/ - Openfaas creator/founder’s blog
● https://github.com/openfaas/faas/tree/master/watchdog -
About the function watchdog