cuddly-jelly-27016
02/14/2025, 1:13 AMeager tasks have the capability to overwhelm the control plane. This change adds a client-side rate limiter. Further protection on the server-side should also be put in place.
What changes were proposed in this pull request?
How was this patch tested?
Unit tested, tested by playing with rate limiter locally, and on a union cluster. Attached screenshots are from union cluster when the rate limit was artificially lowered to 3/min. Five executions are run with the first three kicking off immediately, and after a minute, the remaining two.
Setup process
Screenshots
Screen Shot 2025-02-13 at 5 02 21 PM
Screen Shot 2025-02-13 at 5 02 13 PM
Screen Shot 2025-02-13 at 5 01 30 PM
Check all the applicable boxes
• I updated the documentation accordingly.
• All new and existing tests passed.
• All commits are signed-off.
Related PRs
Docs link
Summary by Bito
Implementation of a client-side rate limiter to prevent control plane overload, featuring a new RateLimiter class with RPM limits. The changes include integration with the worker queue system using a default 60 RPM limit, along with comprehensive unit tests and improved logging visibility.
Unit tests added: True
Estimated effort to review (1-5, lower is better): 2
flyteorg/flytekitcuddly-jelly-27016
02/14/2025, 1:13 AMcuddly-jelly-27016
02/14/2025, 5:45 PM