Skip to content

[rate-limit] The cached count value differs according to the order of limiters. #830

@y-tabata

Description

@y-tabata

This depends on the lua-resty-limit-traffic.

https://github.com/openresty/lua-resty-limit-traffic/blob/ef080731b80fe00a385a4aed8a7f7f575d01c152/lib/resty/limit/traffic.lua#L26-L29

For example, we have 2 limiters (Limiter1 and Limiter2).
If the Limiter1 is rejected, it is not committed.
If the Limiter2 is rejected, it is committed.

We should call the uncommit in the above code.
Maybe the connections limiters are affected by this.

How to fix this is, first to submit a patch to the lua-resty-limit-traffic, and if no response, then to fork and to use the forked version, right?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions