Question

I am looking for a sample .Net application that continuously checks Amazon SQS for new messages and when one is found, perform an action and remove it from the queue.

My goal is to have an app running on EC2 that watches my SQS queue for new messages. When one is found, a call will be made to one of several web based APIs and the message will be deleted from the queue.

Can someone point me to an example of something similar ?

edit Would this type of application best be created as a windows service?

Was it helpful?

Solution

The AWS SDK for .NET features samples for several Amazon Web Services, including an Amazon SQS Sample, which demonstrates how to make basic requests to Amazon SQS using the AWS SDK for .NET.

The SDK is installed via Windows Installer and integrates with Visual Studio; by default, the desired sample ends up in C:\Program Files (x86)\AWS SDK for .NET\Samples\AmazonSQS_Sample and provides Visual Studio solutions for both versions 2008 and 2010.

OTHER TIPS

Windows service will be a perfect candidate for this.

The following link from amazon aws has a really good summary of details you need to pay attention to: https://aws.amazon.com/blogs/compute/building-loosely-coupled-scalable-c-applications-with-amazon-sqs-and-amazon-sns/

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top