-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[DX-687] Update drl_threshold config option description #5546
base: master
Are you sure you want to change the base?
Conversation
… the fallback algos
API Changes --- prev.txt 2023-09-08 19:59:30.800567165 +0000
+++ current.txt 2023-09-08 19:59:21.160140914 +0000
@@ -4504,9 +4504,9 @@
DRLNotificationFrequency int `json:"drl_notification_frequency"`
// A distributed rate limiter is inaccurate on small rate limits, and it will fallback to a Redis or Sentinel rate limiter on an individual user basis, if its rate limiter lower then threshold.
- // A Rate limiter threshold calculated using the following formula: `rate_threshold = drl_threshold * number_of_gateways`.
+ // A Rate limiter threshold is calculated using the following formula: `rate_threshold = drl_threshold * number_of_gateways`.
// So you have 2 Gateways, and your threshold is set to 5, if a user rate limit is larger than 10, it will use the distributed rate limiter algorithm.
- // Default: 5
+ // If the threashold value is set to lower than 0 then the fallback is disabled and DRL will be used regardless of the rate limit. Default: 5.
DRLThreshold float64 `json:"drl_threshold"`
// Controls which algorthm to use as a fallback when your distributed rate limiter can't be used.
@@ -5095,7 +5095,7 @@
// This option should only be used when moving an installation to a new database.
AllowExplicitPolicyID bool `json:"allow_explicit_policy_id"`
// This option is used for storing a policies if `policies.policy_source` is set to `file`.
- // it should be some existing directory path on hard drive
+ // it should be some existing file path on hard drive
PolicyPath string `json:"policy_path"`
}
@@ -8870,9 +8870,6 @@
func (p *ReverseProxy) CheckCircuitBreakerEnforced(spec *APISpec, req *http.Request) (bool, *ExtendedCircuitBreakerMeta)
func (p *ReverseProxy) CheckHardTimeoutEnforced(spec *APISpec, req *http.Request) (bool, float64)
- CheckHardTimeoutEnforced checks APISpec versions for a fine grained timeout
- value. The value is defined in seconds, but we're using float64 to enable
- sub-second durations for tests. Changing to int would break that behaviour.
func (p *ReverseProxy) CheckHeaderInRemoveList(hdr string, spec *APISpec, req *http.Request) bool
@@ -10555,15 +10552,14 @@
Cookies []*http.Cookie `json:",omitempty"`
Delay time.Duration `json:",omitempty"`
BodyMatch string `json:",omitempty"` // regex
+ BodyMatchFunc func([]byte) bool `json:",omitempty"`
BodyNotMatch string `json:",omitempty"`
HeadersMatch map[string]string `json:",omitempty"`
HeadersNotMatch map[string]string `json:",omitempty"`
JSONMatch map[string]string `json:",omitempty"`
ErrorMatch string `json:",omitempty"`
-
- BodyMatchFunc func([]byte) bool `json:"-"`
- BeforeFn func() `json:"-"`
- Client *http.Client `json:"-"`
+ BeforeFn func() `json:"-"`
+ Client *http.Client `json:"-"`
AdminAuth bool `json:",omitempty"`
ControlRequest bool `json:",omitempty"` |
PR Analysis
PR Feedback
How to use
|
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
API tests result: success ✅ |
Update drl_threshold config option description to include turning off the fallback algos
Description
Related Issue
Motivation and Context
How This Has Been Tested
Screenshots (if appropriate)
Types of changes
Checklist