Go Concurrency Series: Introduction to Goroutines

Concurrency is a fundamental concept in modern software development, enabling programs to handle multiple tasks simultaneously, thus increasing efficiency and performance. In this blog series, we’ll cover concurrency concepts specific to Golang, however the concepts themselves are generic and could be applied in a language agnostic manner!

Concurrency Introduction

Concurrency Vs Parallelism

Before diving into concurrency, its important to understand the difference between concurrency and parallelism as these are terms which often used interchangeably but have distinct meanings.

Concurrency is about dealing with multiple tasks at once. It involves structuring a program to handle multiple tasks simultaneously, even if not all are progressing at the same instant. It’s more about the composition of independently executing processes.

Parallelism, on the other hand, is about doing multiple tasks at the same time. It requires a multi-core processor where separate tasks run simultaneously on different cores.

Let’s consider the operations at a busy international airport to further illustrate the concepts of concurrency and parallelism.

Situation: At every airport, we have an air traffic controller, who is responsible for performing multiple tasks…

--

--

Pratik Pandey - https://pratikpandey.substack.com

Senior Engineer with experience in designing and architecting large scale distributed systems.