Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[RateLimiter] Add RateLimiterFactoryInterface #58939

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
Feb 7, 2025

Conversation

alexandre-daubois
Copy link
Member

Q A
Branch? 7.3
Bug fix? no
New feature? yes
Deprecations? no
Issues Fix #58920
License MIT

I think it makes sense to create this interface for both being able to implement your own factory logic as well as type-hint against an interface when injecting it.

I would however not make the class non-final as suggested in the issue. The interface only contains one method with not that much logic inside the current implementation.

@fabpot
Copy link
Member

fabpot commented Feb 7, 2025

Thank you @alexandre-daubois.

@fabpot fabpot merged commit 3974926 into symfony:7.3 Feb 7, 2025
11 checks passed
chalasr added a commit that referenced this pull request Mar 7, 2025
…ace` (kbond)

This PR was merged into the 7.3 branch.

Discussion
----------

[FrameworkBundle] fix autowiring `RateLimiterFactoryInterface`

| Q             | A
| ------------- | ---
| Branch?       | 7.3
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Issues        | Fix bug in #58939
| License       | MIT

Fixes a small bug from #58939. Confirmed with `@alexandre`-daubois this was the intention.

Commits
-------

7130a9f [FrameworkBundle] fix autowiring `RateLimiterFactoryInterface`
@fabpot fabpot mentioned this pull request May 2, 2025
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.

[RateLimiter] RateLimiterFactory should implement a generic interface for mocks or be made non-final
5 participants