Jesper L. Andersen

CS hacker, researcher, and investigator.


Erlang and code style

Musings on mostly defensive programming styles


Correct Erlang usage mandates you do not write any kind of defensive code. This is called intentional programming. You write code for the intentional control flow path which you expect the code to take. And you don’t write any code for the paths which you think are not possible. Furthermore, you…


Ranking 4 Million Quake Live duels in 1.5 seconds.

The last couple of days, I’ve been toying with a little hobby project of mine.

The project is to rank players which player Quake Live duels, and I have reported on it before. I’ve been gathering duels since February 2012 up to now. The project is written as a hybrid. Most of the code for storage, retrieval and…


ProgLang design with evidence

Let us assume the programming language market is effective and free. In this case, the best programming languages are the most popular ones: PHP, Javascript, Java, C#, C, C++ and so on. By definition, fringe languages can’t be the best languages. New fringe languages, like Go and Rust still has a chance in this world order, but long-time languages like Common…


Codes of Conduct

This is a plea. It seems we are stuck with So-called “Codes of Conduct” (CoC) in many projects now. So we better handle them with care, and I need a piece of text to refer to so I can give my stance toward them.

It seems CoCs stem from ancient times where they defined rules and responsibilities for parties, groups, or organizations. Some of these, like “The…


Mnesia and CAP

We start out with the TL;DR treatise: The mnesia database is not CP, nor AP. And it cannot be CA, because CA doesn’t make any meaningful sense. In short, it is broken with respect to the CAP theorem.

Note: Things get subtle once you begin digging into the intricacies of the CAP theorem. I am not a native speaker of English, though Danish is “dangerously close”…


QuickCheck Advice

Roberto Aloi has written a nice write-up about QuickCheck with a lot of good advice[0]. This is my attempt to add to those notes and come up with a set of additional advice you can use.

There is one problem I hear again and again with QC. Which is “How do I start on doing this for this particular project?” The premise is that you have an existing project…


Two technologies which are bad for you

For some odd reason, we end up in situations in this industry which looks even more grave than earlier. In this post, I am going to rant. I am going to rant on two things, which I think contributes negatively. I wanted to write a nice clean post, but rants sometimes fits ones mood better, I guess.

JSON


Erlang and code style

Musings on mostly defensive programming styles


Correct Erlang usage mandates you do not write any kind of defensive code. This is called intentional programming. You write code for the intentional control flow path which you expect the code to take. And you don’t write any code for the paths which you think are not possible. Furthermore, you…


Erlang String Handling

How to be efficient at handling string data in Erlang


The cat is out of the bag. Now, since WhatsApp had success using Erlang, more people will gravitate toward the platform. One of the common things that will happen as a result is that people who do not understand the string handling capabilities of the Erlang BEAM VM will fail to use it…


Error Kernels

What are they?


In any computer system, we can split the system into the part which must be correct—no matter what happens; and the part where we don’t need the system to be correct all the time.

A typical example of this is the operating system kernel. We believe the operating system kernel to be correct, but we don’t a priori trust the…


A MoonPig-like system

for Erlang

[Steven Wilson “The Raven that used to sing—and other stories”]