Daniel-t / node-red-contrib-aws

A collection of Node-RED nodes for AWS.
Apache License 2.0
57 stars 59 forks source link

SQS: How to set request parameters for ReadMessage? #90

Closed prathamesh-gharat closed 2 years ago

prathamesh-gharat commented 2 years ago

For example, how can we set MaxNumberOfMessages on the ReceiveMessage request?

Reference: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/APIReference/API_ReceiveMessage.html

prathamesh-gharat commented 2 years ago

MaxNumberOfMessages property on the msg object 🚀

Reference from code: copyArg(msg,"MaxNumberOfMessages",params,undefined,false); Source: https://github.com/Daniel-t/node-red-contrib-aws/blob/master/SQS.js#L299

Landsailor commented 2 years ago

@prathamesh-gharat Does this work consistently for you?

I have never received ten messages. The number is always between 1 and 5. Perhaps the speed of the AWS instance running Node-RED is the issue?