Copyright
Brief Table of Contents
Table of Contents
Foreword
Preface
Acknowledgments
About this Book
About the Authors
About the Cover Illustration
1. Background and fundamentals
Chapter 1. Getting into Go
1.1. What is Go?
1.2. Noteworthy aspects of Go
1.2.1. Multiple return values
1.2.2. A modern standard library
1.2.3. Concurrency with goroutines and channels
1.2.4. Go the toolchain—more than a language
1.3. Go in the vast language landscape
1.3.1. C and Go
1.3.2. Java and Go
1.3.3. Python, PHP, and Go
1.3.4. JavaScript, Node.js, and Go
1.4. Getting up and running in Go
1.4.1. Installing Go
1.4.2. Working with Git, Mercurial, and version control
1.4.3. Exploring the workspace
1.4.4. Working with environment variables
1.5. Hello, Go
1.6. Summary
Chapter 2. A solid foundation
2.1. Working with CLI applications, the Go way
2.1.1. Command-line flags
2.1.2. Command-line frameworks
2.2. Handling configuration
Technique 3 Using configuration files
Technique 4 Configuration via environment variables
2.3. Working with real-world web servers
2.3.1. Starting up and shutting down a server
2.3.2. Routing web requests
2.4. Summary
Chapter 3. Concurrency in Go
3.1. Understanding Go’s concurrency model
3.2. Working with goroutines
Technique 10 Using goroutine closures
Technique 11 Waiting for goroutines
Technique 12 Locking with a mutex
3.3. Working with channels