Exemplo n.º 1
0
 internal MessageProcessedAwaiter(object context, Func <TMessage, Task> processMessage, MessageProcessedSettings settings, IRabbitMqWrapper rabbitMq)
 {
     m_context        = context;
     m_settings       = settings;
     m_processMessage = processMessage;
     m_rabbitMq       = rabbitMq;
 }
        internal MessagePublishedAwaiter(TimeSpan timeout, object context, IRabbitMqWrapper rabbitMq, ChannelReader <string> messages)
        {
            m_timeout  = timeout;
            m_context  = context;
            m_rabbitMq = rabbitMq;
            m_messages = messages;

            Task.Run(SubscriberLoop, m_cancellationTokenSource.Token);
        }