[erlang-questions] Trace-Driven Development
Mon Jun 4 12:07:16 CEST 2012
On 4 Jun 2012, at 09:52, Michael Turner wrote:
> So there's a classic distributed-systems paper that gives the
> technique its name, yet somehow, even though Kenneth Lundin agreed,
> all the way back in 2007, that seq_trace implements Lamport clocks
> this fact somehow hasn't made it into the documentation. Everybody has
> to rediscover it. This is not just a waste of their time, there's also
> the opportunity cost for Erlang/OTP (and Ericsson) in people *not*
> discovering it because it's not named as such at www.erlang.org.
First of all, I didn't dispute that seq_trace implements Lamport clocks,
only that the requirements for seq_trace had different origins. In a
similar fashion, one might claim that Erlang was inspired by Tony
Hoare's CSP, but that would be rewriting history, even though the pieces
mostly fit. There was a lot of work done on concurrency algorithms in the
'70s and '80s; the telecoms industry (and Ericsson) started designing
software-controlled phone switches in the '60s. It's very hard to untangle
after the fact who inspired whom (but it's certainly a fascinating excercise
- for one thing, Bjarne and co at one point visited Niklaus Wirth and came
to the conclusion that many of the things they had been working on were
manifest in his Modula-2… smart people working on the same type of
problems will sometimes independently arrive at very similar conclusions.)
My main reason for responding was that you accused the OTP team of being
"dishonest" in not mentioning where their ideas came from. I maintain that
they are not; only that many of the inputs that *actually* informed the
implementation were either confidential or proprietary enough to be of
no interest to the people reading the manuals.
A question is of course how many people are helped by the seq_trace
documentation mentioning the relation to Lamport clocks. Some might,
but others couldn't care less; they just want to know how to use the
functionality. We have had examples of OTP man pages in the past that
have gone into great detail about algorithm choices, resulting only in
terrifying anyone who came there just to learn how to use the API.
This is of course the big challenge when writing product manuals.
Many things that are of academic interest must be left out of the
manual if it ends up confusing the reader. In this case, I'm pretty sure
it could be worked in without harming readability, but it is of course
perfectly possible to use seq_trace without understanding, or even
being aware of the existence of, Lamport clocks.
The OTP team is known to accept patches to the documentation,
so please feel free to contribute to a more helpful way to describe
the tracing support. I'm sure it would be universally appreciated.
Ulf Wiger, Co-founder & Developer Advocate, Feuerlabs Inc.
More information about the erlang-questions