Mutability Considered Harmful

(psteitz.blogspot.com)

1 points | by psteitz 7 hours ago ago

2 comments

  • joshsegall 5 hours ago

    I think systems end up mutable not because anyone chose it but because their tools make mutation the path of least resistance. Kafka succeeded not because "immutable logs are better" was a new idea but because it made the immutable approach easier than the spaghetti alternative.

    The mutability in these examples is almost entirely accidental complexity. The state changes are necessary for real world applications, but representing them as in-place mutation is a choice the tooling made for you.

  • fuzzfactor 2 hours ago

    From a bird's-eye view you can point to Google when it first appeared.

    The thing that made it instantly popular was that there were no ads.

    Searches themselves were more thorough than established providers, but also outstanding was the way that search results from the same search string were identical no matter what computer you searched from.

    If you were looking for authoritative information, the best result would usually have risen to stay at the top for an extended period of time too.

    And it only got better from there.

    Until one day it didn't, it reversed.

    Losing that type of immutability was one of the saddest developments at places like Google from which it's just a slippery slope on down from there.