Пример #1
0
        public void can_get_and_increment()
        {
            _num.SetValue(10);

            _num.GetAndIncrement().Should().Be(10);
            _num.GetValue().Should().Be(11);

            _num.GetAndIncrement(5).Should().Be(11);
            _num.GetValue().Should().Be(16);
        }
Пример #2
0
        private CompiledExpression CreateExpressionClass(ISpelNode expressionToCompile)
        {
            var compiledExpression = new SpelCompiledExpression(_loggerFactory);
            var methodName         = "SpelExpression" + _suffixId.GetAndIncrement();
            var method             = new DynamicMethod(methodName, typeof(object), new Type[] { typeof(SpelCompiledExpression), typeof(object), typeof(IEvaluationContext) }, typeof(SpelCompiledExpression));
            var ilGenerator        = method.GetILGenerator(4096);
            var cf = new CodeFlow(compiledExpression);

            try
            {
                expressionToCompile.GenerateCode(ilGenerator, cf);

                var lastDescriptor = cf.LastDescriptor();
                CodeFlow.InsertBoxIfNecessary(ilGenerator, lastDescriptor);
                if (lastDescriptor == TypeDescriptor.V)
                {
                    ilGenerator.Emit(OpCodes.Ldnull);
                }

                ilGenerator.Emit(OpCodes.Ret);
                compiledExpression.MethodDelegate = method.CreateDelegate(typeof(SpelExpressionDelegate));
                var initMethod = cf.Finish(_suffixId.Value);
                if (initMethod != null)
                {
                    compiledExpression.InitDelegate = initMethod.CreateDelegate(typeof(SpelExpressionInitDelegate));
                }

                return(compiledExpression);
            }
            catch (Exception ex)
            {
                _logger?.LogDebug(expressionToCompile.GetType().Name + ".GenerateCode opted out of compilation: " + ex.Message);
                return(null);
            }
        }
            public void Run()
            {
                Operation[] ops    = (Operation[])Enum.GetValues(typeof(Operation));
                int         id     = index.GetAndIncrement();
                Random      random = new Random();

                //debug("#%d: STARTING", id);
                foreach (int key in sets[id])
                {
                    Operation operation = ops[random.NextInt(ops.Length)];
                    try {
                        ActionForOperation(operation)(map, key);
                    } catch (AssertionException ae) {
                        String error =
                            String.Format("Failed: key {0} on operation {1} for node {2}",
                                          key, operation, nodeToString(findNode(key, map)));
                        _test.failures.Enqueue(error);
                        Console.WriteLine(ae);
                        //throw e;
                    } catch (Exception e) {
                        String error =
                            String.Format("Halted: key {0} on operation {1} for node {2} with {3}: {4}",
                                          key, operation, nodeToString(findNode(key, map)), e.GetType(), e.Message);
                        _test.failures.Enqueue(error);
                        Console.WriteLine(e);
                    }
                }
            }
Пример #4
0
        internal Task(TaskActionInvoker invoker, object state, CancellationToken cancellationToken,
                      TaskCreationOptions creationOptions, Task parent = null, Task contAncestor = null, bool ignoreCancellation = false)
        {
            if (SynchronizationContext.Current == null)
            {
                SynchronizationContext.SetSynchronizationContext(new SynchronizationContext());
            }

            this.invoker         = invoker;
            this.creationOptions = creationOptions;
            this.state           = state;
            this.id = lastId.GetAndIncrement();
            this.cancellationToken = cancellationToken;
            //this.parent = parent = parent == null ? current : parent;
            // this.contAncestor = contAncestor;
            this.status = cancellationToken.IsCancellationRequested && !ignoreCancellation ? TaskStatus.Canceled : TaskStatus.Created;

            // Process creationOptions

            //if (parent != null && HasFlag(creationOptions, TaskCreationOptions.AttachedToParent)
            //                   && !HasFlags(parent.creationOptions, TaskCreationOptions.DenyChildAttach))
            //    parent.AddChild();

            if (cancellationToken.CanBeCanceled && !ignoreCancellation)
            {
                cancellationTokenRegistration = cancellationToken.Register(l => ((Task)l).CancelReal(), this);
            }
        }
Пример #5
0
        public void test03()
        {
            var a = new AtomicInteger(1);

            Assert.AreEqual(1, a.GetAndIncrement());
            Assert.AreEqual(2, a.Value);
        }
Пример #6
0
        public T Choose(T[] items)
        {
            if (items == null || items.Length == 0)
            {
                return(default(T));
            }

            int counterValue = counter.GetAndIncrement();

            if (counterValue > MaxValue)
            {
                counter.GetAndSet(0);
            }

            int index = counterValue % items.Length;

            return(items[index]);
        }
Пример #7
0
        /// <summary>
        /// Note: Document instance is re-used per-thread </summary>
        public virtual Document NextDoc()
        {
            string line;

            lock (this)
            {
                line = Reader.ReadLine();
                if (line == null)
                {
                    // Always rewind at end:
                    if (LuceneTestCase.VERBOSE)
                    {
                        Console.WriteLine("TEST: LineFileDocs: now rewind file...");
                    }
                    Dispose();
                    Open(null);
                    line = Reader.ReadLine();
                }
            }

            DocState docState = ThreadDocs.Value;

            if (docState == null)
            {
                docState         = new DocState(UseDocValues);
                ThreadDocs.Value = docState;
            }

            int spot = line.IndexOf(SEP);

            if (spot == -1)
            {
                throw new Exception("line: [" + line + "] is in an invalid format !");
            }
            int spot2 = line.IndexOf(SEP, 1 + spot);

            if (spot2 == -1)
            {
                throw new Exception("line: [" + line + "] is in an invalid format !");
            }

            docState.Body.StringValue = line.Substring(1 + spot2, line.Length - (1 + spot2));
            string title = line.Substring(0, spot);

            docState.Title.StringValue = title;
            if (docState.TitleDV != null)
            {
                docState.TitleDV.BytesValue = new BytesRef(title);
            }
            docState.TitleTokenized.StringValue = title;
            docState.Date.StringValue           = line.Substring(1 + spot, spot2 - (1 + spot));
            docState.Id.StringValue             = Convert.ToString(Id.GetAndIncrement());
            return(docState.Doc);
        }
            public void Test_AtomicInteger()
            {
                AtomicInteger value = new AtomicInteger();

                Assert.Equal(0, value.GetValue());

                var andIncrement = value.GetAndIncrement();

                Assert.Equal(0, andIncrement);
                Assert.Equal(1, value.GetValue());
            }
Пример #9
0
        public void AddValue(params int[] latency)
        {
            foreach (var l in latency)
            {
                /* We just wrap around the beginning and over-write if we go past 'dataLength' as that will effectively cause us to "sample" the most recent data */
                list[index.GetAndIncrement() % length] = l;

                // TODO Alternative to AtomicInteger? The getAndIncrement may be a source of contention on high throughput circuits on large multi-core systems.
                // LongAdder isn't suited to this as it is not consistent. Perhaps a different data structure that doesn't need indexed adds?
                // A threadlocal data storage that only aggregates when fetched would be ideal. Similar to LongAdder except for accumulating lists of data.
            }
        }
Пример #10
0
        public ServerTest(ITestOutputHelper output) : base(output)
        {
            _output = output;
            UserStateFactory.ResetId();

            _serverPort = BaseServerPort.GetAndIncrement();
            _server     = ServerFactory.StartWith(World.Stage, Resources, _serverPort, new Configuration.SizingConf(1, 1, 100, 10240), new Configuration.TimingConf(10, 1, 1000));
            Assert.True(_server.StartUp().Await(TimeSpan.FromMilliseconds(500L)));

            _progress = new Progress();

            _consumer = World.ActorFor <IResponseChannelConsumer>(() => new TestResponseChannelConsumer(_progress));

            _client = new BasicClientRequestResponseChannel(Address.From(Host.Of("localhost"), _serverPort, AddressType.None), _consumer, 100, 10240, World.DefaultLogger);
        }
Пример #11
0
            public virtual Thread NewThread(IRunnable r)
            {
                Thread t = new Thread(r.Run);

                t.Name = namePrefix + threadNumber.GetAndIncrement();
                if (t.IsBackground)
                {
                    t.IsBackground = false;
                }
                if (t.Priority != ThreadPriority.Normal)
                {
                    t.Priority = ThreadPriority.Normal;
                }
                return(t);
            }
Пример #12
0
            private Path ResetHdfsTestDir(Configuration conf)
            {
                Path testDir = new Path("/tmp/" + testName + "-" + counter.GetAndIncrement());

                try
                {
                    // currentUser
                    FileSystem fs = FileSystem.Get(conf);
                    fs.Delete(testDir, true);
                    fs.Mkdirs(testDir);
                }
                catch (Exception ex)
                {
                    throw new RuntimeException(ex);
                }
                return(testDir);
            }
Пример #13
0
            protected override void OnReceive(object message)
            {
                PatternMatch.Match(message)
                .With <string>(str =>
                {
                    if (str.Equals("bar"))
                    {
                        _barCount.GetAndIncrement();
                        _barLatch.CountDown();
                    }

                    if (str.Equals("foo"))
                    {
                        _fooLatch.CountDown();
                    }
                });
            }
Пример #14
0
 /// <exception cref="System.Exception"/>
 public virtual object Answer(InvocationOnMock invocation)
 {
     Log.Info("DelayAnswer firing fireLatch");
     fireCounter.GetAndIncrement();
     fireLatch.CountDown();
     try
     {
         Log.Info("DelayAnswer waiting on waitLatch");
         waitLatch.Await();
         Log.Info("DelayAnswer delay complete");
     }
     catch (Exception ie)
     {
         throw new IOException("Interrupted waiting on latch", ie);
     }
     return(PassThrough(invocation));
 }
Пример #15
0
        public void TestPauseAndResume()
        {
            const string topicName = "zero-queue-pause-and-resume";
            const string subName   = "sub";
            AtomicReference <CountdownEvent> latch = new AtomicReference <CountdownEvent>(new CountdownEvent(1));
            AtomicInteger received = new AtomicInteger();
            var           config   = new ConsumerConfigBuilder <sbyte[]>()
                                     .Topic(topicName)
                                     .SubscriptionName(subName)
                                     .ReceiverQueueSize(0)
                                     .MessageListener(new MessageListener <sbyte[]>((consumer, msg) =>
            {
                Assert.NotNull(msg);
                consumer.Tell(new AcknowledgeMessage <sbyte[]>(msg));
                received.GetAndIncrement();
                latch.Value.AddCount();
            }, null));

            var consumer = _client.NewConsumer(config);

            consumer.Pause();

            var pBuilder = new ProducerConfigBuilder <sbyte[]>()
                           .Topic(topicName)
                           .EnableBatching(false);
            Producer <sbyte[]> producer = _client.NewProducer(pBuilder);

            for (int i = 0; i < 2; i++)
            {
                producer.Send(Encoding.UTF8.GetBytes("my-message-" + i).ToSBytes());
            }

            // Paused consumer receives only one message
            //Assert.True(latch.Value.Wait(TimeSpan.FromSeconds(2)));
            //Thread.Sleep(2000);
            //Assert.Equal(1, received.GetValue());

            //latch.GetAndSet(new CountdownEvent(1));
            consumer.Resume();
            Thread.Sleep(10000);
            //Assert.True(latch.Value.Wait(TimeSpan.FromSeconds(2)), "Timed out waiting for message listener acks");

            consumer.Unsubscribe();
            producer.Close();
        }
Пример #16
0
        public void TestWriteThreadSafety()
        {
            var time = new MockedTime();
            var p    = new HystrixRollingPercentile(time, 100, 25, 1000, true);

            int num_threads    = 10;
            int num_iterations = 1000;

            var latch = new CountdownEvent(num_threads);

            var r = new Random();

            var added = new AtomicInteger(0);

            for (int i = 0; i < num_threads; i++)
            {
                var t = new Task(
                    () =>
                {
                    for (int j = 1; j < (num_iterations / num_threads) + 1; j++)
                    {
                        int nextInt = r.Next(100);
                        p.AddValue(nextInt);
                        added.GetAndIncrement();
                    }

                    latch.SignalEx();
                },
                    CancellationToken.None,
                    TaskCreationOptions.LongRunning);
                t.Start();
            }

            try
            {
                latch.Wait(TimeSpan.FromSeconds(100));
                Assert.Equal(added.Value, p._buckets.PeekLast._data.Length);
            }
            catch (Exception)
            {
                Assert.True(false, "Timeout on all threads writing percentiles");
            }
        }
Пример #17
0
        public virtual long NewId()
        {
            var value = _residue.GetAndIncrement();

            if (value >= BlockSize)
            {
                lock (this)
                {
                    value = _residue.Get();
                    if (value >= BlockSize)
                    {
                        _local.Set(_atomicLong.GetAndIncrement());
                        _residue.Set(0);
                    }
                    return(NewId());
                }
            }
            return(_local.Get() * BlockSize + value);
        }
Пример #18
0
            public override void Run()
            {
                try
                {
                    Latch.Wait();
                }
                catch (ThreadInterruptedException e)
                {
                    throw new ThreadInterruptedException("Thread Interrupted Exception", e);
                }
                int i = 0;

                while ((i = Index.GetAndIncrement()) < Ids.Length)
                {
                    Term term = new Term("id", Ids[i].ToString());
                    Queue.Add(term, Slice);
                    Assert.IsTrue(Slice.IsTailItem(term));
                    Slice.Apply(Deletes, BufferedUpdates.MAX_INT);
                }
            }
Пример #19
0
            internal virtual int Get(T t)
            {
                if (t == null)
                {
                    return(0);
                }
                int sn = t2i[t];

                if (sn == null)
                {
                    sn = max.GetAndIncrement();
                    int old = t2i.PutIfAbsent(t, sn);
                    if (old != null)
                    {
                        return(old);
                    }
                    i2t[sn] = t;
                }
                return(sn);
            }
            /// <exception cref="System.Exception"/>
            public override string Call()
            {
                Random r  = DFSUtil.GetRandom();
                int    op = r.Next(6);

                if (op <= 1)
                {
                    PauseAllFiles();
                    try
                    {
                        string snapshot = GetSnapshotName(snapshotCount.GetAndIncrement());
                        return(CreateSnapshot(snapshot));
                    }
                    finally
                    {
                        StartAllFiles();
                    }
                }
                else
                {
                    if (op <= 3)
                    {
                        string[] keys = Sharpen.Collections.ToArray(snapshotPaths.Keys, EmptyStrings);
                        if (keys.Length == 0)
                        {
                            return("NO-OP");
                        }
                        string snapshot = keys[r.Next(keys.Length)];
                        string s        = CheckSnapshot(snapshot);
                        if (op == 2)
                        {
                            return(DeleteSnapshot(snapshot));
                        }
                        return(s);
                    }
                    else
                    {
                        return("NO-OP");
                    }
                }
            }
Пример #21
0
        /// <summary>Create a snapshot of the given path.</summary>
        /// <remarks>
        /// Create a snapshot of the given path.
        /// It is assumed that the caller will perform synchronization.
        /// </remarks>
        /// <param name="iip">the INodes resolved from the snapshottable directory's path</param>
        /// <param name="snapshotName">The name of the snapshot.</param>
        /// <exception cref="System.IO.IOException">
        /// Throw IOException when 1) the given path does not lead to an
        /// existing snapshottable directory, and/or 2) there exists a
        /// snapshot with the given name for the directory, and/or 3)
        /// snapshot number exceeds quota
        /// </exception>
        public virtual string CreateSnapshot(INodesInPath iip, string snapshotRoot, string
                                             snapshotName)
        {
            INodeDirectory srcRoot = GetSnapshottableRoot(iip);

            if (snapshotCounter == GetMaxSnapshotID())
            {
                // We have reached the maximum allowable snapshot ID and since we don't
                // handle rollover we will fail all subsequent snapshot creation
                // requests.
                //
                throw new SnapshotException("Failed to create the snapshot. The FileSystem has run out of "
                                            + "snapshot IDs and ID rollover is not supported.");
            }
            srcRoot.AddSnapshot(snapshotCounter, snapshotName);
            //create success, update id
            snapshotCounter++;
            numSnapshots.GetAndIncrement();
            return(Org.Apache.Hadoop.Hdfs.Server.Namenode.Snapshot.Snapshot.GetSnapshotPath(snapshotRoot
                                                                                            , snapshotName));
        }
Пример #22
0
        private static FilePath ResetTestCaseDir(string testName)
        {
            FilePath dir = new FilePath(TestDirRoot);

            dir = new FilePath(dir, testName + "-" + counter.GetAndIncrement());
            dir = dir.GetAbsoluteFile();
            try
            {
                Delete(dir);
            }
            catch (IOException ex)
            {
                throw new RuntimeException(MessageFormat.Format("Could not delete test dir[{0}], {1}"
                                                                , dir, ex.Message), ex);
            }
            if (!dir.Mkdirs())
            {
                throw new RuntimeException(MessageFormat.Format("Could not create test dir[{0}]",
                                                                dir));
            }
            return(dir);
        }
Пример #23
0
        public SinglePageApplicationResourceTest(ITestOutputHelper output)
        {
            var converter = new Converter(output);

            Console.SetOut(converter);

            _world = World.StartWithDefaults("static-file-resources");

            var serverPort = BaseServerPort.GetAndIncrement();

            var resources = Resources.Are(new SinglePageApplicationResource(ContentRoot, ContextPath).Routes());
            var sizing    = Configuration.SizingConf.DefineWith(2, 10, 100, 65535);
            var timing    = Configuration.TimingConf.DefineWith(2, 2, 100);

            _server = ServerFactory.StartWith(_world.Stage, resources, serverPort, sizing, timing);
            Assert.True(_server.StartUp().Await(TimeSpan.FromMilliseconds(500)));

            _progress = new Progress();
            var consumer = _world.ActorFor <IResponseChannelConsumer>(() => new TestResponseChannelConsumer(_progress));

            _client = new BasicClientRequestResponseChannel(
                Address.From(Host.Of("localhost"), serverPort, AddressType.None), consumer, 100, 10240,
                _world.DefaultLogger);
        }
Пример #24
0
 public static int Next() => Counter.GetAndIncrement();
 public override void Enqueue(IMessage message)
 {
     enqueuedCount.GetAndIncrement();
     base.Enqueue(message);
 }
 public void HandleMessage(IMessage message) => handledCount.GetAndIncrement();
Пример #27
0
 /// <summary>
 /// Default ctor
 /// </summary>
 protected TaskScheduler()
 {
     id = lastId.GetAndIncrement();
 }
Пример #28
0
        public StaticFilesResourceTest(ITestOutputHelper output)
        {
            var converter = new Converter(output);

            Console.SetOut(converter);

            _world = World.StartWithDefaults("static-file-resources");

            var serverPort = BaseServerPort.GetAndIncrement();

            var properties = new Dictionary <string, string>();

            properties.Add("server.http.port", serverPort.ToString());
            properties.Add("server.dispatcher.pool", "10");
            properties.Add("server.buffer.pool.size", "100");
            properties.Add("server.message.buffer.size", "65535");
            properties.Add("server.probe.interval", "2");
            properties.Add("server.probe.timeout", "2");
            properties.Add("server.processor.pool.size", "10");
            properties.Add("server.request.missing.content.timeout", "100");

            properties.Add("static.files.resource.pool", "5");
            _contentRoot = $"Vlingo.Xoom.Http.Tests.Content";
            properties.Add("static.files.resource.root", _contentRoot);
            properties.Add("static.files.resource.subpaths", "[/, /css, /js, /views]");

            properties.Add("feed.producer.name.events", "/feeds/events");
            properties.Add("feed.producer.events.class", "Vlingo.Xoom.Http.Tests.Resource.Feed.EventsFeedProducerActor");
            properties.Add("feed.producer.events.payload", "20");
            properties.Add("feed.producer.events.pool", "10");

            properties.Add("sse.stream.name.all", "/eventstreams/all");
            properties.Add("sse.stream.all.feed.class", "Vlingo.Xoom.Http.Tests.Sample.User.AllSseFeedActor");
            properties.Add("sse.stream.all.feed.payload", "50");
            properties.Add("sse.stream.all.feed.interval", "1000");
            properties.Add("sse.stream.all.feed.default.id", "-1");
            properties.Add("sse.stream.all.pool", "10");

            properties.Add("resource.name.profile", "[define, query]");

            properties.Add("resource.profile.handler", "Vlingo.Xoom.Http.Tests.Sample.User.ProfileResource");
            properties.Add("resource.profile.pool", "5");
            properties.Add("resource.profile.disallowPathParametersWithSlash", "false");

            properties.Add("action.profile.define.method", "PUT");
            properties.Add("action.profile.define.uri", "/users/{userId}/profile");
            properties.Add("action.profile.define.to",
                           "define(string userId, body:Vlingo.Xoom.Http.Tests.Sample.User.ProfileData profileData)");
            properties.Add("action.profile.define.mapper", "Vlingo.Xoom.Http.Tests.Sample.User.ProfileDataMapper");

            properties.Add("action.profile.query.method", "GET");
            properties.Add("action.profile.query.uri", "/users/{userId}/profile");
            properties.Add("action.profile.query.to", "query(string userId)");
            properties.Add("action.profile.query.mapper", "Vlingo.Xoom.Http.Tests.Sample.User.ProfileDataMapper");

            var httpProperties = HttpProperties.Instance;

            httpProperties.SetCustomProperties(properties);

            var server = ServerFactory.StartWith(_world.Stage, httpProperties);

            Assert.True(server.StartUp().Await(TimeSpan.FromMilliseconds(500L)));

            _progress = new Progress();
            var consumer = _world.ActorFor <IResponseChannelConsumer>(
                () => new TestResponseChannelConsumer(_progress));

            _client = new BasicClientRequestResponseChannel(
                Address.From(Host.Of("localhost"), serverPort, AddressType.None), consumer, 100, 10240,
                _world.DefaultLogger);
        }
Пример #29
0
 public FkSecondPass(ToOne value, Ejb3JoinColumn[] columns)
 {
     this.value    = value;
     this.columns  = columns;
     uniqueCounter = globalCounter.GetAndIncrement();
 }
        public void Handle(IEnumerable <KeyedMessage <TKey, TValue> > events)
        {
            var serializedData = this.Serialize(events);

            foreach (var keyed in serializedData)
            {
                var dataSize = keyed.Message.PayloadSize;
                this.producerTopicStats.GetProducerTopicStats(keyed.Topic).ByteRate.Mark(dataSize);
                this.producerTopicStats.GetProducerAllTopicsStats().ByteRate.Mark(dataSize);
            }

            var outstandingProduceRequests = serializedData;
            var remainingRetries           = this.Config.MessageSendMaxRetries + 1;
            var correlationIdStart         = this.correlationId.Get();

            Logger.DebugFormat("Handling {0} events", events.Count());

            while (remainingRetries > 0 && outstandingProduceRequests.Any())
            {
                foreach (var el in outstandingProduceRequests)
                {
                    this.topicMetadataToRefresh.Add(el.Topic);
                }

                if (this.topicMetadataRefreshInterval >= TimeSpan.MinValue &&
                    (DateTime.Now - this.lastTopicMetadataRefeshTime) > this.topicMetadataRefreshInterval)
                {
                    Util.SwallowError(
                        Logger,
                        () =>
                        this.brokerPartitionInfo.UpdateInfo(
                            new HashSet <string>(this.topicMetadataToRefresh), this.correlationId.GetAndIncrement()));

                    this.sendPartitionPerTopicCache.Clear();
                    this.topicMetadataToRefresh.Clear();
                    this.lastTopicMetadataRefeshTime = DateTime.Now;
                }

                outstandingProduceRequests = this.DispatchSerializedData(outstandingProduceRequests);
                if (outstandingProduceRequests.Any())
                {
                    Logger.InfoFormat("Back off for {0} ms before retrying send. Remaining retries = {1}", this.Config.RetryBackoffMs, remainingRetries - 1);

                    // back off and update the topic metadata cache before attempting another send operation
                    Thread.Sleep(this.Config.RetryBackoffMs);
                    Util.SwallowError(
                        Logger,
                        () =>
                    {
                        brokerPartitionInfo.UpdateInfo(
                            new HashSet <string>(outstandingProduceRequests.Select(r => r.Topic)), correlationId.GetAndIncrement());
                        sendPartitionPerTopicCache.Clear();
                        remainingRetries -= 1;
                        producerStats.ResendRate.Mark();
                    });
                }

                this.sendPartitionPerTopicCache.Clear();
                remainingRetries -= 1;
            }

            if (outstandingProduceRequests.Any())
            {
                this.producerStats.FailedSendRate.Mark();
                var correlationIdEnd = this.correlationId.Get();
                Logger.ErrorFormat("Failed to send requests for topics {0} with correlation ids in [{1}, {2}]", string.Join(",", outstandingProduceRequests.Select(r => r.Topic)), correlationIdStart, correlationIdEnd);

                throw new FailedToSendMessageException(
                          "Failed to send messages after " + this.Config.MessageSendMaxRetries + " tries");
            }
        }