Developing Microservices with GO

By Anand Joshi

Elevator Pitch

A simple Notes application that will demonstrate how to write a microservice in GO.
You will build solid Foundation of Golang concepts for developing microservices, learn how to Dockerize them and deploy them into Kubernetes. It will all be a live coding experience. Get Set Gooo!!!

Description

Developing Microservice with GO

Introduction

A simple Notes application that will demonstrate how to write a microservice in GO. This application will provide CRUD API operations for notes. This application will be deployed to Kubernetes in a docker container.

Takeaways for Audience from this talk

  • Audience will have a full working API service written in GO with Dockerfile and Kubernetes deployment definition with full access to source code in github
  • Solid foundation of concepts to write microservice in GO
  • A working example of Dockerfile for a GO application and how to build GO code in container
  • A working example of Kubernetes Deployment resource that demonstrate ReplicaSet and Rolling deployment concept.

Notes

What the talk will cover

During this talk I plan to cover following concepts of GO programming language

Structures and Structure Functions How structures are written in GO and how to declare Structure Functions using 1. Receiver pointer 2. Interface

JSON Marshaling/Unmarshaling Basics How to work with JSON in GO - quick introduction to JSON package, string - byte conversions

JSON Annotations How structure members are enriched with JSON annotations to control JSON representation

Introduction to Gorilla Mux How to start the Microservice using gorilla mux and net http packages with route and corresponding handler functions.

Dockerization of GO Microservice Introduction to how to Dockerize a GO Microservice. Setting up Dockerfile with golang base image, use of “go get” to install required tools in container to build in the container.

Deploy to Kubernetes A quick deployment to local Kubernetes(Minikube). Use of Kubernetes “Deployment” resource