我正在从SNS主题向SQS发送消息.当我在客户端检查SQS消息的正文时,整个消息元数据正在SQS正文中发送.
I.E.如果我从主题发送消息“Hello World”,我的客户端正在接收:
BenFlowers { "Type" : "Notification","MessageId" : "84102bd5-8890-4ed5-aeba-c15fafc926dc","TopicArn" : "arn:aws:sns:eu-west-1:534706846367:HelloWorld","Message" : "hello World","Timestamp" : "2012-06-05T13:44:22.360Z","SignatureVersion" : "1","Signature" : "Qzh0qXhijBKylaFwc9PGE+lQQDwHGWkIzCW2Ld1eVrxNfSem4yyBTgouqGX26V0m1qhFD4RQcBzE3oNqx5jFhJfV4hN45FNcsFVnmfLPGNUTmJWblSk8f6znWgTy8UtK9xrTeNYzK59k3VJ4WTJ5kCEj+2vH7sBV15fAXeCAtdQ=","SigningCertURL" : "https://sns.eu-west-1.amazonaws.com/SimpleNotificationService-f3ecfb7224c7233fe7bb5f59f96de52f.pem","UnsubscribeURL" : "https://sns.eu-west-1.amazonaws.com/?Action=Unsubscribe&SubscriptionArn=arn:aws:sns:eu-west-1:534706846367:HelloWorld:8a3acde2-cb0b-4a56-9b9c-b75ed7307556" }
这有点烦人,因为我不得不在另一端拆分消息正文.速度在这个应用程序中非常重要,所以我想消除这一点.有没有办法从SNS发送消息并忽略其余的元数据?
谢谢,
本
解决方法
SNS最近推出了一项功能,允许您在SNS主题上设置“原始邮件传递”.
http://docs.aws.amazon.com/sns/latest/dg/large-payload-raw-message.html