Beispiel #1
0
        private static IBrowsableElementStore GetBuiltInBrowsableElementStore()
        {
            var connectionString = ConfigurationManager.ConnectionStrings["MyNotes Event Store"].ConnectionString;
            var browsableEventStore = new MsSqlServerEventStoreElementStore(connectionString);

            return browsableEventStore;
        }
Beispiel #2
0
        private static IBrowsableElementStore GetBuiltInBrowsableElementStore()
        {
            var connectionString    = ConfigurationManager.ConnectionStrings["EventStore"].ConnectionString;
            var browsableEventStore = new MsSqlServerEventStoreElementStore(connectionString);

            return(browsableEventStore);
        }
Beispiel #3
0
        static void Main(string[] args)
        {
            // Register all denormalizers in this assembly.
            _bus.RegisterAllHandlersInAssembly(typeof(Program).Assembly);

            var connectionString    = Settings.Default.EventStoreConnectionString;
            var browsableEventStore = new MsSqlServerEventStoreElementStore(connectionString);
            var pipeline            = Pipeline.Create(new CallbackEventProcessor(Process), browsableEventStore);

            pipeline.Start();

            Console.ReadLine();

            pipeline.Stop();
        }
Beispiel #4
0
        static void Main(string[] args)
        {
            var bus = new InProcessEventBus(true);

            bus.RegisterAllHandlersInAssembly(typeof(Program).Assembly);
            var browsableEventStore = new MsSqlServerEventStoreElementStore(Settings.Default.EventStoreConnectionString);
            var buffer   = new InMemoryBufferedBrowsableElementStore(browsableEventStore, 20 /*magic number faund in ThresholedFetchPolicy*/);
            var pipeline = Pipeline.Create("Default", new EventBusProcessor(bus), buffer);

            BootStrapper.BootUp(buffer);
            var commandServiceHost = new ServiceHost(typeof(CommandWebService));

            commandServiceHost.Open();
            pipeline.Start();

            Console.ReadLine();

            pipeline.Stop();
            commandServiceHost.Close();
        }