How can the company solve this problem?
Turn on termination protection tor the EC2 Instances
Update the visibility timeout for the SQS queue to 3 hours
Configure scale-in protection for the instances during processing
Update the redrive policy and set maxReceiveCount to 0.
Explanations:
Termination protection prevents accidental termination of EC2 instances, but it does not address the underlying issue of videos not being processed properly or messages remaining in the dead-letter queue.
Updating the visibility timeout to 3 hours would only prolong the time a message remains invisible after being received. Since processing takes 30 minutes, this change is unnecessary and would not prevent messages from ending up in the dead-letter queue if they are not processed.
Configuring scale-in protection for the instances during processing ensures that EC2 instances currently processing videos cannot be terminated when the Auto Scaling group scales in. This helps prevent incomplete processing of videos and reduces the likelihood of messages being sent to the dead-letter queue.
Setting maxReceiveCount to 0 in the redrive policy would prevent any message from being sent to the dead-letter queue, effectively making it impossible to handle failures appropriately. This does not resolve the processing issue and could lead to lost messages.