Reading Fathom™ SQS Messages

Currently, only the standard SQS queue is supported. Fathom includes a sequence number
with each message.

Your code must remember the previous sequence number seen. When your code reads a message from SQS, it must ensure the new sequence number is only one increment more than previous sequence number.

If it is more than one increment, the code should ignore the message payload and set the VisibilityTimeout on the message to 1 second and continue reading the next message until the correct sequence number is found.

If the new sequence number is less than previous sequence number, the message should be deleted from SQS and ignored.

If the new sequence number is equal to 1 plus the previous sequence number, the message should deleted from SQS and processed into your system. Message payloads will be in JSON composed of an array of events.

See the API docs for the event format. Sample Node.js code can be obtained from here.




Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request


Please sign in to leave a comment.