我能够使用AWSSDK.SQS包中的AmazonSQSClient客户端将消息成功发送到.NET中的队列.
I'm able to successfully send messages to a queue in .NET using the AmazonSQSClient clientin the AWSSDK.SQS package.
如何检查特定队列是否存在以及是否没有创建特定队列?
How can I check to see whether a specific queue exists, and if it doesn't create it?
推荐答案您需要使用AmazonSQSClient.GetQueueUrl (string)方法运行检查,其中的字符串是队列名称.如果队列不存在,则抛出QueueDoesNotExistException.为了执行您想要的操作,您需要捕获异常,然后使用该名称创建队列.
You'd need to run a check using the AmazonSQSClient.GetQueueUrl (string) method, where the string is the queue name. If the queue doesn't exist, it throws QueueDoesNotExistException. For you to do what you want, you'd need to catch the exception, and then create the queue using that name.
所有这些都在SQS .Net文档中列出这里
This is all listed in the SQS .Net Documentation here
更多推荐
使用.NET检查AWS中是否存在SQS
发布评论