I’ve recently gone through and separated a (admittedly small) system into several different services, so wanted discuss the different boundaries I’ve defined, the reasoning behind them, and the trade offs. What are we Building? This is a webapp similar to Pinterest. Users will create Galleries of images with tags, comments, and ratings for the images. […]
Tag: code
Write Bad Code
Today, I lit a bushel of money on fire. We still measure money in bushels, right? As I was implementing the handler for my UpdateItemsCommand, I noticed we were potentially doing a lot of insertions. My perfectionism fired up, and I got to work on an “insertMany” method for an array. I spent some time […]
Designing Good Commands
Working with an event-driven architecture, I got stuck wondering how best to structure my Commands, and would love to steal your ideas hear what you think. In this web-app, very much like Pintrest, users create and manage “Galleries” of “GalleryItems”. A “GalleryItem” is just an image with a title, description, and tags. Users can reorder […]
ZenLog
Sometimes, trace is not enough. When I started working with Haxe, I wasn’t completely satisfied with any of the logging libraries, so of course I made my own. Problem The existing package that most resonated with me was LogShim, but it had one critical issue for me: The selling point of Haxe is that you […]
API First
Recently I was writing a small package for data validation (specifically for a web-form). My first attempt was pretty bad, so I want to take a minute to reflect on why that was my first instinct and how not to make those same mistakes again. My first approach was to build a generic Validator object. […]
Econia #1: Clicking Like a Champ
Sometimes simply clicking something isn’t enough. Sometimes you need to click, double click, or click + hold! Here’s what we implemented when working on Econia. Link to the full source at the bottom. Generally, once a click begins we start a timer to check if the player holds for long enough (in which case he is “click + hold”-ing) […]