||[Jun. 10th, 2010|03:18 pm]
Shlomif's Technical Posts Community
Joel Spolsky had written an essay titled
Law of Leaky Abstractions" where he discusses the fact that sometimes
one needs to be aware of details of the abstraction's implementation to know
how to properly make use of it. Today, I'd like to talk about an analogous
phenomenon which I came to call a "quirky" abstraction, in which
an abstraction over several technologies (probably two or more) fails to
expose certain features in one of the technologies that it abstracts.
I first noticed this concept in
Stack Overflow question of how to encrypt/decrtypt an SQLite database from
within Qt. Now, the Qt SQLite backend module links against the vanilla
SQLite and not its encrypted implementations, so in order to make use of them
one will have to recompile Qt and possibly expose some extra functionality in
At the moment, I've also volunteered to help maintain
CPAN module and the reason was that one of the features of GraphViz was
not exposed in its Graph-Easy backend, which brought the need to hack
something as a workaround.
Can quirky abstractions be avoided? I don't know. As the abstraced
technologies progress and gain more features, the abstraction
needs to keep up with them, which makes a situation of a quirky abstraction
more likely to occur.
I'm not sure quirky abstractions are as bad as leaky abstractions, but it's
still an phenomenon that we need to be aware of.