Since OTP 25, Erlang has included a function maps:groups_from_list/2 and I had occasion to use it recently. In KAZOO , we have a process that monitors other processes, keeping track of their message queue length, heap size, etc (we're on OTP 26 at the moment so need to do this manually). I wanted to print a table of the tracked processes, ordered first by message queue length, but within the…
Reversing binaries in Erlang In KAZOO , we have a kz_binary module that performs various functions over binary() data (typically string-ish stuff). Most of this code came before the string module was introduced in OTP 20 (for those that may not be aware, KAZOO started on R15B03 in 2010). Recently we encountered an issue in a production cluster where a large blob of JSON was being processed and…
It seems like most kids in the late 80s / early 90s played BOMBER on the Apple 2e. The basic premise of the game was answering basic multiplication questions to earn more bombs, fuel, rounds, and stealth mode. You then got to control a plane (side-scrolling) as it flew along the mission route. Enemy pilots will try to shoot you while you have to bomb specific targets without being hit and before…
AoC 2020 Day 1 Day 1 of the Advent of Code brings us a search problem - find two entries whose sum is 2020 and answer with the product. Reading the input file I like to get the data in from the file and into a workable internal format. For this problem its pretty simple - a list of integers will suffice. read_input ( File ) -> { 'ok' , Lines } = file : read_file ( File ), [ binary_to_integer (…
I'll be participating, slowly, in the Advent Of Code and writing about how I used Erlang to solve the problems. The goal of the code is, hopefully, to be easy to read and reason about. Not-goals include being the shortest, fastest, or "cleverest". Nothing about the code is "best"; it will represent whatever chunk of time I'm able to offer it. Subsequent posts will cover a particular day's two-part…
From an AP US History Teacher: If you are confused as to why so many Americans are defending the confederate flag, monuments, and statues right now, I put together a quick Q&A, with questions from a hypothetical person with misconceptions and answers from my perspective as an AP U.S. History Teacher: Q: What did the Confederacy stand for? A: Rather than interpreting, let's go directly to the words…
With the transition to working from home in full swing, let's look at the ways KAZOO makes it easy to bring your office with you! From Scratch Let's say you are a solo business owner who needs to forward your business phone calls to your personal mobile phone. Assuming the business phone number is provisioned for the account already, here's the basic steps to set that up! Setup the callflow A…
Recently learned that I was accepted to Github's beta sponsorship program which allows me to define sponsorship tiers! https://github.com/sponsors/jamesaimonetti My hope is that folks that have appreciated my work with KAZOO and help in the forums, documentation, and IRC, might throw a bone or two of thanks my way. If there's a better tier that would get you on board, let me know.
At work, we've been coerced for a few years now to use Slack. At first it wasn't too bad; Slack provided an IRC gateway so irssi remained viable. Then in 2018 they shut down the gateways in the name of "security". Enter emacs-slack ! As part of my personal initiative to move more of my computing life into Emacs, the IRC gateway closure actually provided me the necessary kick in the pants to move…