Пример #1
0
        /// <summary>
        /// Use RavenDB messages persistence by the gateway.
        /// </summary>
        /// <param name="config"></param>
        /// <returns></returns>
        public static Configure UseRavenGatewayPersister(this Configure config)
        {
            if (!config.Configurer.HasComponent <IDocumentStore>())
            {
                config.RavenPersistence();
            }

            config.Configurer.ConfigureComponent <RavenDbPersistence>(DependencyLifecycle.SingleInstance);
            return(config);
        }
Пример #2
0
        /// <summary>
        /// Use RavenDB for message deduplication by the gateway.
        /// </summary>
        /// <param name="config"></param>
        /// <returns></returns>
        public static Configure UseRavenGatewayDeduplication(this Configure config)
        {
            if (!config.Configurer.HasComponent <StoreAccessor>())
            {
                config.RavenPersistence();
            }

            config.Configurer.ConfigureComponent <RavenDBDeduplication>(DependencyLifecycle.SingleInstance);
            return(config);
        }
        public static Configure RavenSagaPersister(this Configure config)
        {
            if (!config.Configurer.HasComponent <StoreAccessor>())
            {
                config.RavenPersistence();
            }

            config.Configurer.ConfigureComponent <RavenSagaPersister>(DependencyLifecycle.InstancePerCall);

            return(config);
        }
Пример #4
0
        public static Configure RavenSubscriptionStorage(this Configure config)
        {
            if (!config.Configurer.HasComponent <StoreAccessor>())
            {
                config.RavenPersistence();
            }

            config.Configurer.ConfigureComponent <RavenSubscriptionStorage>(DependencyLifecycle.SingleInstance);

            return(config);
        }
Пример #5
0
        public static Configure RavenSagaPersister(this Configure config)
        {
            if (!config.Configurer.HasComponent <IDocumentStore>())
            {
                config.RavenPersistence();
            }

            var store = config.Builder.Build <IDocumentStore>();

            return(RavenSagaPersister(config, store));
        }
Пример #6
0
        public static Configure RavenSubscriptionStorage(this Configure config)
        {
            if (!config.Configurer.HasComponent <IDocumentStore>())
            {
                config.RavenPersistence();
            }

            var store = config.Builder.Build <IDocumentStore>();

            return(RavenSubscriptionStorage(config, store, Configure.EndpointName));
        }
Пример #7
0
        /// <summary>
        /// Use the Raven timeout persister implementation.
        /// </summary>
        public static Configure UseRavenTimeoutPersister(this Configure config)
        {
            if (!config.Configurer.HasComponent <StoreAccessor>())
            {
                config.RavenPersistence();
            }

            config.Configurer.ConfigureComponent <RavenTimeoutPersistence>(DependencyLifecycle.SingleInstance);

            return(config);
        }