“Domain-Specific Lanugages” by Martin Fowler

Today, I finished reading the thick black book.. “Domain-Specific Languages” by Martin Fowler.

Here’s the (personal)mind map of the book.(click to magnify img. or here to see in “share”)

Recently, my colleagues are rapidly moving from Java to Ruby, first because they have found that Java + XML config of Web application was much more cumbersome that Ruby on Rails. And they naturally became big fans of Cucumber testing, Rake files, … and other Ruby DSLs(internal/external).

I’m finding that Ruby’s capability of meta-programming, flexible syntax, blocks(closures), and literal expressions have a great power to design internal DSLs. 20 years ago, I was a Unix-hand and a heavy user of yacc/lex tools to incorporate “my languages” into my application. So I have been feeling nostalgic about this movement, and wanted to update my knowledge to date.

That’s why I started reading the book, and to me, “Part I” is the part I should read and the other parts are for DSL designers. (Useful patterns, which reminded me of the “Dragon Book”.)

If I would choose one quote from the book, it would be about a Semantic Model and DSLs.;

All the DSL does is provide a readable way of populating that model – that is the difference from the command-query API I started with.

From the DSL’s point of view, I refer to this model as the “Semantic Model”(159)…

I advocate a Semantic Model because it provides a clear separation of concerns between parsing a language and the resulting semantics…

I put “DSL populates the Semantic Model” message and the diagram into the center of the mind map.

Among the four “why”s of DSL, I really liked “Communication with Domain Experts” aspect as an Agilista. One of my colleagues, @moro, has been developing “moro-miso” which works with Cucumber and helps use Japanese terms in the testing language.

(EDIT 5/6: “moro-miso” is now incorporated with “cucumer-rails”, thanks @moro)

Coincidentally I recently attended the DSM(Domain Specific Modeling) workshop at SPLASH 2010 which Steven Kelly at MetaEdit hosted and knew the concept of “language workbench”, so I learned a bit about other workbenches and added info to at the right bottom.

Also, InfoQ has some good articles about MD*, which I added at the left bottom.

I’m a developer of a modeling tool “Astah” (http://astah.change-vision.com) and exploring ways to incorporate the concept of DSL or to collaborate with DSL tools and workbenches.

Also a PDF version of the mindmap is available for printing in A3 or bigger paper -> DomainSpecificLanguagesByMartinFowler.pdf


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s