Skip to content
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

Rolling window limit support #193

Closed
wants to merge 34 commits into from

Commits on Jan 14, 2021

  1. add UnixNanoNow to TimeSource

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    84e3323 View commit details
    Browse the repository at this point in the history
  2. add cache implementation for windowed rate limit

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    8f517f4 View commit details
    Browse the repository at this point in the history
  3. add near limit test for windowed rate limit implementation

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    b1aadd1 View commit details
    Browse the repository at this point in the history
  4. add random jitter test for windowed rate limit implementation

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    f2c6324 View commit details
    Browse the repository at this point in the history
  5. add benchmark for windowed ratelimit

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    ab6f360 View commit details
    Browse the repository at this point in the history
  6. add local cache to windowed ratelimit

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    e516c20 View commit details
    Browse the repository at this point in the history
  7. configure rate limit algorithm to use from setting

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    4a4c9cc View commit details
    Browse the repository at this point in the history
  8. add readme on rate limit algorithm

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    b69f04d View commit details
    Browse the repository at this point in the history
  9. use constant for rate limit algorithm

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    d72f951 View commit details
    Browse the repository at this point in the history
  10. move max min to utils

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    e5704b6 View commit details
    Browse the repository at this point in the history
  11. add more explanation on rolling window implementation

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    b07edff View commit details
    Browse the repository at this point in the history
  12. throw error when rate limit cache type is unknown

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    48446cf View commit details
    Browse the repository at this point in the history
  13. move time conversion related to utils

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    927b23e View commit details
    Browse the repository at this point in the history
  14. move pipeline and cache key method from cache implementation

    Signed-off-by: William Albertus Dembo <[email protected]>
    walbertus authored and zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    f0d3c8b View commit details
    Browse the repository at this point in the history
  15. Fix fixed_window algorithm generate same cache keys

    Co-Authored-By: exagil <[email protected]>
    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq and exagil committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    5e2676b View commit details
    Browse the repository at this point in the history
  16. fix conflicting files

    Co-Authored-By: exagil <[email protected]>
    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq and exagil committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    ffff44a View commit details
    Browse the repository at this point in the history
  17. add memcached rolling window code

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    33f39f9 View commit details
    Browse the repository at this point in the history

Commits on Jan 17, 2021

  1. generate memcached client mock with MockGen

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Jan 17, 2021
    Configuration menu
    Copy the full SHA
    846ba8e View commit details
    Browse the repository at this point in the history

Commits on Jan 20, 2021

  1. refactor rate limit decision to algorithm package

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Jan 20, 2021
    Configuration menu
    Copy the full SHA
    e4e25cc View commit details
    Browse the repository at this point in the history
  2. fix broken rolling window limiter with localcache

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Jan 20, 2021
    Configuration menu
    Copy the full SHA
    244e801 View commit details
    Browse the repository at this point in the history

Commits on Jan 21, 2021

  1. refactor redis & memcached unit tests

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Jan 21, 2021
    Configuration menu
    Copy the full SHA
    510abf5 View commit details
    Browse the repository at this point in the history

Commits on Jan 26, 2021

  1. add compile time check and fix readme

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Jan 26, 2021
    Configuration menu
    Copy the full SHA
    307c27d View commit details
    Browse the repository at this point in the history

Commits on Feb 4, 2021

  1. Configuration menu
    Copy the full SHA
    122cbf5 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    953958e View commit details
    Browse the repository at this point in the history
  3. refactor algorithm interfaces

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Feb 4, 2021
    Configuration menu
    Copy the full SHA
    baf012b View commit details
    Browse the repository at this point in the history

Commits on Feb 9, 2021

  1. fix mocks & add memcached windowed test

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Feb 9, 2021
    Configuration menu
    Copy the full SHA
    1face4c View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    5cc166b View commit details
    Browse the repository at this point in the history
  3. fix format settings.go

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Feb 9, 2021
    Configuration menu
    Copy the full SHA
    8ce4708 View commit details
    Browse the repository at this point in the history
  4. fix memcached windowed unit test

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Feb 9, 2021
    Configuration menu
    Copy the full SHA
    d2d32b4 View commit details
    Browse the repository at this point in the history

Commits on Feb 10, 2021

  1. add unit tests for windowed memcached

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Feb 10, 2021
    Configuration menu
    Copy the full SHA
    bc25eb7 View commit details
    Browse the repository at this point in the history
  2. add fixed algorithm unit test

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Feb 10, 2021
    Configuration menu
    Copy the full SHA
    10404f4 View commit details
    Browse the repository at this point in the history
  3. add rolling window algorithm unit test

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Feb 10, 2021
    Configuration menu
    Copy the full SHA
    3ec9cca View commit details
    Browse the repository at this point in the history

Commits on Feb 20, 2021

  1. Refactor fixed and rolling window

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    Kateryna Nezdolii authored and zufardhiyaulhaq committed Feb 20, 2021
    Configuration menu
    Copy the full SHA
    73df311 View commit details
    Browse the repository at this point in the history
  2. refactor & add base window testing

    Signed-off-by: zufardhiyaulhaq <[email protected]>
    zufardhiyaulhaq committed Feb 20, 2021
    Configuration menu
    Copy the full SHA
    a400046 View commit details
    Browse the repository at this point in the history