From https://docs.aws.amazon.com/lambda/latest/dg/with-sqs.html#events-sqs-queueconfig
Set your queue visibility timeout to 6 times your function timeout, plus the value of
MaximumBatchingWindowInSeconds
Why can't the queue visibility timeout be equal to the function timeout? Let's say the function has a timeout of 30 seconds, so is the queue visibility. The function picks up the message and 30s passed, the message has not been deleted, now it's visible for other functions/consumers. Then why does it have to be 6 times? And what role does maxium batching window plays in queue visiblity timeout?