
The Go Workshop
By :

What we've seen hitherto is useful when building a website, even though, for this purpose, we still need to see how to better render HTML pages. You might want to use a framework such as revel or gin for this purpose, although plain Go with a few libraries is more than enough for a production-grade website. You will find, however, that HTTP servers are used not only for building websites, but also for building web services, and especially, nowadays, microservices. Although how to build a web service-based project is beyond the scope of this chapter and book, it is important for you to know how to let your HTTP server serve something that will not be consumed by a human through a browser, but by another program. You may already know what a web service is, but even if you do not, you might have to work on an existing project where you have to modify a web service. There are several ways to present a message to another program, which will be referred...