In this workshop you will build a simple voting service that exposes a RESTful API with a single /votes
resource that supports two methods:
You will use the following simplified model of a vote:
// Vote represents one voter casting one vote in one poll.
// A single voter can only vote once for any given poll.
type Vote struct {
Voter string `json:"voter"`
Poll string `json:"topic"`
Choice string `json:"choice"`
}
First you will write a simple version of the service to learn the basics of the event-driven architecture event cycle. Once you understand the basics, you will improve the service by adding in more realistic functionality, including: