private WindsorContainer CreateContainer()
 {
     var container = new WindsorContainer(new XmlInterpreter());
     var facility = new RhinoServiceBusFacility().UseFlatQueueStructure();
     container.Kernel.AddFacility("rhino.esb", facility);
     return container;
 }
Exemple #2
0
        public DhtTestBase(IConfigurationInterpreter interpreter)
        {
            EnsureQueueExistsAndIsEmpty("msmq://localhost/dht_test.replication");
            EnsureQueueExistsAndIsEmpty("msmq://localhost/dht_test.replication2");
            EnsureQueueExistsAndIsEmpty("msmq://localhost/dht_test.replication3");

            Delete("cache.esent");
            Delete("cache1.esent");
            Delete("cache2.esent");
            Delete("cache3.esent");
            Delete("test.esent");

            container = new WindsorContainer(interpreter);
            var facility = new RhinoServiceBusFacility();
            bootStrapper = new DhtBootStrapper();
            bootStrapper.ConfigureBusFacility(facility);

            container.Kernel.AddFacility("rhino.esb", facility);

            bus = container.Resolve<IStartableServiceBus>();

            bootStrapper.InitializeContainer(container);

            bus.Start();

            bootStrapper.AfterStart();

            metaDataUrl = new Uri("net.tcp://localhost:8128/dht.metadata");
            client = new DistributedHashTableClient(new Node
            {
                Primary = new NodeUri
                {
                    Sync = metaDataUrl
                }
            });
        }
 public virtual void ConfigureBusFacility(RhinoServiceBusFacility facility)
 {
 }