• Bob Van Landuyt's avatar
    Add a dry-run mode for RackAttack · f7562c83
    Bob Van Landuyt authored
    This allows tracking rather than throttling certain or all configured
    throttles.
    
    This can be done by setting the GITLAB_THROTTLE_DRY_RUN env variable
    to a comma separated list of throttles. Each of the throttles
    specified in that list will be tracked instead of throttled.
    
    To disable throttling for all configured throttles, we can specify '*'
    in the environment variable.
    
    When a request would be rate-limited but dry-run mode is set, the
    request continues as normal, but we emit a log message.
    f7562c83
rack_attack_logging.rb 1.2 KB