Database Reference
In-Depth Information
Storage patterns
Here is a very important chart that we will continuously refer to:
The type is the various persistence storage properties that can be persisted. For instance,
when performing publish/subscribe messaging, there is subscription information that needs
to be saved to a database that details the subscribers and the message types that they are
listening for in their queues.
We can have various configurations for these persistence stores: InMemory, RavenDB,
NHibernate and MSMQ. The following bullet list provides a brief explanation of these
stores:
InMemory : This refers to the data that is persisted only to the local memory of the
NSB service. This also means that when a service is stopped or restarted, the data
is no longer saved. A reboot will cause the data to disappear.
RavenDB : This refers to the data that is persisted to a Raven database. RavenDB
is a document-oriented NoSQL database. Regardless of a reboot, the data in
RavenDB will be persisted. It uses JSON documents for communication; see ht-
tp://ravendb.net/docs/intro/ravendb-in-a-nutshell . The default for almost all persist-
ences, except the distributor, which is just MSMQ, is RavenDB.
NHibernate : This is ORM that connects objects to relational databases, such as
SQL Server, MySQL, and Oracle. It normally needs a mapper properties file usu-
ally in the form of XML to map the objects to the SQL. In NSB, it will handle any
mapping that it requires with NHibernate, otherwise you will have to use the map-
ping interface; see http://nhforge.org/ . Regardless of a reboot, the data will be per-
sisted. For NSB configurations, see http://docs.particular.net/nservicebus/
relational-persistence-using-nhibernate .
MSMQ : This refers to the data that is persisted to Microsoft Message Queues
( MSMQs ). MSMQ is an installation of the Windows server that is used for
queuing messages; see http://en.wikipedia.org/wiki/Microsoft_Message_Queuing .
Regardless of a reboot, the messages will be persisted in this configuration.
Search WWH ::




Custom Search