diff --git a/v1/brokers/sqs/sqs.go b/v1/brokers/sqs/sqs.go index a11e419..8de4362 100644 --- a/v1/brokers/sqs/sqs.go +++ b/v1/brokers/sqs/sqs.go @@ -272,6 +272,10 @@ func (b *Broker) consumeOne(delivery *awssqs.ReceiveMessageOutput, taskProcessor sig.SQSReceiptHandle = *delivery.Messages[0].ReceiptHandle } + if delivery.Messages[0].MessageId != nil { + sig.SQSMessageID = *delivery.Messages[0].MessageId + } + if receiveCount := delivery.Messages[0].Attributes[awssqs.MessageSystemAttributeNameApproximateReceiveCount]; receiveCount != nil { if rc, err := strconv.ParseInt(*receiveCount, 10, 64); err == nil { sig.AttemptCount = int(rc) - 1 // SQS receive count includes this attempt, but AttemptCount goes from 0 diff --git a/v1/tasks/signature.go b/v1/tasks/signature.go index eb5ab44..2a947a4 100644 --- a/v1/tasks/signature.go +++ b/v1/tasks/signature.go @@ -67,8 +67,8 @@ type Signature struct { ChordCallback *Signature //MessageGroupId for Broker, e.g. SQS BrokerMessageGroupId string - //ReceiptHandle of SQS Message - SQSReceiptHandle string + SQSReceiptHandle string + SQSMessageID string AzureMessageID string AzurePopReceipt string