You have a good source in the MEAP (Early Access) book
DSL in action from Debasish Ghosh (blog: "Ruminations of a programmer)
Testing frameworks like scalatest are classic examples of DSL:
test("pop is invoked on an empty stack") {
val emptyStack = new Stack[String]
evaluating { emptyStack.pop() } should produce [NoSuchElementException]
emptyStack should be ('empty)
}
There are many others DSL-based frameworks out there:
def songCountByArtistId: Query[GroupWithMeasures[Long,Long]] =
from(artists, songs)((a,s) =>
where(a.id === s.artistId)
groupBy(a.id)
compute(count)
)