I’ll start with the punch line. RavenDB just rocked my world. Two things stick out:
- It combines a database with an ORM – It’s as if Ayende said “I’m tired of working on the whole ORM thing. They only exist because SQL databases aren’t solving the right problems. Let’s just combine SQL and the ORM and simplify everybody’s life.”
- It’s extremely approachable, even for non-database guys – It took me less than 30 minutes to get up and running.
How did I jump to those conclusions?
I have a confession to make. I’m not a database guy. In fact, when I’m prototyping, I tend to go to great lengths to avoid using databases. Sometimes, these workarounds are sane. Using a disk based key/value store isn’t so bad. Tonight, however, I was going down an insane path.
Our blog content is created in a CMS built by our colleagues at Newsvine. All of our other content is in our custom CMS (named Workbench). As you might expect, our editors don’t care which CMS their content is in. They just want to use their content however they wish.
Tonight, I prototyped a process that consumes blog feeds from Newsvine and creates stubs in Workbench for each blog post. In Workbench lingo, these stubs are called “teases.” So far so good.
It started to get more interesting I wanted to make sure that:
- I didn’t create more than one tease for each blog post
- When blog posts are updated, the teases are updated
I’m guessing the average developer would create a link table in a database to maintain a mapping between the two systems. Not me. Instead I charged down a path of great difficulty. In a nutshell, I relied upon a very fragile folder path and naming convention in Workbench to infer a mapping between Workbench and Newsvine. My approach was fraught with peril since:
- Humans can change the names and folders of things (and they do!)
- There was really no way for me to track changes to posts and appropriately update the teases
Raven to the rescue
Ninety minutes into the madness, I decided to give Raven a whirl (a couple of other folks here have been doing some really great stuff with it). Within 30 minutes, my stuff was working. Most impressive (not me, Raven). For the truly interested, here’s the Raven stuff from my prototype. It was incredibly easy.