Go R1 Day 66
This wasn’t specific to Go, but was the first step towards using Go in a distributed test.
I had an interesting project today with my first development level effort using Kubernetes. Here’s my log of attempting to use Getting started with Dapr | Dapr Docs and getting two Go APIs to talk to each other with it.
First, what is Dapr?
Dapr is a portable, event-driven runtime that makes it easy for any developer to build resilient, stateless and stateful applications that run on the cloud and edge and embraces the diversity of languages and developer frameworks. 1 … Dapr codifies the best practices for building microservice applications into open, independent building blocks that enable you to build portable applications with the language and framework of your choice. Each building block is completely independent and you can use one, some, or all of them in your application.
From this, it sounds like Dapr helps solve issues by abstracting the “building blocks” away from the business logic. Rather than focusing on the implementation level concern of how to talk from service to service, Dapr can help with this.
Instead of relying on provider specific key-value store, such as AWS SSM Parameter store, Dapr abstracts that too.
It’s interesting as this concept of abstraction on a service level is something new to me. Good abstractions in software are hard but critical to maintainability long-term. Provider-level abstractions are something on an entirely different scale.
- Enable Kubernetes on Docker Desktop.
- Install Lens:
brew install lens
- Pop this open and
Cmd+,to get to settings.
- Add dapr helm charts:
- Connect to local single-node Kubernetes cluster and open the charts section in Lens.
- Install Dapr charts.
- Celebrate your master of all things Kubernetes.
I think I’ll achieve the next level when I don’t do this in Lens. I’ll have to eventually use some cli magic to deploy my changes via helm or level-up to Pulumi. 😀 Until then, I’ll count myself as victorious.
A Practical Test
- Install Dapr - Visual Studio Marketplace