CA to WI via Motorcyle

Somehow this “project” never got a write up here. Near the end of September, my wife and I took a spectacular motorcycle ride from California to Wisconsin. Nearly two weeks of spectacular views and interesting places.

With the COVID-19 pandemic surging throughout the US again now, I imagine a few raised eyebrows after reading the previous paragraph. Wasn’t this dangerous, and didn’t we help to spread the disease?

No, we didn’t, and here’s why: we followed the very simple guidelines the CDC and other reputable authorities have been recommending for months.

We wore masks every time we went in a building. We stayed six feet or more from others. We washed our hands often, and carried hand sanitizer for when we couldn’t. We avoided large groups – in fact we even avoided small groups, skipping all the friends we could have visited along the way. We ate outside, most often in empty parks, or alone in our hotel room.

None of our hosts at either end of our journey have developed COVID-19 symptoms. At least one has even confirmed testing negative.

This isn’t hard. Listen to the experts, follow their guidance, and we’ll have this kicked.

Erlang Observations

To those who are considering Erlang and Erlyweb as a framework for their website: just go for it.

A couple of days ago, there was yet another blog post on Reddit about the scalability of Erlang, with the same yaws-owning-apache graph we’ve all seen before. There was absolutely nothing new in the entire post.

In my opinion, there are many reasons to use Erlang that have nothing to do with server performance.

Those of you who found BeerRiot through the Ask Reddit thread about Erlang usage already know that it’s built on Erlang and Erlyweb. My experience with them will be different than others’, of course, but I felt the need to list a few of my [completely subjective] observations about this framework.

So, in no specific order:

  • I like the syntax. I got past the comma-semicolon-full-stop confusion that many complain about within the first few hours of coding. It’s different, refreshing, and not too hard to understand.
  • Development cycles go really fast. More than once, I’ve hashed out some new functionality on my subway commute, then polished it at home and posted it the same evening. Part of this is the pattern matching used in function calls and branches – it translates almost directly from my pseudocode.
  • Some complain about the lack of hierarchy and types – I love it. It makes evening coding feel very free-form after eight hours of Java.
  • Erlyweb and Yaws are both very powerful and useful, yet their codebases are small enough that the thought of digging through their code does not intimidate me.
  • Erlang doesn’t have all of the libraries of other languages yet, but they’re not hard to get to.
  • Hot code loading and the ability to open a shell connected to your webserver doesn’t get enough press. I never stop my webserver unless I’m making a huge change that I’m too lazy to plan the transition for.
  • I dislike typing underscore. I do think it’s a good visual representation for “don’t care”, but I just don’t like to type it. I often use camelCase to define my own functions, but it looks a bit messy in mixed code.

So, yeah, some of these are reasons to use Erlang, some are reasons to use any language with similar features, some are just things to note. I just felt like there needed to be some conversation about Erlang other than its scalability.

If anyone has any specific questions about my experience with Erlang, please post them in the comments. I’ll either answer here or write another post to cover them all in a few days.