RavenDB

{{Short description|NoSQL document-oriented database}}

{{Infobox software

| name = RavenDB

| logo =

| logo size = 250px

| screenshot =

| caption =

| author = Oren Eini (aka Ayende Rahien)

| developer = Hibernating Rhinos

| released = {{Start date and age|2010}}

| latest release version = 6.2

| latest release date = {{start date and age|2024|10||df=yes}}

| programming language = C#

| engine = Voron

| operating system = Windows, Linux, Mac OS, Docker and Raspberry Pi

| language = English

| genre = Document-oriented database

| license = AGPLv3

| website = {{URL|https://ravendb.net/}}
{{URL|https://hibernatingrhinos.com/}}

}}

RavenDB is an open-source document-oriented database written in C#, developed by Hibernating Rhinos Ltd.{{Cite web |title=RavenDB |url=https://dbdb.io/2db/ravendb |date= |website=Database of Databases |language=en |access-date=10 October 2020 }}{{Dead link|date=March 2023 |bot=InternetArchiveBot |fix-attempted=yes }}{{Cite web |title=Raven, a Document Database for .NET |url=https://www.infoq.com/news/2010/05/Raven/ |date=2010 |website=www.infoq.com |language=en |access-date=10 October 2020}}{{Cite web |title=Other Vendors to Consider for Operational DBMSs |url=https://www.gartner.com/en/documents/3892294/other-vendors-to-consider-for-operational-dbmss |date=2018 |website=www.gartner.com |language=en |access-date=10 October 2020}}{{Cite web |title=Hibernating Rhinos |url=https://hibernatingrhinos.com/ |date= |website=hibernatingrhinos.com |language=en |access-date=10 October 2020}}Kaur, Harpreet, and Kamal Jeet Kaur. "A Review: Study of Document oriented databases and their Security." International Journal of Advanced Research in Computer Science 4.8 (2013). It is cross-platform, supported on Windows, Linux, and Mac OS.{{Cite web |last=Wallen |first=Jack |date=2021-01-06 |title=How to create a new database with RavenDB |url=https://www.techrepublic.com/article/how-to-create-a-new-database-with-ravendb/ |access-date=2022-11-22 |website=TechRepublic |language=en-US}} RavenDB stores data as JSON documents and can be deployed in distributed clusters with master-master replication.

History

Originally named "Rhino DivanDB",{{Cite web |title=Ayende's DivanDB (also, is ESENT the most widely used database engine?) |url=https://blogs.msdn.microsoft.com/laurionb/2008/12/23/ayendes-divandb-also-is-esent-the-most-widely-used-database-engine/ |date=2008 |website=blogs.msdn.microsoft.com |language=en |access-date=10 October 2020}} RavenDB began in 2008 as a project by Oren Eini (aka Ayende Rahien){{Cite web |title=Interview with Oren Eini of RavenDB on database management, analytics & security |url=https://bigdata-madesimple.com/interview-with-oren-eini-of-ravendb-on-database-management-analytics-security/ |date=2019 |website=bigdata-madesimple.com |language=en |access-date=10 October 2020 |archive-date=8 October 2020 |archive-url=https://web.archive.org/web/20201008141436/https://bigdata-madesimple.com/interview-with-oren-eini-of-ravendb-on-database-management-analytics-security/ |url-status=dead }} and is developed by Hibernating Rhinos Ltd. The company claims it was the first document database to run natively in the .NET Framework.{{Cite web |title=RavenDB Development: Finally, A Solid Document-based Database for Windows? |url=https://www.whoishostingthis.com/resources/ravendb/ |date=2019 |website=www.whoishostingthis.com |language=en |access-date=10 October 2020 |archive-date=8 October 2020 |archive-url=https://web.archive.org/web/20201008090120/https://www.whoishostingthis.com/resources/ravendb/ |url-status=dead }}{{Cite web |title=NoSQL Document Database - Embedding RavenDB into an ASP.NET MVC 3 Application |url=https://docs.microsoft.com/en-us/archive/msdn-magazine/2011/november/nosql-document-database-embedding-ravendb-into-an-asp-net-mvc-3-application |date=2011 |website=docs.microsoft.com |language=en |access-date=10 October 2020}}{{Cite web |title=Why Raven DB? |url=https://dzone.com/articles/why-raven-db |date=2010 |website=dzone.com |language=en |access-date=10 October 2020}} It was an early document database to offer ACID guarantees.{{Cite web |title=RavenDB vs SQL Server |url=https://www.integrace.nl/nl/News/307/RavenDB |date= |website=www.integrace.nl |language=nl |access-date=10 October 2020}}

In 2019, Hibernating Rhinos began offering RavenDB as a cloud service named RavenDB Cloud.

Version history

class="wikitable sortable"

! Version

! Date

! Features added (partial list)

{{No2}}1.0

| May 2010{{Cite web |title=RavenDB goes live! |url=https://ayende.com/blog/4507/ravendb-goes-live |date=2010 |website=ayende.com |language=en |access-date=10 October 2020}}

|

{{No2}}2.0

| January 2013{{Cite web |title=RavenDB 2.0 RTM |url=https://ayende.com/blog/160642/ravendb-2-0-rtm |date=2013 |website=ayende.com |language=en |access-date=10 October 2020}}

| Replication{{Cite web |title=RavenDB: A document database for the .NET platform |url=https://learning.oreilly.com/library/view/ravendb-2x-beginners/9781783283798/ch01s04.html |date= |website=learning.oreilly.com |language=en |access-date=10 October 2020 }}{{Dead link|date=March 2023 |bot=InternetArchiveBot |fix-attempted=yes }}{{Cite web |title=RavenDB: A document database for the .NET platform |url=https://learning.oreilly.com/library/view/ravendb-high-performance/9781782166986/ch01s05.html |date= |website=learning.oreilly.com |language=en |access-date=10 October 2020 |archive-date=2 November 2020 |archive-url=https://web.archive.org/web/20201102211752/https://www.oreilly.com/library/view/ravendb-high-performance/9781782166986/ch01s05.html |url-status=dead }}

{{No2}}2.5

| June 2013{{Cite web |title=RavenDB 2.5 Release Candidate is out |url=https://ayende.com/blog/162498/ravendb-2-5-release-candidate-is-out |date=2013 |website=ayende.com |language=en |access-date=10 October 2020}}

| Projections; facet querying

{{No2}}3.0

| November 2014{{Cite web |title=RavenDB 3.0 RTM! |url=https://ayende.com/blog/169313/ravendb-3-0-rtm |date=2014 |website=ayende.com |language=en |access-date=10 October 2020}}

| Java API; Voron storage engine{{Cite web |title=NoSQL for .NET: RavenDB 3.0 Takes Flight |url=https://visualstudiomagazine.com/articles/2014/12/02/ravendb-3-for-dotnet.aspx |date=2014 |website=visualstudiomagazine.com |language=en |access-date=10 October 2020}}{{Cite web |title=NoSQL: RavenDB 3.0 erhält weitere Storage Engine |url=https://www.heise.de/developer/meldung/NoSQL-RavenDB-3-0-erhaelt-weitere-Storage-Engine-2480210.html |date= |website=www.heise.de |language=en |access-date=10 October 2020}}

{{No2}}3.5

| October 2016{{Cite web |title=RavenDB 3.5 RTM released |url=https://ayende.com/blog/175937/ravendb-3-5-rtm-released |date=2016 |website=ayende.com |language=en |access-date=10 October 2020}}

| Clustering

{{No2}}4.0

| February 2018{{Cite web |title=RavenDB 4.0 is out |url=https://ayende.com/blog/181857-A/ravendb-4-0-is-out |date=2018 |website=ayende.com |language=en |access-date=10 October 2020}}

| Became cross-platform; available with a free license{{Cite web |title=NoSQL: RavenDB 4.0 jetzt für Windows, Linux, macOS und Docker verfügbar |url=https://www.heise.de/developer/meldung/NoSQL-RavenDB-4-0-jetzt-fuer-Windows-Linux-macOS-und-Docker-verfuegbar-3971913.html |date=2018 |website=www.heise.de |language=en |access-date=10 October 2020}}

{{No2}}4.1

| August 2018{{Cite web |title=RavenDB 4.1 Release Candidate is out |url=https://ayende.com/blog/184194-A/ravendb-4-1-release-candidate-is-out |date=2018 |website=ayende.com |language=en |access-date=10 October 2020}}

| Cluster-wide transactions{{Cite web |title=RavenDB Launches Managed Cloud Service |url=https://www.datanami.com/2019/07/02/ravendb-launches-managed-cloud-service/ |date=2019 |website=www.datanami.com |language=en |access-date=10 October 2020}}

{{Yes2}}4.2

| May 2019{{Cite web |title=RavenDB 4.2 has been released! |url=https://ayende.com/blog/187361-A/ravendb-4-2-has-been-released |date=2019 |website=ayende.com |language=en |access-date=10 October 2020}}

| Graph querying

{{No2}}5.0

| July 2020{{Cite web |title=RavenDB 5.0 has been released! |url=https://ravendb.net/articles/ravendb-5-0-has-been-released |date=2020-07-24 |website=ravendb.net |language=en |access-date=10 October 2020}}

| Time series;{{Cite web |title=RavenDB Adds Time Series Query Support |url=https://www.i-programmer.info/news/84-database/13846-ravendb-adds-time-series-query-support.html |date=16 July 2020 |website=i-programmer.info |language=en |access-date=10 October 2020}} Data compression using the Zstd algorithm{{Cite web |title=RavenDB 5 Improves Distributed Time-Series, Document Compression, and Indexing |url=https://www.infoq.com/news/2020/08/ravendb-5-release-document-db/ |date=Aug 3, 2020 |website=infoq.com |language=en |access-date=10 October 2020}}

{{No2}}5.1

| November 2020

| Indexing attachments; Hub/Sink replication with filtering

{{Yes2}}5.2

| June 2021

| OLAP ETL; Custom Analyzers

{{Yes2}}5.3

| November 2021

| Concurrent Data Subscriptions; Microsoft Power BI support

  • Red: Not supported
  • Green: Supported

= System architecture =

Data is stored as schemaless documents in JSON format.{{Cite web |title=A document database for the .NET platform |url=https://learning.oreilly.com/library/view/ravendb-high-performance/9781782166986/ch01s05.html |date= |website=learning.oreilly.com |language=en |access-date=10 October 2020 |archive-date=2 November 2020 |archive-url=https://web.archive.org/web/20201102211752/https://www.oreilly.com/library/view/ravendb-high-performance/9781782166986/ch01s05.html |url-status=dead }} Documents are grouped into collections, with each document having exactly one collection.{{Cite web |title=The Design of RavenDB 4.0: The Implications of the Blittable Format |url=https://dzone.com/articles/the-design-of-ravendb-40-the-implications-of-the-b |date=2016 |website=dzone.com |language=en |access-date=10 October 2020}}

Databases can be deployed on a distributed cluster of servers (called ‘nodes’) using multi-master replication.{{Cite web |title=RavenDB System Properties |url=https://db-engines.com/en/system/RavenDB |date= |website=db-engines.com |language=en |access-date=10 October 2020}} Some operations at the cluster level require a consensus of a majority of nodes; consensus is determined using an implementation of the Raft algorithm called Rachis. Tasks are distributed to the different nodes in a balanced way.{{Cite web |title=Review: NoSQL database RavenDB |url=http://techgenix.com/review-nosql-database-ravendb/ |date=2019 |website=techgenix.com |language=en |access-date=10 October 2020}}

Versions 1.0 through 3.5 supported sharding, but versions 4.x do not.

RavenDB originally used the ESENT storage engine.{{Cite web |title=Hidden Windows Gems: Extensible Storage Engine |url=https://ayende.com/blog/3769/hidden-windows-gems-extensible-storage-engine |date=2008 |website=ayende.com |language=en |access-date=10 October 2020}} Version 3.0 replaced it with a new open-source storage engine called Voron.

Clients are supported for C#, C++, Java, NodeJS, Python, Ruby, and Go.

Main features

  • Cluster-wide ACID Transactions - ACID transactions can be executed at the scope of a cluster (in addition to single node transactions). The transaction will only be persisted if it is confirmed by a consensus of nodes; if it is not, the transaction is cancelled and rolled back.
  • Distributed counters{{Cite web |title=RavenDB Adds Graph Queries |url=https://www.datanami.com/2019/05/15/ravendb-adds-graph-queries/ |date=2019 |website=www.datanami.com |language=en |access-date=10 October 2020}}{{Cite web |title=SD Times news digest: New Relic One, WhiteSource for Developers, RavenDB4.2, and VMware's acquisition of Bitnami |url=https://sdtimes.com/softwaredev/sd-times-news-digest-new-relic-one-whitesource-for-developers-ravendb4-2-and-vmware-acquisition-of-bitnami/ |date=2019 |website=sdtimes.com |language=en |access-date=10 October 2020}}

= Indexes and querying =

Queries are expressed in LINQ or with a custom query language named RQL (stands for Raven Query Language) with syntax similar to SQL.

  • Dynamic indexes - in RavenDB is that queries can only be satisfied by an index; if no appropriate index exists, a new index is created to satisfy the query.{{Cite web |title=RavenDB: Driving DX through DB infrastructure management |url=https://ciostory.com/technology/ravendb-driving-dx-through-db-infrastructure-management/ |date= |website=ciostory.com |language=en |access-date=10 October 2020 |archive-date=11 October 2020 |archive-url=https://web.archive.org/web/20201011205901/https://ciostory.com/technology/ravendb-driving-dx-through-db-infrastructure-management/ |url-status=dead }}
  • Graph querying - related documents can be treated as vertices in a graph, with the connections treated as edges. This makes it possible to create recursive queries.{{Cite web |title=RavenDB Features |url=https://ravendb.net/features/querying/graph-api |date= |website=ravendb.net |language=en |access-date=10 October 2020}}
  • Projection - indexes can be configured to transform indexed data, perform calculations, perform aggregations, and execute JavaScript code on the server side.{{Cite web |title=Data Modeling with Indexes in RavenDB |url=https://www.codeproject.com/Articles/1348454/Data-Modeling-with-Indexes-in-RavenDB |date=2019 |website=www.codeproject.com |language=en |access-date=10 October 2020}}
  • Full-text search - at a low level, data is indexed with Lucene.net, which means indexes support full-text search.Stevic, Milorad P. "Managing documents with NoSQL in service oriented architecture." Online Journal of Applied Knowledge Management (OJAKM) 1.2 (2013): 105-115.{{Cite web |title=Data Points - What the Heck Are Document Databases? |url=https://docs.microsoft.com/en-us/archive/msdn-magazine/2011/november/data-points-what-the-heck-are-document-databases |date=2011 |website=docs.microsoft.com |language=en |access-date=10 October 2020}}

Document extensions

Documents can be extended with other data types less suited to JSON. These extensions can be loaded, modified, and stored independently of the document itself.

  • Attachments - documents can have multiple attachments of any data type, such as images, audio, or pure binary.
  • Time Series - numerical data associated with specific times and ordered chronologically.

RavenDB Cloud

RavenDB Cloud is a managed database-as-a-service launched in 2019 on AWS, Azure, and GCP. The service performs administration tasks such as hardware maintenance and security for users. It features the sharing of CPU resources among the different nodes in a cluster to avoid throttling.{{Cite web |title=SD Times news digest: Google robots.text parser open sourced, Bonitasoft's cloud and low-code capabilities, and OWASP ZAP 2.8 |url=https://sdtimes.com/goog/sd-times-news-digest-google-robots-text-parser-open-sourced-bonitasofts-cloud-and-low-code-capabilities-and-owasp-zap-2-8/ |date=2019 |website=sdtimes.com |language=en |access-date=10 October 2020}}{{Cite web |title=RavenDB Adds New Enhancements to Its Cloud-Based Database Service |url=https://it.toolbox.com/blogs/shrutiumathe/ravendb-adds-new-enhancements-to-its-cloud-based-database-service-ensuring-high-availability-in-cloud-110419 |date=2019 |website=it.toolbox.com |language=en |access-date=10 October 2020}}

Embedded instance

RavenDB can also be run as an embedded instance, a great option for smaller applications and proof of concepts, for instance.

From their Server: Running an Embedded Instance{{Cite web |title=Server: Running an Embedded Instance |url=https://ravendb.net/docs/article-page/5.3/csharp/server/embedded#server-running-an-embedded-instance |access-date=25 April 2022 |website=Ravendb.net}} page: "RavenDB makes it very easy to be embedded within your application, with RavenDB Embedded package you can integrate your RavenDB server with a few easy steps."

Licensing

RavenDB is open source under an AGPLv3 license. It is available with a commercial license and a free license for open source projects, but it must be applied for.{{Cite book |last=Tannir |first=Khaled |url=https://books.google.com/books?id=ySBz4HBQx8EC |title=RavenDB 2.x beginner's guide |date=2013-09-04 |publisher=Packt Publishing Ltd |isbn=978-1-78328-380-4 |language=en}}

References

{{Reflist

|refs=

{{Cite web|url=https://ravendb.net/about/roadmap|title=An Open Source NoSQL Database | The History of RavenDB|website=RavenDB NoSQL Database}}

{{Cite web|url=https://ravendb.net/articles/ravendb-5-1-features-searching-in-office-documents|title=RavenDB 5.1 Features: Searching in Office documents|website=RavenDB NoSQL Database}}

{{Cite web|url=https://ravendb.net/articles/filtered-replication|title=Filtered Replication | NoSQL Database | RavenDB NoSQL|website=RavenDB NoSQL Database}}

{{Cite web|url=https://www.datavail.com/blog/the-challenges-of-etl-oltp-vs-olap-databases/|title=OLTP vs. OLAP Databases: The Challenges of ETL|date=May 21, 2020|website=Datavail}}

{{Cite web|url=https://ravendb.net/docs|title=NoSQL Database Documentation|website=RavenDB NoSQL Database}}

{{Cite web|url=https://ayende.com/blog/195265-C/ravendb-5-3-new-features-concurrent-subscriptions|title=RavenDB 5.3 New Features: Concurrent subscriptions|website=Ayende @ Rahien}}

{{Cite web|url=https://ayende.com/blog/195300-C/ravendb-features-5-3-power-bi-integration|title=RavenDB Features 5.3: Power BI integration|website=Ayende @ Rahien}}

}}