index
int64 0
10.7k
| class
stringclasses 867
values | comment_sentence
stringlengths 1
1.78k
| partition
int64 0
0
| combo
stringlengths 17
1.81k
| labels
sequencelengths 7
7
|
---|---|---|---|---|---|
1,623 | SmoothRateLimiter.java | li when the ratelimiter is used, this goes left down to zero , since if we have | 0 | li when the ratelimiter is used, this goes left down to zero , since if we have | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
0
] |
1,624 | SmoothRateLimiter.java | storedpermits, we serve from those first | 0 | storedpermits, we serve from those first | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
0
] |
1,625 | SmoothRateLimiter.java | li when unused , we go right at a constant rate! | 0 | li when unused , we go right at a constant rate! | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,626 | SmoothRateLimiter.java | the rate at which we move to the right is | 0 | the rate at which we move to the right is | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
0
] |
1,627 | SmoothRateLimiter.java | this ensures that the time it takes to go from 0 to | 0 | this ensures that the time it takes to go from 0 to | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
0
] |
1,628 | SmoothRateLimiter.java | li when used , the time it takes, as explained in the introductory class note, is equal to | 0 | li when used , the time it takes, as explained in the introductory class note, is equal to | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
0
] |
1,629 | SmoothRateLimiter.java | the integral of our function, between x permits and x k permits, assuming we want to | 0 | the integral of our function, between x permits and x k permits, assuming we want to | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
0
] |
1,630 | SmoothRateLimiter.java | spend k saved permits. | 0 | spend k saved permits. | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,632 | SmoothRateLimiter.java | p in summary, the time it takes to move to the left spend k permits , is equal to the area of | 0 | p in summary, the time it takes to move to the left spend k permits , is equal to the area of | SmoothRateLimiter.java | [
1,
0,
0,
1,
0,
0,
0
] |
1,633 | SmoothRateLimiter.java | the function of width k. | 0 | the function of width k. | SmoothRateLimiter.java | [
1,
0,
0,
1,
0,
0,
0
] |
1,634 | SmoothRateLimiter.java | p assuming we have saturated demand, the time to go from maxpermits to thresholdpermits is | 0 | p assuming we have saturated demand, the time to go from maxpermits to thresholdpermits is | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
0
] |
1,635 | SmoothRateLimiter.java | equal to warmupperiod. | 0 | equal to warmupperiod. | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,636 | SmoothRateLimiter.java | and the time to go from thresholdpermits to 0 is warmupperiod 2. | 0 | and the time to go from thresholdpermits to 0 is warmupperiod 2. | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
0
] |
1,637 | SmoothRateLimiter.java | the | 0 | the | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,638 | SmoothRateLimiter.java | reason that this is warmupperiod 2 is to maintain the behavior of the original implementation | 0 | reason that this is warmupperiod 2 is to maintain the behavior of the original implementation | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,639 | SmoothRateLimiter.java | where coldfactor was hard coded as 3. | 0 | where coldfactor was hard coded as 3. | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,640 | SmoothRateLimiter.java | p it remains to calculate thresholdspermits and maxpermits. | 0 | p it remains to calculate thresholdspermits and maxpermits. | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,641 | SmoothRateLimiter.java | li the time to go from thresholdpermits to 0 is equal to the integral of the function | 0 | li the time to go from thresholdpermits to 0 is equal to the integral of the function | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
0
] |
1,642 | SmoothRateLimiter.java | between 0 and thresholdpermits. | 0 | between 0 and thresholdpermits. | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,643 | SmoothRateLimiter.java | this is thresholdpermits stableintervals. | 0 | this is thresholdpermits stableintervals. | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,644 | SmoothRateLimiter.java | therefore | 0 | therefore | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,645 | SmoothRateLimiter.java | thresholdpermits 05 warmupperiod stableinterval | 0 | thresholdpermits 05 warmupperiod stableinterval | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,646 | SmoothRateLimiter.java | li the time to go from maxpermits to thresholdpermits is equal to the integral of the | 0 | li the time to go from maxpermits to thresholdpermits is equal to the integral of the | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
0
] |
1,647 | SmoothRateLimiter.java | function between thresholdpermits and maxpermits. | 0 | function between thresholdpermits and maxpermits. | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,648 | SmoothRateLimiter.java | this is the area of the pictured | 0 | this is the area of the pictured | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,649 | SmoothRateLimiter.java | trapezoid, and it is equal to 05 stableinterval coldinterval maxpermits | 0 | trapezoid, and it is equal to 05 stableinterval coldinterval maxpermits | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,650 | SmoothRateLimiter.java | thresholdpermits . | 0 | thresholdpermits . | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,651 | SmoothRateLimiter.java | maxpermits thresholdpermits 2 warmupperiod stableinterval coldinterval | 0 | maxpermits thresholdpermits 2 warmupperiod stableinterval coldinterval | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,652 | SmoothRateLimiter.java | how is the ratelimiter designed, and why? | 0 | how is the ratelimiter designed, and why? | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,657 | SmoothRateLimiter.java | wait as much. | 0 | wait as much. | SmoothRateLimiter.java | [
1,
0,
0,
0,
0,
0,
0
] |
1,660 | SmoothRateLimiter.java | for example, for a rate of | 0 | for example, for a rate of | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,661 | SmoothRateLimiter.java | qps 5 5 tokens per second , if we ensure that a request isn t granted earlier than 200ms after | 0 | qps 5 5 tokens per second , if we ensure that a request isn t granted earlier than 200ms after | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,663 | SmoothRateLimiter.java | if a request comes and the last request was | 0 | if a request comes and the last request was | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
0
] |
1,665 | SmoothRateLimiter.java | at this rate, serving 15 fresh permits | 0 | at this rate, serving 15 fresh permits | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,667 | SmoothRateLimiter.java | it is important to realize that such a ratelimiter has a very superficial memory of the past | 0 | it is important to realize that such a ratelimiter has a very superficial memory of the past | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
1
] |
1,669 | SmoothRateLimiter.java | what if the ratelimiter was unused for a long period of | 0 | what if the ratelimiter was unused for a long period of | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
1
] |
1,671 | SmoothRateLimiter.java | this ratelimiter would immediately | 0 | this ratelimiter would immediately | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
1
] |
1,674 | SmoothRateLimiter.java | overflow, depending on the real world consequences of not using the expected rate. | 0 | overflow, depending on the real world consequences of not using the expected rate. | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
1
] |
1,680 | SmoothRateLimiter.java | translates to almost empty buffers , which can be filled immediately. | 0 | translates to almost empty buffers , which can be filled immediately. | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,682 | SmoothRateLimiter.java | the request has become less ready for future requests , ie its caches become stale, and | 0 | the request has become less ready for future requests , ie its caches become stale, and | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
0
] |
1,684 | SmoothRateLimiter.java | example is when a server has just booted, and it is mostly busy with getting itself up to | 0 | example is when a server has just booted, and it is mostly busy with getting itself up to | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,686 | SmoothRateLimiter.java | to deal with such scenarios, we add an extra dimension, that of past underutilization , | 0 | to deal with such scenarios, we add an extra dimension, that of past underutilization , | SmoothRateLimiter.java | [
0,
0,
1,
0,
0,
0,
0
] |
1,688 | SmoothRateLimiter.java | this variable is zero when there is no underutilization, | 0 | this variable is zero when there is no underutilization, | SmoothRateLimiter.java | [
0,
0,
1,
1,
0,
0,
0
] |
1,694 | SmoothRateLimiter.java | how this works is best explained with an example | 0 | how this works is best explained with an example | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,696 | SmoothRateLimiter.java | ratelimiter being unused, we increase storedpermits by 1. | 0 | ratelimiter being unused, we increase storedpermits by 1. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,698 | SmoothRateLimiter.java | for 10 seconds ie, we expected a request at time x, but we are at time x 10 seconds before | 0 | for 10 seconds ie, we expected a request at time x, but we are at time x 10 seconds before | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,701 | SmoothRateLimiter.java | at that point, a request of | 0 | at that point, a request of | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,703 | SmoothRateLimiter.java | we serve this request out of storedpermits, and reduce that to 70 how | 0 | we serve this request out of storedpermits, and reduce that to 70 how | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,704 | SmoothRateLimiter.java | this is translated to throttling time is discussed later . | 0 | this is translated to throttling time is discussed later . | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,705 | SmoothRateLimiter.java | immediately after, assume that an | 0 | immediately after, assume that an | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,706 | SmoothRateLimiter.java | acquire 10 request arriving. | 0 | acquire 10 request arriving. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,707 | SmoothRateLimiter.java | we serve the request partly from storedpermits, using all the | 0 | we serve the request partly from storedpermits, using all the | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,708 | SmoothRateLimiter.java | remaining 70 permits, and the remaining 30, we serve them by fresh permits produced by the | 0 | remaining 70 permits, and the remaining 30, we serve them by fresh permits produced by the | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,709 | SmoothRateLimiter.java | rate limiter. | 0 | rate limiter. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,710 | SmoothRateLimiter.java | we already know how much time it takes to serve 3 fresh permits if the rate is | 0 | we already know how much time it takes to serve 3 fresh permits if the rate is | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,711 | SmoothRateLimiter.java | 1 token per second , then this will take 3 seconds. | 0 | 1 token per second , then this will take 3 seconds. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,712 | SmoothRateLimiter.java | but what does it mean to serve 7 stored | 0 | but what does it mean to serve 7 stored | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,713 | SmoothRateLimiter.java | permits? | 0 | permits? | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,714 | SmoothRateLimiter.java | as explained above, there is no unique answer. | 0 | as explained above, there is no unique answer. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,715 | SmoothRateLimiter.java | if we are primarily interested to deal | 0 | if we are primarily interested to deal | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,716 | SmoothRateLimiter.java | with underutilization, then we want stored permits to be given out faster than fresh ones, | 0 | with underutilization, then we want stored permits to be given out faster than fresh ones, | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,717 | SmoothRateLimiter.java | because underutilization free resources for the taking. | 0 | because underutilization free resources for the taking. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,718 | SmoothRateLimiter.java | if we are primarily interested to | 0 | if we are primarily interested to | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,719 | SmoothRateLimiter.java | deal with overflow, then stored permits could be given out slower than fresh ones. | 0 | deal with overflow, then stored permits could be given out slower than fresh ones. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,720 | SmoothRateLimiter.java | thus, we | 0 | thus, we | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,721 | SmoothRateLimiter.java | require a different in each case function that translates storedpermits to throttling time. | 0 | require a different in each case function that translates storedpermits to throttling time. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,724 | SmoothRateLimiter.java | the | 0 | the | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,725 | SmoothRateLimiter.java | underlying model is a continuous function mapping storedpermits from 00 to maxstoredpermits | 0 | underlying model is a continuous function mapping storedpermits from 00 to maxstoredpermits | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,726 | SmoothRateLimiter.java | storedpermits | 0 | storedpermits | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,727 | SmoothRateLimiter.java | essentially measure unused time we spend unused time buying storing permits. | 0 | essentially measure unused time we spend unused time buying storing permits. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,728 | SmoothRateLimiter.java | rate is | 0 | rate is | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,729 | SmoothRateLimiter.java | permits time , thus 1 rate time permits . | 0 | permits time , thus 1 rate time permits . | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,730 | SmoothRateLimiter.java | thus, 1 rate time permits times | 0 | thus, 1 rate time permits times | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,731 | SmoothRateLimiter.java | of requested permits. | 0 | of requested permits. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,732 | SmoothRateLimiter.java | this guarantees that we handle | 0 | this guarantees that we handle | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,733 | SmoothRateLimiter.java | integrals . | 0 | integrals . | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,734 | SmoothRateLimiter.java | cost as fresh ones 1 qps is the cost for each . | 0 | cost as fresh ones 1 qps is the cost for each . | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,735 | SmoothRateLimiter.java | underutilization. | 0 | underutilization. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,736 | SmoothRateLimiter.java | last, but not least consider a ratelimiter with rate of 1 permit per second, currently | 0 | last, but not least consider a ratelimiter with rate of 1 permit per second, currently | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,737 | SmoothRateLimiter.java | completely unused, and an expensive acquire 100 request comes. | 0 | completely unused, and an expensive acquire 100 request comes. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,738 | SmoothRateLimiter.java | it would be nonsensical to just | 0 | it would be nonsensical to just | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,739 | SmoothRateLimiter.java | why wait without doing anything? | 0 | why wait without doing anything? | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,740 | SmoothRateLimiter.java | a much | 0 | a much | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,741 | SmoothRateLimiter.java | instead , and postpone subsequent requests as needed. | 0 | instead , and postpone subsequent requests as needed. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,742 | SmoothRateLimiter.java | task immediately, and postpone by 100 seconds future requests, thus we allow for work to get | 0 | task immediately, and postpone by 100 seconds future requests, thus we allow for work to get | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,743 | SmoothRateLimiter.java | this has important consequences it means that the ratelimiter doesn t remember the time of the | 0 | this has important consequences it means that the ratelimiter doesn t remember the time of the | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,744 | SmoothRateLimiter.java | last request, but it remembers the expected time of the next request. | 0 | last request, but it remembers the expected time of the next request. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,745 | SmoothRateLimiter.java | this also enables | 0 | this also enables | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,746 | SmoothRateLimiter.java | us to tell immediately see tryacquire timeout whether a particular timeout is enough to get | 0 | us to tell immediately see tryacquire timeout whether a particular timeout is enough to get | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,747 | SmoothRateLimiter.java | us to the point of the next scheduling time, since we always maintain that. | 0 | us to the point of the next scheduling time, since we always maintain that. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,748 | SmoothRateLimiter.java | and what we mean by | 0 | and what we mean by | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,749 | SmoothRateLimiter.java | an unused ratelimiter is also defined by that notion when we observe that the | 0 | an unused ratelimiter is also defined by that notion when we observe that the | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,750 | SmoothRateLimiter.java | expected arrival time of the next request is actually in the past, then the difference now | 0 | expected arrival time of the next request is actually in the past, then the difference now | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,751 | SmoothRateLimiter.java | past is the amount of time that the ratelimiter was formally unused, and it is that amount of | 0 | past is the amount of time that the ratelimiter was formally unused, and it is that amount of | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,752 | SmoothRateLimiter.java | time which we translate to storedpermits. | 0 | time which we translate to storedpermits. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,753 | SmoothRateLimiter.java | we increase storedpermits with the amount of permits | 0 | we increase storedpermits with the amount of permits | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,754 | SmoothRateLimiter.java | that would have been produced in that idle time . | 0 | that would have been produced in that idle time . | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,755 | SmoothRateLimiter.java | so, if rate 1 permit per second, and | 0 | so, if rate 1 permit per second, and | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,758 | SmoothRateLimiter.java | we would only increase it for arrivals later than the expected one second. | 0 | we would only increase it for arrivals later than the expected one second. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
1,759 | SmoothRateLimiter.java | the time when the next request no matter its size will be granted. | 0 | the time when the next request no matter its size will be granted. | SmoothRateLimiter.java | [
0,
0,
0,
1,
0,
0,
0
] |
Subsets and Splits