Refreshed

As mentioned in the last post, the bones of this site are a little creaky. It's running on Rails 3.2.15, which came out in 2013, stuck on Ruby 2.1.5, which came out in 2014. It's spent the last eight years running on an m1.small instance in AWS, provisioned using Chef cookbooks that were neat when I wrote them in 2013, but haven't had a thing done to them since.

I didn't even have a good way to deploy an update to change the sidebar to show that I've spent the last six years working for Square and Cash App rather than public radio.

Definitely time for a refresh. I'd been messing around with using a Docker container to get my ancient Ruby running on this M1 iMac, so I decided to shoot for ECS (Elastic Container Service), using Amazon-provisioned database and Redis. — Continue Reading...

It's been a bit...

After thoroughly ignoring this site for the last six and a half years, I'm going to try to get back into a slightly better flow of posting something every now and again.

A lot has happened in between my last posts in 2015 and now. The kid who had just been born in this 2014 post is now seven and in first grade. He's got a brother, Brent, who is five. We've moved houses twice, and since early 2016 I've been working for Square, where I took a job to do Ruby code and somehow quickly ended up in payments. Turns out, it's a fun space, and six years later I'm still learning it as I help teams on Cash App's Financial Platform figure out how to move money around the world. — Continue Reading...

Policy Routing for Xfinity Traffic on a Dual-WAN Unifi Gateway

Since mid-2019 I've had redundant Internet connections here at the house, using AT&T Fiber as our primary link but keeping a Comcast connection active just in case of outages. For a long time it was just set up warm, where I would need to go down to the basement and switch a cable to switch links. Somewhere along the way a coworker pointed out that my Unifi Security Gateway (USG) supported Dual-WAN failover, and I plugged them both in.

That all works great, but there's been one nagging case I've wanted to clean up: We do use Comcast for television, and I like their Xfinity Stream app for listening to news while I'm getting ready in the morning. Because of using the AT&T Fiber link, though, the Xfinity app thinks I'm out-of-home, which limits my ability to watch in-progress recordings.

To fix that, I need to set the USG to route Xfinity traffic over the Comcast link, but leave other traffic doing its normal failover setup that prefers AT&T. That's not an especially hard ask, but it's been sitting on the todo list for a while.

When we moved in mid-2019 I turned on Comcast internet because it was the quickest to get going, but then quickly moved to using AT&T Fiber for our primary connection. I kept the Comcast internet active, though, because in this day and age redundant Internet connections seems — Continue Reading...

Computing Podcast Stats with Elasticsearch

KPCC Podcast Stats Flow Eric Richardson / KPCC

Since rejoining KPCC last fall, I've spent a good bit of time on the topics of metrics and analytics. There's a very healthy ecosystem of options for monitoring the traffic to your website or the health of your servers, but as a radio station we end up with a lot of questions around how our audio is getting consumed that don't always fit in those same tools.

Podcasts are the hot topic in the audio world right now, but they present a big challenge for those of us trying to make sense out of the numbers. Some of that challenge is intractable right now—podcast clients simply don't give us any information about when a downloaded file is played—but some of it is just about putting a better wrapper around old-school download stats.

At KPCC we're using two free tools—Logstash and Elasticsearch—to make it much quicker and easier to keep track of podcast downloads. — Continue Reading...

Back to Work: Looking Beyond the Play Button

I've been back at KPCC for about four months now, and it's been a trip to drop back into code and ideas that I had left behind in 2012 when we headed east to Atlanta. There have definitely been times where I've wished code that I wrote back then wasn't still around to greet me, but on the whole it's been great to get to pick up the process of thinking about how radio works in the digital age.

Today some of that thinking actually gets into the hands of users. We just pushed a completely-rewritten version of KPCC's iPhone app that lets you rewind to the start of the currently-live program regardless of when you start listening. — Continue Reading...