示例#1
0
        public void Run(int messageCount, int timeOut, int workerCount, int readerCount, int queueSize, ConnectionInfoTypes type, LinqMethodTypes linqMethodTypes)
        {
            var queueName        = GenerateQueueName.Create();
            var connectionString = new ConnectionInfo(type).ConnectionString;
            var consumer         =
                new DotNetWorkQueue.IntegrationTests.Shared.ConsumerMethodAsync.Implementation.
                ConsumerMethodAsyncErrorTable();

            consumer.Run <RedisQueueInit, RedisQueueCreation>(new QueueConnection(queueName, connectionString),
                                                              messageCount, timeOut, workerCount, readerCount, queueSize, linqMethodTypes, false, x => { },
                                                              Helpers.GenerateData, Helpers.Verify, VerifyQueueCount, ValidateErrorCounts);
        }
        public void Run(int messageCount, int timeOut, int workerCount,
                        int readerCount, int queueSize, bool useTransactions, LinqMethodTypes linqMethodTypes, bool enableChaos)
        {
            var queueName = GenerateQueueName.Create();
            var consumer  =
                new DotNetWorkQueue.IntegrationTests.Shared.ConsumerMethodAsync.Implementation.
                ConsumerMethodAsyncErrorTable();

            consumer.Run <PostgreSqlMessageQueueInit, PostgreSqlMessageQueueCreation>(new QueueConnection(queueName,
                                                                                                          ConnectionInfo.ConnectionString),
                                                                                      messageCount, timeOut, workerCount, readerCount, queueSize, linqMethodTypes, enableChaos, x => Helpers.SetOptions(x,
                                                                                                                                                                                                        true, !useTransactions, useTransactions, false,
                                                                                                                                                                                                        false, !useTransactions, true, false),
                                                                                      Helpers.GenerateData, Helpers.Verify, Helpers.VerifyQueueCount, ValidateErrorCounts);
        }