<commit_before>---
title: MongoDB persistence Sample
summary: This sample shows how use MongoDB to store Sagas and Timeouts.
tags:
- Saga
- Timeouts
related:
- nservicebus/sagas
---


## Prerequisites 

Ensure you have an instance of [MongoDB](https://www.mongodb.org/) running on `localhost:27017`. See [Install MongoDB on Windows](http://docs.mongodb.org/getting-started/shell/tutorial/install-mongodb-on-windows/). 


### MongoDB Persistence for NServiceBus 

This sample utilizes the community run [NServiceBus.MongoDB project](https://github.com/sbmako/NServiceBus.MongoDB). <commit_msg>Update sample.md<commit_after>---
title: MongoDB persistence Sample
summary: This sample shows how use MongoDB to store Sagas and Timeouts.
tags:
- Saga
- Timeout
related:
- nservicebus/sagas
---


## Prerequisites 

Ensure you have an instance of [MongoDB](https://www.mongodb.org/) running on `localhost:27017`. See [Install MongoDB on Windows](http://docs.mongodb.org/getting-started/shell/tutorial/install-mongodb-on-windows/). 


### MongoDB Persistence for NServiceBus 

This sample utilizes the community run [NServiceBus.MongoDB project](https://github.com/sbmako/NServiceBus.MongoDB). 
{'fraction_non_alphanumeric': 0.11720067453625632, 'fraction_numerical': 0.008431703204047217, 'mean_word_length': 4.625592417061611, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '326039', 'n_tokens_mistral': 407, 'n_tokens_neox': 364, 'n_words': 101}