Mastering Multithreading Programming with Go (Golang)

Learn about Multithreading, Concurrency & Parallel programming with practical and fun examples in Google's Go Lang

4.53 (602 reviews)
Udemy
platform
English
language
Software Engineering
category
instructor
4,909
students
5.5 hours
content
Jul 2022
last update
$109.99
regular price

What you will learn

Discover how to create responsive and high performance software.

See how to use multithreading for modeling certain types of problems and simulations.

Develop programs with Golang that are highly Concurrent and Parallel.

Understand the advantages, limits and properties of Parallel computing.

Improve your programming skills in Go with more advanced, mulithreading topics.

Learn about goroutines, mutexes, reader writers locks, waitgroups, channels, condition variables and more.

Description

The mood in the meeting on the 12th floor of an international investment bank was as bleak as it gets. The developers of the firm met to discuss the best way forward after a critical core application failed and caused a system wide outage.


"Guys, we have a serious issue here. I found out that the outage was caused by a race condition in our code, introduced a while ago and triggered last night." says Mark Adams, senior developer.


The room goes silent. The cars outside the floor to ceiling windows slowly and silently creep along in the heavy city traffic. The senior developers immediately understand the severity of the situation, realizing that they will now be working around the clock to fix the issue and sort out the mess in the datastore. The less experienced developers understand that a race condition is serious but don't know exactly what causes it and therefore keep their mouths shut.


Eventually Brian Holmes, delivery manager, breaks the silence with "The application has been running for months without any problems, we haven't released any code recently, how is it possible that the software just broke down?!"


Everyone shakes their heads and goes back to their desk leaving Brian in the room alone, puzzled. He takes out his phone and googles "race condition".


Sound familiar? How many times have you heard another developer talking about using threads and concurrent programming to solve a particular problem but out of fear you stayed out of the discussion?


Here's the little secret that senior developers will never share... Multithreading programming is not much harder than normal programming. Developers are scared of concurrent programming because they think it is an advanced topic that only highly experienced developers get to play with.


This is far from the truth. Our minds are very much used to dealing with concurrency. In fact we do this in our everyday life without any problem but somehow we struggle to translate this into our code. One of the reasons for this is that we're not familiar with the concepts and tools available to us to manage this concurrency. This course is here to help you understand how to use multithreading tools and concepts to manage your parallel programming. It is designed to be as practical as possible. We start with some theory around parallelism and then explain how the operating system handles multiple processes and threads. Later we move on to explain the multiple tools available by solving example problems using multithreading.


In this course we use Google's Go programming language with its goroutines, however the concepts learned here can be applied to most programming languages.


All code in this course can be found on github, username/project: cutajarj/multithreadingingo

Content

Introduction

Understanding Parallel Computing
More on Parallel Computing
Links and Resources for this course

Creating and using Threads

Processes, Threads and Green threads
Using Goroutines for Boids
Groundwork for our simulation
Starting our Goroutines
Memory sharing between Threads
Memory Sharing example Part 1
Memory Sharing example Part 2
Using Threads Quiz

Thread Synchronization with Mutexes

Why do we need Locking?
Using Mutexes in Boid simulation
Adding Synchronization to simulation
Readers-Writer Locks
Boid Synchronization with Readers-Writers Locks
Mutexes Quiz

Waiting for Completed tasks

Understanding WaitGroups
Concurrent file searching with WaitGroups
WaitGroup Quiz

Message passing with Channels

Thread Communication using Channels
Pipelining Example
Understanding Thread Pools
Thread Pool Example Part 1
Thread Pool Example Part 2
Channels Quiz

Synchronization using Condition Variables

What's a Condition Variable?
Parallel Algorithm for Matrix Multiplication
Implementing Parallel Matrix Multiplication Part 1
Implementing Parallel Matrix Multiplication Part 2
Condition Variable Quiz

Screenshots

Mastering Multithreading Programming with Go (Golang) - Screenshot_01Mastering Multithreading Programming with Go (Golang) - Screenshot_02Mastering Multithreading Programming with Go (Golang) - Screenshot_03Mastering Multithreading Programming with Go (Golang) - Screenshot_04

Reviews

Elijah
April 11, 2023
James is an outstanding instructor. He explains concepts in a concise and intuitive way. There are great coding exercises to help students reinforce their learning. The material he's prepared is fundamental for any developer looking to utilise concurrent programming in their projects.
Jamshidbek
April 1, 2023
This course gives harder examples instead of giving simple example and focusing more on the main topic.
Goffredo
January 21, 2023
the instructor know very well the matter and able to simplify and visualize tough concepts about multithreading paradigm. great job!
Arturo
November 11, 2022
I'm learning a lot and the instructor is experienced and able to communicate efficiently and with good engagement
Cynthia
October 30, 2022
Too focused on boids. While this course does go into concurrency, I feel like it's massively overshadowed with the complication of explaining boids and its algorithms. I care a lot about learning about concurrency. but I care very little about boids. I'm just powering through right now since otherwise it is wasted money. I recommend another course if you just want to learn about go concurrency.
James
October 20, 2022
Excellent illustrative examples, with diagrams, before moving to code. Which in most cases starts with a simple example and build to something more real world.
Roberto
October 4, 2022
It was a great course! Teaching Deadlock with trains and graphs was amazing! Congratulations!!! I recommended it!
Giorgio
September 5, 2022
I'm a software engineer so I'm already familiar with the concepts. I think this course explain very well the basics of concurrency. It is also very useful to me to understand the same in Go language.
Renato
July 4, 2022
The course is fantastic. All the code examples that James brought are straight forward and made it easier for me to understand. I really recommend the course
Sebastian
June 13, 2022
Theoretical knowledge is really nice, but in my opinion such topic should contain more practical tasks for homework and then solution should be provided.
Alexander
May 1, 2022
One of the most interesting course of all ones I've ever took. I am in programming for more than 20 years and had to deal with multithreading many times. Still, I've never had such a clear and simple multithreading perspective as I have now after finishing this course. All concepts are explained in the most simple and very well visualised way. All examples are viable, useful and back up concepts with clarity. Despite the fact that couple of times I struggled to reproduce examples by video (that is why I gave 4.5 instead of 5, and don't worry, all sources codes are supplied with the course, I just did not like to use them), in all other respects the course is outstanding. Highly recommend.
Rob
April 28, 2022
The course covers the concepts well, but it's pretty abstract: none of the examples are particularly practical, and some of them are fanciful, which is fun, but won't help you figure out which of these concepts you want to do in a real project.
Nicklas
February 22, 2022
A lot of the problems were overly complex for the usage of the different multithreading techniques. Creating an unnecessary layering of complexity.
Diego
February 2, 2022
The course is amazing! The way the instructor conducts the classes is amazing. Just one note that the first example of boids was not so good because the example had a high complexity so we spend to much time to understand and we loose the focus of the course that is about threads in go.
Sean
January 11, 2022
The examples chosen are well thought out. Not too academic or contrived. They perfectly illustrate the concepts. I am very impressed. After little effort, I have a much more solid understanding of concurrency features in Go

Charts

Price

Mastering Multithreading Programming with Go (Golang) - Price chart

Rating

Mastering Multithreading Programming with Go (Golang) - Ratings chart

Enrollment distribution

Mastering Multithreading Programming with Go (Golang) - Distribution chart
2841404
udemy ID
2/28/2020
course created date
3/21/2020
course indexed date
Bot
course submited by