Skip to main content

The new MongoDB support for NServiceBus

NServiceBus and MongoDB

If you’re using (or considering) MongoDB with NServiceBus, we’ve got good news: we’ve just released our official MongoDB persister. This replaces the previous community-created (but now abandoned) MongoDB persistence options and is now a fully supported part of the Particular Service Platform.

As NoSQL databases have gained in popularity, MongoDB has emerged as one of the go-to choices in the field. MongoDB databases provide high availability and scalability, features which are near and dear to our hearts here at Particular, so it was an easy decision to provide a MongoDB package. As more and more people have embraced MongoDB, we felt it was important to provide an officially supported option for our customers.

With the new package, you can now use MongoDB with NServiceBus version 7. The package supports sagas, subscriptions, and the outbox for all message transports. Full details are available in our MongoDB documentation.

Nice work making the process super easy! The documentation is quite clear about how to make use of the persistence, as well as how to perform a migration from the community NServiceBus.MongoDB package. Billy Wolfington, Senior Software Engineer

Migrating from the community packages

There are two existing MongoDB packages, both of which work only for NServiceBus version 6. Luckily, migrating from either one is straightforward:

The existing community packages are still available, but they are no longer actively developed. We strongly encourage everyone to migrate to NServiceBus version 7 and the official package to take advantage of the new features and our support.

It has been completely seamless for our existing micro-services to migrate to the new mongodb persistence package and “just work”. This was a huge concern for us with the amount of micro-services we have running in production using the legacy package. In addition, we now have first class support for transactions and full confidence in the maintainability of the package itself Matt Biddle, Lead Software Engineer


If you’ve been on the fence about using MongoDB with NServiceBus, now’s the time to take a look. The new package is fully supported, complete with documentation and samples.

Get the official NServiceBus.Storage.MongoDB package today and let us know what you think.

Don't miss a thing. Sign up today and we'll send you an email when new posts come out.
Thank you for subscribing. We'll be in touch soon.
We collect and use this information in accordance with our privacy policy.
Need help getting started?