public static bool MyQueueExists(this SqsTestContext context) { var queueExists = false; var tryCount = 0; while (!queueExists && tryCount < 10) { ++tryCount; var listQueuesResponse = context.SqsClient.ListQueues(context.ConnectionConfiguration.QueueNamePrefix); foreach (var q in listQueuesResponse.QueueUrls) { if (q.Contains(context.Address.Queue)) { queueExists = true; } } if (!queueExists) { Thread.Sleep(TimeSpan.FromMilliseconds(500)); } } return(queueExists); }
public void FixtureSetUp() { _context = new SqsTestContext(this); // ensure queue doesn't exist var listQueuesResponse = _context.SqsClient.ListQueues(""); foreach (var q in listQueuesResponse.QueueUrls) { if (q.Contains(_context.Address.Queue)) { _context.SqsClient.DeleteQueue(q); // We'll be creating the queue again shortly. // SQS wants you to wait a little while before you create // a queue with the same name. Thread.Sleep(TimeSpan.FromSeconds(61)); } } }
public void FixtureSetUp() { _context = new SqsTestContext(this); // ensure queue doesn't exist var listQueuesResponse = _context.SqsClient.ListQueues(""); foreach (var q in listQueuesResponse.QueueUrls) { if (q.Contains(_context.Address.Queue)) { _context.SqsClient.DeleteQueue(q); // We'll be creating the queue again shortly. // SQS wants you to wait a little while before you create // a queue with the same name. Thread.Sleep(TimeSpan.FromSeconds(61)); } } }
public void SetUp() { _context = new SqsTestContext(this); }
public void FixtureSetUp() { _context = new SqsTestContext(this); _context.CreateQueue(); _context.InitAndStartDequeueing(); }
public void SetUp() { _context = new SqsTestContext(this); }
public void FixtureSetUp() { _context = new SqsTestContext(this); _context.CreateQueue(); _context.InitAndStartDequeueing(); }