Hacker News new | past | comments | ask | show | jobs | submit login

This is such a great quote, and helps explain what is a good abstraction.

Because CRDTs have been in the zeitgeist a lot lately, I want to pick them as an example of a "good" abstraction.

CRDTs have mathematical properties which can be described and understood independently of a specific implementation. And importantly, you can judge whether an implementation is correct with reference to these abstract rules.

This means that when using a CRDT, you largely can treat it as a reliably-solved problem. Once you understand the concepts, and work out how to use the library you've picked, you don't have to think about the details. Though that doesn't mean sometimes the behaviour can be surprising:

https://www.moment.dev/blog/lies-i-was-told-pt-1

TCP and HTTP are great examples too, though interestingly I don't know if they rely on mathematical definitions so much as just being extremely widespread to the point that reliable implementations are available anywhere you care to write code.

I like this article which also leans on the Dijkstra quote:

https://www.pathsensitive.com/2022/03/abstraction-not-what-y...






CRDTs are also an excellent example because of how their supporting infrastructure is impacted by their design, namely that Postgres’ method of dealing with updates makes for massive write amplification.

I wrote this [0] previously, but it still applies. IMO, as a dev, there are times where you really do need to think somewhat deeply about infrastructure choices. Unfortunately, knowing when you need to care practically requires you to already understand it.

[0]: https://news.ycombinator.com/item?id=40834759




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: