In the previous post, we discussed the basics of caching in Go and implemented a simple in-memory cache that utilizes a RWMutex to protect concurrent access to the inner map. In this post, we will explore how to further improve the handling of concurrent access to the cache through the use of a concept called “sharding.”
|
In many cases, a fully featured external cache library is overkill, and for most use cases, writing your own implementation is a better option. You will understand how it works, and will be able to extend it to your needs. This post will cover the basics of implementing a cache in Go, and provide a working template for you to use.
|
I am an IBM Z Mainframe software and infrastructure engineer since 2018. I have experience in application development, application infrastructure, and mainframe infrastructure on IBM Z Mainframes.
I have a wide range of experience in the application infrastructure and mainframe infrastructure space. I have worked on customer facing applications, service account caching and handling applications, API development, external connectivity, and more.
Languages | Environments | Software & Tools |
---|---|---|
PL/I | z/OS | z/OS Connect |
REXX | IMS | CA-Librarian |
CLIST | CICS | Datavantage |
COBOL | DB2 | BMC Mainview |
Golang | Z/VM | Syncsort |
Python | USS | IBM File Manager |
Javascript | MVS | Fault Analzyer |
Easytrieve | TSO | |
ISPF |
I have many passions and hobbies that I keep cycling through.