Movatterモバイル変換


[0]ホーム

URL:


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

Sign up
Appearance settings

[Messenger] Addbury_on_reject option to Beanstalkd bridge#49652

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
fabpot merged 1 commit intosymfony:7.3fromHypeMC:bury-on-reject
Feb 7, 2025

Conversation

HypeMC
Copy link
Member

@HypeMCHypeMC commentedMar 10, 2023
edited
Loading

QA
Branch?7.3
Bug fix?no
New feature?yes
Deprecations?no
Tickets-
LicenseMIT
Doc PR-

Contains#59273.

This PR adds two improvements to the Beanstalkd bridge:

  1. Beanstalkd has the concept of "buried" jobs, which is a way of denoting that something has gone wrong while the consumer was processing the job. This PR adds abury_on_reject option to bury rejected messages instead of deleting them, which is the current behavior. Since Symfony messenger's retry mechanism sends a new message for each retry and rejects the old one, it would create multiple buried jobs for each failed one. To avoid this issue aSentForRetryStamp was added to identify whether a failed message was sent for retry or not. As long as the retry mechanism keeps sending a new message, the old one will be deleted. Once it finishes, the final rejected message will be buried.

    framework:messenger:transports:some_name:dsn:'%env(MESSENGER_TRANSPORT_DSN)%'options:bury_on_reject:true
  2. Extracted to[Messenger] AddBeanstalkdPriorityStamp to Beanstalkd bridge #59273

spideyfusion, X-Coder264, dominikgalicc, Brajk19, Vorta, matkomat, matijabelec, and stipic reacted with thumbs up emoji
@carsonbotcarsonbot added this to the6.3 milestoneMar 10, 2023
@HypeMCHypeMCforce-pushed thebury-on-reject branch 2 times, most recently fromd27f62e to3243a9fCompareMarch 10, 2023 13:18
@HypeMCHypeMC changed the title[Messenger] Addbury_on_reject option to Beanstalkd bridge[Messenger] Addpriority andbury_on_reject options to Beanstalkd bridgeMar 10, 2023
@HypeMCHypeMC closed thisMar 11, 2023
@HypeMCHypeMC reopened thisMar 12, 2023
@HypeMCHypeMC changed the title[Messenger] Addpriority andbury_on_reject options to Beanstalkd bridge[Messenger] Addbury_on_reject option andBeanstalkdPriorityStamp to Beanstalkd bridgeMar 12, 2023
@HypeMCHypeMCforce-pushed thebury-on-reject branch 2 times, most recently from17fbade toee0db6aCompareMarch 15, 2023 02:18
@nicolas-grekasnicolas-grekas modified the milestones:6.3,6.4May 23, 2023
@spideyfusion
Copy link

@X-Coder264 Could you please give this a glance since you originally worked on this transport implementation?

Copy link
Contributor

@X-Coder264X-Coder264 left a comment

Choose a reason for hiding this comment

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

@spideyfusion The implementation looks good to me 👍

spideyfusion reacted with thumbs up emoji
@HypeMCHypeMCforce-pushed thebury-on-reject branch 3 times, most recently from235b83f to669a8bfCompareSeptember 5, 2023 19:32
@nicolas-grekasnicolas-grekas modified the milestones:6.4,7.1Nov 15, 2023
@OskarStarkOskarStarkforce-pushed thebury-on-reject branch 2 times, most recently fromc6ec2c9 to64e02ecCompareDecember 29, 2023 22:28
@OskarStark
Copy link
Contributor

rebased ✅

@HypeMCHypeMCforce-pushed thebury-on-reject branch 2 times, most recently fromf933998 to7987d87CompareApril 9, 2024 19:56
@HypeMCHypeMCforce-pushed thebury-on-reject branch 2 times, most recently froma340de0 toc66a791CompareApril 9, 2024 20:19
@xabbuhxabbuh modified the milestones:7.1,7.2May 15, 2024
@HypeMCHypeMCforce-pushed thebury-on-reject branch 2 times, most recently from6a9a57c to9197b0bCompareAugust 11, 2024 14:03
@fabpotfabpot modified the milestones:7.2,7.3Nov 20, 2024
@HypeMCHypeMC changed the title[Messenger] Addbury_on_reject option andBeanstalkdPriorityStamp to Beanstalkd bridge[Messenger] Addbury_on_reject option to Beanstalkd bridgeDec 20, 2024
@HypeMCHypeMCforce-pushed thebury-on-reject branch 2 times, most recently fromb706a44 to4ca177eCompareDecember 20, 2024 19:26
fabpot added a commit that referenced this pull requestJan 5, 2025
…d bridge (HypeMC)This PR was merged into the 7.3 branch.Discussion----------[Messenger] Add `BeanstalkdPriorityStamp` to Beanstalkd bridge| Q             | A| ------------- | ---| Branch?       | 7.3| Bug fix?      | no| New feature?  | yes| Deprecations? | no| Issues        | -| License       | MITExtracted from#49652 as the original PR was trying to do two separate things in one.Beanstalkd has the ability to configure the priority at which messages are reserved. This can now be set using the `BeanstalkdPriorityStamp`:```php$this->bus->dispatch(new SomeMessage('some data'), [    new BeanstalkdPriorityStamp(0),]);```Commits-------9926d59 [Messenger] Add BeanstalkdPriorityStamp to Beanstalkd bridge
@fabpot
Copy link
Member

@HypeMC Now that#59273 has been merged, this one can be rebased. Thank you.

@HypeMC
Copy link
MemberAuthor

@HypeMC Now that#59273 has been merged, this one can be rebased. Thank you.

@fabpot Done

@HypeMCHypeMCforce-pushed thebury-on-reject branch 2 times, most recently from2824fcb tobc7dc5dCompareJanuary 27, 2025 02:04
@fabpot
Copy link
Member

Thank you@HypeMC.

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

@fabpotfabpotfabpot approved these changes

@X-Coder264X-Coder264X-Coder264 approved these changes

Assignees
No one assigned
Projects
None yet
Milestone
7.3
Development

Successfully merging this pull request may close these issues.

8 participants
@HypeMC@spideyfusion@OskarStark@fabpot@X-Coder264@nicolas-grekas@xabbuh@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp