Go Fundamentals: Interfaces, Embedding & Composition, and Concurrency

Duration: 3 Hours

In this second installment of Go Fundamentals, you will learn the powerful concept of Interfaces, Embedding and Composition. From there, take a tour around Go's elegant implementation of concurrency. Learn the idiomatic way to write go and common mistakes and pitfalls that developers new to the language should know.

Each attendee will receive a link 24 hours prior to the start of the workshop with links to all class material. Additionally, each attendee will receive a link after the workshop to the recording of the workshop as well.

Having problems purchasing above? Purchase directly from Eventbrite

Workshop Overview

This module covers general information about your instructor and course materials.

This module covers general environment setup and other resource related information needed to complete the courses contained within.

Interfaces in Go provide a way to specify the behavior of an object: if something can do this, then it can be used here. This module will take a look at how to use interfaces to abstract that behavior. Concepts such as the Empty Interface, satisfying multiple interfaces, and asserting for behavior will be covered. Additionally this module will cover the difference between value and pointer receivers and how they affect the ability to satisfy an interface.

Go does not provide the typical, type-driven notion of subclassing, but it does have the ability to “borrow” pieces of an implementation by embedding types within a struct or interface. This module will cover how promotion from embedding works as well how collision and overriding are handled. You will also walk through how to embed types to be able to satisfy a specific interface.

Concurrent programming in many environments is made difficult by the subtleties required to implement correct access to shared variables. Go encourages a different approach in which shared values are passed around on channels and, in fact, never actively shared by separate threads of execution.

This module covers Go routines and how to synchronize communication between them. Mechanics for synchronization such as WaitGroups, Mutexs, and Channels are explored along with the corresponding patterns for each. Find out the difference between a buffered and unbuffered channel, and when to use them. Also discover how to use channels for signaling for concepts such as graceful application shutdown.

This module covers where to get more support on Go, recommends books and videos, and list contact information for our instructors.

Mark Bates

Cofounder/Instructor

Mark specializes in Go Fundamentals, Advanced Go, Web Development, and Buffalo.