hands-on lab

Creating a Microservice in Go - Part 2

Difficulty: Intermediate
Duration: Up to 1 hour
Students: 221
Rating: 4.4/5
Get guided in a real environmentPractice with a step-by-step scenario in a real, provisioned environment.
Learn and validateUse validations to check your solutions every step of the way.
See resultsTrack your knowledge and monitor your progress.

Description

You have a small collection of retro video games and you want to upgrade the previously built microservice API to manage them. In this lab, you will build upon what you worked on for Part 1, by adding RESTful update and delete functionality for a game entity. Lastly, you will create a bonus endpoint, that will allow the user to filter the results by game console.

This lab builds off of a previous one. If you have not already completed part one of this lab series, please do that first before continuing with this lab.

Learning Objectives

Upon completion of this lab you will be able to:

  • Implement web server code and SQL code to update entities in a database
  • Implement web server code and SQL code to delete entities from a database
  • Implement web server code and SQL code to filter entities from a database

Intended Audience

This lab is intended for:

  • Developers, especially those working with Go
  • Anyone leveraging containers

Prerequisites

You should possess:

  • Basic understanding of the Go programming language
  • Familiarity with basic SQL commands
  • Understanding of the Linux command line
  • Experience with JSON and CRUD APIs is recommended but not required

The following content is sufficient to fulfill these prerequisites:

Covered topics

Lab steps

Connecting to the Go Development Environment
Implementing the Update Operation
Implementing the Delete Operation