framework icon indicating copy to clipboard operation
framework copied to clipboard

SqsConnector ignores custom prefix

Open n3ih7 opened this issue 8 months ago • 2 comments

Laravel Version

12.7.2

PHP Version

8.4.5

Database Driver & Version

No response

Description

It ignores custom SQS_PREFIX set in .env, and always POST https://{AWS_DEFAULT_REGION}.ap-southeast-2.amazonaws.com

Error message

[2025-04-07 14:59:46] local.ERROR: Error executing "ReceiveMessage" on "https://sqs.ap-southeast-2.amazonaws.com"; AWS HTTP error: Client error: `POST https://sqs.ap-southeast-2.amazonaws.com` resulted in a `403 Forbidden` response:
{"__type":"com.amazon.coral.service#UnrecognizedClientException","message":"The security token included in the request i (truncated...)
 InvalidClientTokenId (Sender): The security token included in the request is invalid. - {"__type":"com.amazon.coral.service#UnrecognizedClientException","message":"The security token included in the request is invalid."} {"exception":"[object] (Aws\\Sqs\\Exception\\SqsException(code: 0): Error executing \"ReceiveMessage\" on \"https://sqs.ap-southeast-2.amazonaws.com\"; AWS HTTP error: Client error: `POST https://sqs.ap-southeast-2.amazonaws.com` resulted in a `403 Forbidden` response:
{\"__type\":\"com.amazon.coral.service#UnrecognizedClientException\",\"message\":\"The security token included in the request i (truncated...)
 InvalidClientTokenId (Sender): The security token included in the request is invalid. - {\"__type\":\"com.amazon.coral.service#UnrecognizedClientException\",\"message\":\"The security token included in the request is invalid.\"} at /var/www/html/vendor/aws/aws-sdk-php/src/WrappedHttpHandler.php:196)
[stacktrace]

Steps To Reproduce

set SQS_PREFIX as http://elasticmq.local/000000000000 and it will get ignored.

n3ih7 avatar Apr 07 '25 07:04 n3ih7

This might relates to SqsClient SDK update here.

n3ih7 avatar Apr 07 '25 07:04 n3ih7

Thank you for reporting this issue!

As Laravel is an open source project, we rely on the community to help us diagnose and fix issues as it is not possible to research and fix every issue reported to us via GitHub.

If possible, please make a pull request fixing the issue you have described, along with corresponding tests. All pull requests are promptly reviewed by the Laravel team.

Thank you!

github-actions[bot] avatar Apr 11 '25 02:04 github-actions[bot]

@n3ih7 (/cc @crynobone) we had 2 attempts and the answer is:

No has work to do here, close the issue please, thanks.

rafaelqueiroz avatar Oct 28 '25 10:10 rafaelqueiroz