Domain Modeling For Dummies

by

Domain Modeling, at least to me, sounds complicated. It sounds like something you should have an advanced degree to do, and something that, if you do understand the term at face value, marks you as an Expert. At something. And while there are a lot of valuable domain modeling tools that help developers make useful applications, it can be an off-putting term. It took me a while to understand that ‘Domain Modeling’ can be boiled down to:

“Explain this little world of yours”

or

“This thing you’re describing: What’s it like? How does it work? What makes it special?”

The first time I wrote the stickies project, I created the following resources: Users, Stickies, Projects. It was remarkably simple. There was also the concept of Groups (a cluster of related stickies); and a Dock (a place to move those groups out of the way). Beyond that, though — go get a hamburger, we’re done. We’ve got users, the people using the application; stickies, those little sticky notes; and projects, well…

Wait.

I’d chosen “Project” without thinking about it too much. Having projects and thinking about new ways to keep track of projects is one of our favorite occupations as web developers (and people) these days. Plus, it’s a status symbol. Have a lot of projects! Yum, projects. Yum, to-dos. Yum, airport-bookstore-manage-your-life books.

Yum.

However, had I been on the Domain Modeling ball, I would have seen that when I sat down and stuck stickies to the floor, table, or wall, it had more to do with cataloging a tumbleweed of thoughts and feelings, creating clustered relationships and visualizing a brain dump than doing project related tasks such as creating milestones, to-dos and deliverables. Well, I actually did know that, but I would have also said…

Hey, wait! While there’s nothing stopping a user from using stickies to flesh out a particular, extant project or to start a new one — hell, the stickies project even hooks into the Basecamp API because somewhere on your living room rug you might find the seed of a project and want to manage it — project management is not where the impulse to stick originates.

What I had been calling a Project was really… a big, open, preferably flat, preferably indoor, often private, always dry… surface.

And so we changed “Projects” to “Surfaces”.

Big deal, right? While it may seem like a minor name change that affects a few files, getting the domain name right can have a small, then bigger, then biggest-of-all effect on the design and world of your application. It’s similar to character development as a writer or a director: observe and listen to your subject until you find their unique twitch, their particular motivation. Finding this can drive their purpose, save them from cliche, and make them real to the audience.

While steering clear of cliche is an ongoing task, clarifying the “surfaces” domain has led us to some organic ideas for the design. Ideas that we hope will enrich the application. Getting closer to the “real world” of sticking will allow us to create a more specific “web world” of stickies.

This experience has helped me to recast “Domain Modeling” in my mind to simpler things, such as listening to your environment, paying attention to what you or your clients are actually doing, and steering clear of the default classification buckets in our minds. Use all the tools you have handy and feel comfortable with, but remember that getting the domain right starts before the tools come out: it’s more of a paying attention kind of thing.

In the theater, actors are encouraged not act out an emotion, but to try to achieve a specific objective. Who wants to watch someone “act sad”? A similar directive for us as application developers would be to look out for general types of things we think we understand (such as “projects”) and instead focus on the little, simple, tasks we are actually trying to represent. You might find that everything changes shape.

Find the twitch: that unique and domain-centric something that needs to be expressed, and then delve deep.

Advertisement

5 Responses to “Domain Modeling For Dummies”

  1. James Martin Says:

    If you have the time, the book ‘Domain Driven Development’, by Eric Evans is an excellent read. What you’ve described in this post is what Evans calls defining an “ubiquitous language”, which is specific to your domain and is used both in conversations with the project stake holders (just yourself and Corey, right now) and throughout your code.

    As well as helping to guide you in designing the system in the context of the domain, an ubiquitous language also helps to align the understanding of that domain, the model you’re building with your software, the people building and maintaining the code and the people who will use the end product.

    When the rest of us start to get a look at the software, we should also be able to see the influence of the ubiquitous language throughout the design. I’m looking forward to seeing a version we can play with!

    Keep up the good work!

  2. Sarah Gray Says:

    James, thanks for pointing that out. I will check out that book. We’ve just picked up stickies after a couple months of holidays and other distractions (such as a volcano-induced extended vacation in paradise), but we’re aiming to start opening up tsp for folks to get a look at sometime in the next few weeks or early April. We’ll keep you posted.

  3. Claimed and Unclaimed Surfaces « The Stickies Project Says:

    [...] The Stickies Project All stickies, all the time « Domain Modeling For Dummies [...]

  4. Moving Patterns « The Stickies Project Says:

    [...] of the stickies on the stage (which we are now referring to as a ’surface’, see my previous post on naming). When this method completed, the groups were configured. This way when a sticky was dragged it [...]

  5. Simple Design starts from the outside in « The Stickies Project Says:

    [...] while ago. A major and important decision is what the URL should be for these surfaces (Sarah wrote a post on our choice of domain). The natural first thought would be /surfaces, since it seems like a natural root [...]

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 )

Connecting to %s


Follow

Get every new post delivered to your Inbox.