protected override void ConfigureInMemoryReceiveEndpoint(IInMemoryReceiveEndpointConfigurator configurator)
        {
            base.ConfigureInMemoryReceiveEndpoint(configurator);

            _receivedA = GetTask <MessageA>();
            _receivedB = GetTask <MessageB>();

            ConsumerConvention.Remove <AsyncConsumerConvention>();
            ConsumerConvention.Remove <LegacyConsumerConvention>();

            configurator.Consumer(typeof(DefaultHandlers), type => new DefaultHandlers(_receivedA, _receivedB));
        }
        protected override void ConfigureInMemoryReceiveEndpoint(IInMemoryReceiveEndpointConfigurator configurator)
        {
            base.ConfigureInMemoryReceiveEndpoint(configurator);

            _receivedA = GetTask <MessageA>();
            _receivedB = GetTask <MessageB>();

            configurator.UseMessageRetry(r => r.Interval(1, 100));

            ConsumerConvention.Register <CustomConsumerConvention>();

            configurator.Consumer(typeof(CustomHandler), type => new CustomHandler(_receivedA, _receivedB));
        }
Esempio n. 3
0
 static ConsumerConventionCache()
 {
     ConsumerConvention.Register <AsyncConsumerConvention>();
     ConsumerConvention.Register <BatchConsumerConvention>();
     ConsumerConvention.Register <JobConsumerConvention>();
 }
 public Task TearDown()
 {
     ConsumerConvention.Remove <CustomConsumerConvention>();
     return(TaskUtil.Completed);
 }
 public Task TearDown()
 {
     ConsumerConvention.Register <AsyncConsumerConvention>();
     ConsumerConvention.Register <LegacyConsumerConvention>();
     return(TaskUtil.Completed);
 }
 static ConsumerConventionCache()
 {
     ConsumerConvention.Register <AsyncConsumerConvention>();
     ConsumerConvention.Register <LegacyConsumerConvention>();
 }