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

Reduce tooBusy false-negative #17

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Commits on Nov 8, 2016

  1. Reduce tooBusy false-negative

    In my company we realize that toobusy.js generate a large amount of false-positive (Our settings are highWater = 80 & smootingFactor = 1/5).
    Event with this conservative factor, in a sudden load on the service would cause currentLag to jump from 0 to 200+ ms which triggered cause all consecutive requests to be rejected even the server has largely the resource to handle them.
    
    This commit bring a proposal that solve this situation:
    1. Limit the maximum lag value:
    As highWater * 2 == (100% too busy) we want to avoid the current lag to suddenly jump to a stat of rejection all requests.
    Limiting the lag metric to highWater * 2 insure a smooth and coherent current Lag increase.
    
    2. Inverse smoothfactor for decrementing the currentLag value:
    In a situation of a quick punctual overload of the system the recovery should be fast to avoid false-negative rejections when the resources are already available.
    Inverting the smoothfactor when the lag measure is smaller than the current lag insure full resources usage.
    sauvainr authored Nov 8, 2016
    Configuration menu
    Copy the full SHA
    a0fda0c View commit details
    Browse the repository at this point in the history