Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

[Messenger] [AmazonSqs] Allow async-aws/sqs version 2 #53524

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 23, 2024

Conversation

smoench
Copy link
Contributor

@smoench smoench commented Jan 12, 2024

Q A
Branch? 5.4
Bug fix? no
New feature? no
Deprecations? no
Issues -
License MIT

With this PR async-aws/sqs version 2 would be allowed to be installed. With version 2 they are using the AWS JSON-1.0 protocol instead of the XML one. They declared this as a BC-Break as they switced the protocol from query to json, but no public method signatures have been changed.

TODO

  • Provide JSON stubs for tests

@carsonbot carsonbot added this to the 6.4 milestone Jan 12, 2024
@carsonbot carsonbot changed the title [Messenger][AmazonSqs] Allow async-aws/sqs version 2 [Messenger] [AmazonSqs] Allow async-aws/sqs version 2 Jan 12, 2024
@OskarStark OskarStark changed the title [Messenger] [AmazonSqs] Allow async-aws/sqs version 2 [Messenger] [AmazonSqs] Allow async-aws/sqs version 2 Jan 13, 2024
Copy link
Member

@xabbuh xabbuh left a comment

Choose a reason for hiding this comment

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

test failures are related

@smoench smoench force-pushed the aysnc-aws/sqs-2.0 branch 2 times, most recently from fc9a4d1 to 8bcfb99 Compare January 15, 2024 08:52
@smoench
Copy link
Contributor Author

smoench commented Jan 15, 2024

Tests are fixed. appveyor failues are unrelated to this PR.

Copy link
Member

@xabbuh xabbuh left a comment

Choose a reason for hiding this comment

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

For 5.4?

@smoench smoench changed the base branch from 6.4 to 5.4 January 15, 2024 10:24
@smoench
Copy link
Contributor Author

smoench commented Jan 15, 2024

Base branch changed to 5.4

@smoench smoench force-pushed the aysnc-aws/sqs-2.0 branch 2 times, most recently from 2634947 to 3d8226a Compare January 15, 2024 10:44
Copy link
Member

@stof stof left a comment

Choose a reason for hiding this comment

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

The dev requirement in the root composer.json should also be updated.

And once this is done, you will need to fix the integration-tests workflow which will break because the asyncaws/testing-sqs docker image only provides a fake implementation of the old protocol. You should migrate to localstack for the integration tests (as was done in async-aws itself)

@smoench
Copy link
Contributor Author

smoench commented Jan 19, 2024

@stof I updated the missing parts :-)

@nicolas-grekas nicolas-grekas modified the milestones: 6.4, 5.4 Jan 23, 2024
@nicolas-grekas
Copy link
Member

Thank you @smoench.

@nicolas-grekas nicolas-grekas merged commit 09cc9c7 into symfony:5.4 Jan 23, 2024
@smoench smoench deleted the aysnc-aws/sqs-2.0 branch January 23, 2024 13:46
nicolas-grekas added a commit that referenced this pull request Jan 23, 2024
…(smoench)

This PR was merged into the 5.4 branch.

Discussion
----------

[Messenger] [AmazonSqs] Allow `async-aws/sqs` version 2

| Q             | A
| ------------- | ---
| Branch?       | 5.4
| Bug fix?      | no
| New feature?  | no <!-- please update src/**/CHANGELOG.md files -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Issues        |  -
| License       | MIT

With this PR async-aws/sqs version 2 would be allowed to be installed. [With version 2 they are using the AWS JSON-1.0 protocol instead of the XML one](https://github.com/async-aws/sqs/blob/master/CHANGELOG.md#200). They declared this as a BC-Break as they switced the protocol from query to json, but no public method signatures have been changed.

TODO
- [x] Provide JSON stubs for tests

Commits
-------

96f103a [Messenger][AmazonSqs] Allow async-aws/sqs version 2
nicolas-grekas added a commit that referenced this pull request Jan 23, 2024
* 6.3:
  minor #53524 [Messenger] [AmazonSqs] Allow `async-aws/sqs` version 2 (smoench)
  Fix bad merge
  List CS fix in .git-blame-ignore-revs
  Fix implicitly-required parameters
  List CS fix in .git-blame-ignore-revs
  Apply php-cs-fixer fix --rules nullable_type_declaration_for_default_null_value
nicolas-grekas added a commit that referenced this pull request Jan 23, 2024
* 6.4:
  Fix implicitly-required parameters
  minor #53524 [Messenger] [AmazonSqs] Allow `async-aws/sqs` version 2 (smoench)
  Fix bad merge
  List CS fix in .git-blame-ignore-revs
  Fix implicitly-required parameters
  List CS fix in .git-blame-ignore-revs
  Apply php-cs-fixer fix --rules nullable_type_declaration_for_default_null_value
  [Messenger][AmazonSqs] Allow async-aws/sqs version 2
nicolas-grekas added a commit that referenced this pull request Jan 23, 2024
* 7.0:
  List CS fix in .git-blame-ignore-revs
  Fix implicitly-required parameters
  minor #53524 [Messenger] [AmazonSqs] Allow `async-aws/sqs` version 2 (smoench)
  Fix bad merge
  List CS fix in .git-blame-ignore-revs
  Fix implicitly-required parameters
  List CS fix in .git-blame-ignore-revs
  Apply php-cs-fixer fix --rules nullable_type_declaration_for_default_null_value
  [Messenger][AmazonSqs] Allow async-aws/sqs version 2
nicolas-grekas added a commit that referenced this pull request Feb 14, 2024
This PR was merged into the 5.4 branch.

Discussion
----------

[Messenger] Fix SQS visibility_timeout type

| Q             | A
| ------------- | ---
| Branch?       | 5.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Issues        | Introduced in #53524
| License       | MIT

Getting an error after `composer update`:

```
Error thrown while running command "messenger:consume -- async". Message: "HTTP 400 returned for "https://sqs.eu-west-1.amazonaws.com/)".

Code:    SerializationException
Message: STRING_VALUE can not be converted to an Integer
Type:
Detail:  "
```

`async-aws/sqs` v2 is using JSON instead of `x-www-form-urlencoded` so now all of the sudden, types do matter. If you set `visibility_timeout` in the DSN, it will be sent as a string to SQS – so we need to cast it explicitly.

Commits
-------

6683d4c Fix SQS visibility_timeout type
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.

6 participants
Morty Proxy This is a proxified and sanitized view of the page, visit original site.