All publications

Magazine · 2014

On domain-specific languages usage (why DSLs really matter)

Vassilios Karakoidas

A column arguing that the standard claims for domain-specific languages were repeated more often than they were measured, and reporting an experiment that measured one of them: how widely DSLs are actually used in Java.

Published in
XRDS: Crossroads, The ACM Magazine for Students, Vol. 20, No. 3, pp. 16--17, 2014
Citations
3 on Google Scholar, read 5 September 2026 — 25 of 30 by count
Cite as
KARA14

The idea

Research papers on DSLs tended to open by asserting that DSLs are useful and increase productivity. The claims seemed reasonable, and were treated rather like urban legends — everyone knows they are true, nobody quite proves them. The column takes one claim that can be measured — that DSLs are genuinely in everyday use — and measures it.

The experiment

  • A January 2012 snapshot of the Maven repository, filtered to the most recent version of each project: 12,959 projects and more than 110 million lines of code.
  • DSL use detected by scanning Java source for the import statements of the standard libraries that implement a DSL — java.util.regex for regular expressions, and so on. A project using four such libraries counts as using four DSLs.
  • Only Java source was scanned. Build files, which are themselves DSLs, were deliberately left out, as was any library beyond the set that was identified.

What it found

More than a third of the projects — 4,655 of them — use at least one DSL. XML leads at 75% of the projects that use any, regular expressions follow at 25%, and the popular combinations are XML with regular expressions and SQL. The column is explicit that the experiment is not exhaustive and that a wider net would push the numbers up, not down.

Where it sits

The experiment works over the same January 2012 Maven snapshot as Generating the Blueprints of the Java Ecosystem — filtered differently, so the project counts are not the same figure — and what it establishes is the motivation for the thesis. The piece is also on this site as a post — On Domain-Specific Language Usage.

Written from the author's own full text of the piece, republished on this site as a blog post; the XRDS version is behind the DOI above.