protected override void EstablishContext() { base.EstablishContext(); LocalEndpoint = EndpointFactory.GetEndpoint(LocalEndpointUri); LocalErrorEndpoint = EndpointFactory.GetEndpoint(LocalErrorUri); RemoteEndpoint = EndpointFactory.GetEndpoint(RemoteEndpointUri); SetupSubscriptionService(); LocalBus = ServiceBusConfigurator.New(x => { x.AddService <SubscriptionPublisher>(); x.AddService <SubscriptionConsumer>(); x.ReceiveFrom(LocalEndpointUri); x.SendErrorsTo(LocalErrorUri); }); RemoteBus = ServiceBusConfigurator.New(x => { x.AddService <SubscriptionPublisher>(); x.AddService <SubscriptionConsumer>(); x.ReceiveFrom(RemoteEndpointUri); }); }
protected override void EstablishContext() { base.EstablishContext(); MsmqEndpointConfigurator.Defaults(x => { x.CreateMissingQueues = true; x.CreateTransactionalQueues = Transactional; x.PurgeOnStartup = true; }); Endpoint = EndpointFactory.GetEndpoint(EndpointAddress.Uri); ErrorEndpoint = EndpointFactory.GetEndpoint(ErrorEndpointAddress.Uri); }