Training

Introduction to Go

Introduction to Go is a one day workshop that introduces programmers with prior experience to the basics of Go.

This workshop assumes you have prior experience with another common programming language; Python, Java, Ruby, Perl, Javascript, C, for example. This workshop will show you how to apply your knowledge of programming to Go. As the workshop assumes no knowledge of Go, if you have written some Go code, you may find the morning session boring or repetitive.

Syllabus

The workshop is divided in five sections.

  • Syntax

    An introduction to the basic syntax of the language; numbers, expressions; addition, subtraction, etc, variables, assignment, arrays, slices and subslices, loops, conditionals, switch, and functions

  • Language details

    In this second section we’ll revisit each of the topics of the previous section and expand on each; literals, identifiers, types, structs, constant expressions, zero values, short declaration syntax, scopes, constants, range, pointers, nil, and methods.

  • Development environment

    This section focuses on the developer experience, installing Go and setting up a $GOPATH workspace, introduction to the go command, and writing unit tests with the go test command.

  • The standard library

    Go ships with a rich standard library of packages. This section will focus on the important packages from the standard library with exercises.

  • Packages and applications

    The final section will focus on designing your own reusable Go packages and combining those into complete applications.

Prerequisites

  • Each student should have experience with a programming language other than Go.
  • Each student must provide their own laptop with permission to install software.
  • A reliable internet connection at the training venue is required.

Outcomes

At the end of the day you will be able to:

  • Install Go and configure your development environment.
  • Learn the syntax and structure of Go programs.
  • Learn to write and test Go packages.
  • Learn to build complete Go applications.

Training Dates

  • December 10th, Tokyo, Japan

Materials:

All training materials are supplied under a CC-SA 4.0 licence


High Performance Go

High Performance Go is a half day workshop that teaches the foundations of writing Go code that performs well at scale.

Syllabus

  • What does performance mean, what is possible?

    A short introduction that describes the current computing landscape, what modern cpu’s look like, what they like (sequential data), and what they don’t like (random, unpredictable data).

  • Benchmarking

    How to write effective benchmarks, and how to interpret their results. This section includes some traps for young players and advice for how to avoid them.

  • Performance measurement and profiling

    How to use the tools built into the Go runtime, and other tools like perf(1) to gain an understanding on what your code is doing.

  • Memory management and GC tuning

    As Go is a garbage collected language, understanding, and working with the garbage collector is a large part of writing performant applications.

  • Concurrency

    The final section focuses on using (and not overusing) Go’s concurrency features.

After each section there will be ample time for questions from the students.

Once all the sections are complete the remainder of the time will be dedicated to assisting the students in applying the material to their own projects.

Prerequisites

  • Each student must provide their own laptop with a current working Go environment.
  • Students are expected to bring real code to profile and improve.

Outcomes

At the end of the day you will be able to

  • Write reliable benchmarks.
  • Profile existing programs.
  • Identify common bottlenecks.
  • Address performance bottlenecks and measure the result.

Who should attend

  • Familiarity with the Go programming language is assumed. This is not an introductory course on Go programming.
  • Students should have written and deployed a Go application to production.

Training Dates

Materials:

All training materials are supplied under a CC-SA 4.0 licence