🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Sign inDemoInstall
Socket

github.com/miruked/Go-Programming-Cookbook-Second-Edition

Package Overview
Dependencies
Alerts
File Explorer
Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github.com/miruked/Go-Programming-Cookbook-Second-Edition

v0.0.0-20220614004814-4d508b638933
Source
Go
Version published
Created
Source

Go Programming Cookbook - Second Edition

Go Programming Cookbook - Second Edition

This is the code repository for Go Programming Cookbook - Second Edition , published by Packt.

Over 85 recipes to build modular, readable, and testable Golang applications across various domains

What is this book about?

Go (or Golang) is a statically typed programming language developed at Google. Known for its vast standard library, it also provides features such as garbage collection, type safety, dynamic-typing capabilities, and additional built-in types. This book will serve as a reference while implementing Go features to build your own applications.

This book covers the following exciting features:

  • Work with third-party Go projects and modify them for your use
  • Write Go code using modern best practices
  • Manage your dependencies with the new Go module system
  • Solve common problems encountered when dealing with backend systems or DevOps
  • Explore the Go standard library and its uses Test, profile, and fine-tune Go applications

If you feel this book is for you, get your copy today!

https://www.packtpub.com/

Instructions and Navigations

All of the code is organized into folders. For example, Chapter02.

The code will look like the following:

                b, err := ioutil.ReadAll(r)
                if err != nil {
                    return "", err
                }
                return string(b), nil
        }

Following is what you need for this book: This book is aimed for web developers, programmers, and enterprise developers. Basic knowledge of the Go language is assumed. Experience with backend application development is not necessary, but may help understand the motivation behind some of the recipes.

This book serves as a good reference for Go developers who are already proficient but need a quick reminder, example, or reference. With the open source repository, it should be possible to share these examples quickly with a team as well. If you are looking for quick solutions to common and not-so-common problems in Go programming, this book is for you.

Errata

The following content at Page 323 under How it works... should read as: Consul provides a robust Go API library. It can feel daunting when you're starting for the first time, but this recipe shows how you might approach wrapping it. Configuring Consul further is beyond the scope of this recipe; this shows the basics of registering a service and querying for other services when given a key and tag. It would be possible to use this to register new microservices at startup time, query for all dependent services, and deregister at shutdown. You may also want to cache this information so that you're not hitting Consul for every request, but this recipe provides the basic tools that you can expand upon. The Consul agent also makes these repeated requests fast and efficient (https://www.consul.io/intro/getting-started/agent.html).

With the following software and hardware list you can run all code files present in the book (Chapter 1-).

Software and Hardware List

ChapterSoftware requiredOS required
AllGo - latest versionWindows, macOS and Linux
AllUnix Shell - any versionWindows, macOS and Linux
6MySQL - latest versionWindows, macOS and Linux
6Redis - latest versionWindows, macOS and Linux
6MongoDB - latest versionWindows, macOS and Linux
11consul.io - latest versionWindows, macOS and Linux
11Docker - latest community edition versionWindows, macOS and Linux
11Prometheus - latest versionWindows, macOS and Linux

Get to Know the Author

Aaron Torres received his master's degree in computer science from the New Mexico Institute of Mining and Technology. He has worked on distributed systems in high-performance computing and in large-scale web and microservices applications. He currently leads a team of Go developers that refines and focuses on Go best practices with an emphasis on continuous delivery and automated testing.

Aaron has published a number of papers and has several patents in the area of storage and I/O. He is passionate about sharing his knowledge and ideas with others. He is also a huge fan of the Go language and open source for backend systems and development.

Suggestions and Feedback

Click here if you have any feedback or suggestions.

FAQs

Package last updated on 14 Jun 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts