Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
Amazingly Simple Serverless Go
September 2017 Golang Meetup
Yun Zhi Lin, Microservices Architect
1
2
3
Why Go + Serverless
(Gopher) Event Driven Architecture
Demo and Examples
Why SLS Golang
Why
People want Golang!
But got .Net Core instead 
Why Serverless Framework?
The most versatile out of all golang enabled serverless libraries
Framework Provider Languages G...
Secret Sauce – EAWSY Shim
Eawsy’s Shim is 2nd fastest way to run AWS Lambda from cold starts
(Gopher)
Event Driven
Architecture
Life prior to Microservices and Gophers
Mobile Backend
Frontend
Life after Event Driven Microservices, with Gophers!
2 Docker Go MicroServices + 14 Go Lambdas
SSO SCVJAMstack JAMstack
Demo & Examples
Kinesis Event Source
Go code serverless.yml
func DataLogger(
evt *kinesisstreamsevt.Event)(
interface{}, error) {
rs := ev...
Go Net with API Gateway
Go code serverless.yml
functions:
crud:
handler: handler.Handler
events:
- http:
path: todos
metho...
Demo
Credits and Road Map
This library would not be possible without the help of:
• @cristm from HereMaps
• Serverless.com and ...
Upcoming SlideShare
Loading in …5
×

Amazingly Simple Serverless Go

1,243 views

Published on

2017 September Golang Sydney meetup https://www.meetup.com/golang-syd/events/243263974/

Yun Zhi Lin wrote serverless-golang to bring about the perfect combination of strongly typed idiomatic Golang with the simplicity of Serverless Framework.

Serverless Golang currently forms the backbone of amaysim’s Serverless Realtime Event Driven Architecture, Anti-Corruption Layer and Single Customer View across 4 business verticals.

The library comes with easy to follow real world examples, and is entirely built and deployed immutably via Docker.

Published in: Technology
  • Be the first to comment

Amazingly Simple Serverless Go

  1. 1. Amazingly Simple Serverless Go September 2017 Golang Meetup Yun Zhi Lin, Microservices Architect
  2. 2. 1 2 3 Why Go + Serverless (Gopher) Event Driven Architecture Demo and Examples
  3. 3. Why SLS Golang Why
  4. 4. People want Golang! But got .Net Core instead 
  5. 5. Why Serverless Framework? The most versatile out of all golang enabled serverless libraries Framework Provider Languages Golang Shim Infrastructure Apex AWS Node Golang Node Partial GoSparta AWS Golang Node Partial Serverless Framework AWS Azure Google Openwhisk Kubeless Python Node Java .Net Python Full - Dev friendly YML - Ops friendly CF
  6. 6. Secret Sauce – EAWSY Shim Eawsy’s Shim is 2nd fastest way to run AWS Lambda from cold starts
  7. 7. (Gopher) Event Driven Architecture
  8. 8. Life prior to Microservices and Gophers Mobile Backend Frontend
  9. 9. Life after Event Driven Microservices, with Gophers! 2 Docker Go MicroServices + 14 Go Lambdas SSO SCVJAMstack JAMstack
  10. 10. Demo & Examples
  11. 11. Kinesis Event Source Go code serverless.yml func DataLogger( evt *kinesisstreamsevt.Event)( interface{}, error) { rs := evt.Records for r := range rs { log.Println(r) } return evt.String(), nil } functions: logger: handler: handler.DataLogger events: - stream: ${env:AWS_KINESIS_ARN}
  12. 12. Go Net with API Gateway Go code serverless.yml functions: crud: handler: handler.Handler events: - http: path: todos method: post cors: true - http: path: todos method: get cors: true - http: path: todos/{id} method: get cors: true func setUpMux() *mux.Router { r := mux.NewRouter() r.HandleFunc("/todos", create) .Methods(http.MethodPost) r.HandleFunc("/todos", list) .Methods(http.MethodGet) r.HandleFunc("/todos/{id}", read) .Methods(http.MethodGet) … return r }
  13. 13. Demo
  14. 14. Credits and Road Map This library would not be possible without the help of: • @cristm from HereMaps • Serverless.com and Eawsy.com • @flemay from amaysim for the awesome logo Coming soon: • dynamodb example with localstack • Event Gateway and FDK • Azure integration

×