- Browse
- » Hands-on software engineering with Golang: move beyond basic programming to design and build reliable software with clean code
Hands-on software engineering with Golang: move beyond basic programming to design and build reliable software with clean code
Author
Publisher
Packt Publishing
Publication Date
2020.
Language
English
Description
Loading Description...
Table of Contents
From the eBook
Intro
Title Page
Copyright and Credits
Dedication
About Packt
Contributors
Table of Contents
Preface
Section 1: Software Engineering and the Software Development Life Cycle
Chapter 1: A Bird's-Eye View of Software Engineering
What is software engineering?
Types of software engineering roles
The role of the software engineer (SWE)
The role of the software development engineer in test (SDET)
The role of the site reliability engineer (SRE)
The role of the release engineer (RE)
The role of the system architect
A list of software development models that all engineers should know
Waterfall
Iterative enhancement
Spiral
Agile
Lean
Eliminate waste
Create knowledge
Defer commitment
Build in quality
Deliver fast
Respect and empower people
See and optimize the whole
Scrum
Scrum roles
Essential Scrum events
Kanban
DevOps
The CAMS model
The three ways model
Summary
Questions
Further reading
Section 2: Best Practices for Maintainable and Testable Go Code
Chapter 2: Best Practices for Writing Clean and Maintainable Go Code
The SOLID principles of object-oriented design
Single responsibility
Open/closed principle
Liskov substitution
Interface segregation
Dependency inversion
Applying the SOLID principles
Organizing code into packages
Naming conventions for Go packages
Circular dependencies
Breaking circular dependencies via implicit interfaces
Sometimes, code repetition is not a bad idea!
Tips and tools for writing lean and easy-to-maintain Go code
Optimizing function implementations for readability
Variable naming conventions
Using Go interfaces effectively
Zero values are your friends
Using tools to analyze and manipulate Go programs
Taking care of formatting and imports (gofmt, goimports)
Refactoring code across packages (gorename, gomvpkg, fix)
Improving code quality metrics with the help of linters
Summary
Questions
Further reading
Chapter 3: Dependency Management
What's all the fuss about software versioning?
Semantic versioning
Comparing semantic versions
Applying semantic versioning to Go packages
Managing the source code for multiple package versions
Single repository with versioned folders
Single repository
multiple branches
Vendoring
the good, the bad, and the ugly
Benefits of vendoring dependencies
Is vendoring always a good idea?
Strategies and tools for vendoring dependencies
The dep tool
The Gopkg.toml file
The Gopkg.lock file
Go modules
the way forward
Fork packages
Summary
Questions
Further reading
Chapter 4: The Art of Testing
Technical requirements
Unit testing
Mocks, stubs, fakes, and spies
commonalities and differences
Stubs and spies!
Mocks
Introducing gomock
Excerpt
Loading Excerpt...
Author Notes
Loading Author Notes...
More Details
ISBN
9781838550240
Reviews from GoodReads
Loading GoodReads Reviews.