/// <summary> /// Configures Rebus to use MongoDB to store timeouts. /// </summary> public static void StoreInMongoDb(this StandardConfigurer <ITimeoutManager> configurer, MongoDatabase mongoDatabase, string collectionName) { configurer.Register(c => { var subscriptionStorage = new MongoDbTimeoutManager(mongoDatabase, collectionName); return(subscriptionStorage); }); }
/// <summary> /// Configures Rebus to use MongoDB to store timeouts. /// </summary> public static void StoreInMongoDb(this StandardConfigurer <ITimeoutManager> configurer, IMongoDatabase mongoDatabase, string collectionName) { configurer.Register(c => { var rebusLoggerFactory = c.Get <IRebusLoggerFactory>(); var subscriptionStorage = new MongoDbTimeoutManager(mongoDatabase, collectionName, rebusLoggerFactory); return(subscriptionStorage); }); }