Skip to content

Conversation

@seb-cr
Copy link
Contributor

@seb-cr seb-cr commented Jan 19, 2024

Currently, sending an SQS message using SQSService does not throw an error by default. This has caught us out a couple of times where we were expecting a failure. The failureMode parameter was added to opt in to throwing errors, to avoid introducing a breaking change in v1.

In v2 we'll throw errors by default, and you'll have to opt out of this behaviour.

Jira: ENG-3013

BREAKING CHANGE: SQSService#publish throws by default instead of handling errors. To maintain old behaviour, you can pass "catch" in the failureMode parameter.

BREAKING CHANGE: `SQSService#publish` throws by default instead of
handling errors. To maintain old behaviour, you can pass `"catch"` in
the `failureMode` parameter.
This makes more sense logically and also makes the diff cleaner.
Copy link
Member

@corinja corinja left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems clear to me.

@seb-cr seb-cr merged commit dca7620 into beta Jan 19, 2024
@seb-cr seb-cr deleted the make-sqs-publish-throw-by-default branch January 19, 2024 14:36
@github-actions
Copy link

🎉 This PR is included in version 2.0.0-beta.14 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants