summaryrefslogtreecommitdiffstats
path: root/container-search/src/main/resources/configdefinitions/search.config.rate-limiting.def
blob: 81ef06868ce457206e827a39f2a7e1befe36df27 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
# Configuration of the rate limiting algorithm
namespace=search.config

# How much additional capacity to assign to a thread each time it has run out.
# A higher number means less thread contention and less accuracy
capacityIncrement double default=1000

# The max capacity which will ever (and initially) be available to requesting threads on one node
# A higher number means we'll be less sensitive to intermittent overlap
# A good number may be capacityIncrement * 10
maxAvailableCapacity double default=10000

# The probability per request that we check for more quota when we have run out.
# A higher number means less probability of rejecting a request unnecessarily
# but also more thread contention.
# A good number may be 1 / (maxAvailableCapacity * average-cost)
recheckForCapacityProbability double default=0.001

# Set to true to interpret the rate.quota given in the query as a node-local value
# instead of a cluster-wide value.
localRate bool default=false