Introducing RavenDB: NoSQL for .Net

RavenDB is a very powerful and capable database that let you store documents. Over the next few weeks I will present you what I like so much about RavenDB, how you can use it and how NoSQL can change the way you think about the persistence layer.

This post is part of the RavenDB series. You can find the other parts here:

 

What is NoSQL?

As so many terms “NoSQL” has a lot of meanings. For some it stands for “No SQL” and is used whenever they want to describe a persistence System that is not a relational database. Others like myself look at saving data from the polyglot persistence angle and prefer the meaning “Not only SQL”.

What everyone agrees on is that the problems we have to solve today are not always a good fit for relational databases like Oracle or MS SQL Server. Those problems not only rise at companies like Twitter or Google. Even when you play around with a new web technology framework you feel the friction when you have to build a schema to store your data.

There are many different types of NoSQL databases. There are key–value stores like Riak, object databases like Db4o, graph databases like Neo4j and many more.
RavenDB is a Document Database who as the name implies stores all the data as documents. But be aware that those documents are not like Word documents, they are JSON objects who look like this one:

 

Why RavenDB?

In the last 5 years I used mostly C# and the .Net Framework to develop applications. With that .Net centric background RavenDB is a natural fit. To query the database you can use LINQ (and not JavaScript). The .Net Client works great, the database itself runs on Windows and when you want to use AngularJS you have a HTTP API as well.

RavenDB calls itself a 2nd generation document database. There are many helpful optimisations and features (like transactions) that ease the transition to NoSQL. Oren Eini, the creator of RavenDB, is a well-known expert in the .Net world. His NHProfiler (for NHibernate) and EFProfiler (for Entity Framework) where a great help to me whenever I had to fix performance problems with those OR-Mappers. To prevent the same performance problems in RavenDB Oren put a lot of work in the detection and prevention of the most common errors. This is so fine-tuned that it will work with the few entries you normally have on a development machine.

Even if you don’t want to use the .Net parts you should check out RavenDB. It is open-source and licensed under the GNU Affero General Public License. Don’t panic, if you have proprietary software you can (or better must) buy the commercial licence.

 

Next

In the next post we will install RavenDB on our development machine and then play around with the sample database.

7 thoughts on “Introducing RavenDB: NoSQL for .Net”

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.