Example #1
0
 public MessageBatch(Message[] messages, QueueFunctionLogic queue, int maxDequeueCount, TimeSpan visibilityTimeout)
 {
     this.messages          = messages;
     this.queue             = queue;
     this.maxDequeueCount   = maxDequeueCount;
     this.visibilityTimeout = visibilityTimeout;
     processed = new ConcurrentDictionary <string, string>();
 }
Example #2
0
 public Listener(ITriggeredFunctionExecutor executor, QueueFunctionLogic queue,
                 TimeSpan maxBackOff, int maxRetries, TimeSpan visibilityTimeout, int parallelGets,
                 bool shouldRunOnEmptyBatch, ILoggerFactory loggerFactory)
 {
     this.executor              = executor;
     this.queue                 = queue;
     this.maxRetries            = maxRetries;
     this.visibilityTimeout     = visibilityTimeout;
     this.shouldRunOnEmptyBatch = shouldRunOnEmptyBatch;
     this.loggerFactory         = loggerFactory;
     gets    = new Task <IRetrievedMessages> [parallelGets];
     backOff = new RandomizedExponentialBackoffStrategy(TimeSpan.FromMilliseconds(100), maxBackOff);
 }
Example #3
0
 public TriggerBinding(ParameterInfo param, QueueFunctionLogic queue, TimeSpan maxBackOff, int parallelGets, bool shouldRunOnEmptyBatch, ILoggerFactory loggerFactory)
 {
     this.param                 = param;
     this.queue                 = queue;
     this.maxBackOff            = maxBackOff;
     this.parallelGets          = parallelGets;
     this.shouldRunOnEmptyBatch = shouldRunOnEmptyBatch;
     this.loggerFactory         = loggerFactory;
     BindingDataContract        = new Dictionary <string, Type>(StringComparer.OrdinalIgnoreCase)
     {
         { "data", typeof(IMessageBatch) }
     };
 }