An SNS topic receives JSON pipeline alerts with a severity field but no message attributes. An SQS subscription must receive only critical alerts without publisher changes; which configuration meets this requirement?
Show the answer
Correct answerB. Set a subscription filter policy matching severity to critical, with MessageBody scope.
AWhy not this: MessageAttributes scope evaluates message attributes, not fields within the JSON message body.
BWhy this is right: MessageBody scope lets the subscription filter match the severity field in the JSON payload.
CWhy not this: A queue access policy controls access to the queue; it does not filter messages by JSON body fields.
DWhy not this: A topic access policy controls access to the topic rather than filtering individual subscription deliveries.
An SNS subscription filter policy with MessageBody scope evaluates fields in a JSON message body before delivery. MessageAttributes scope cannot match the severity field because the publisher sends no message attributes.