Skip to content

Commit e0c05d5

Browse files
authored
StreamRateLimiter change relnote (#44195)
Relnote to accompany the change made in #44145, in case of external filters using the API. Signed-off-by: Raven Black <ravenblack@dropbox.com>
1 parent 65fdd68 commit e0c05d5

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

changelogs/current.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,18 @@ minor_behavior_changes:
135135
and the caller does not want to manage shared pointer ownership. The new shared pointer methods
136136
are intended for use cases where the caller needs to keep the ownerships to the route, cluster,
137137
or virtual host.
138+
- area: http
139+
change: |
140+
``StreamRateLimiter`` constructor was updated to always take a pre-constructed and initialized
141+
``TokenBucket``, and remove the first argument ``max_buffered_data`` and the ``TimeSource&``
142+
argument.
143+
The ``write_stats_cb`` callback signature was changed from taking a ``bool`` argument
144+
"something is buffered" to a ``uint64_t`` "how many bytes are buffered".
145+
If already initializing with a ``TokenBucket``, you may need to call ``maybeReset`` on that
146+
bucket before passing it to ``StreamRateLimiter`` to ensure equivalent initialization.
147+
If previously constructing a ``StreamRateLimiter`` using ``max_buffered_data``, use
148+
``StreamRateLimiter::simpleTokenBucket(limit_kbps, time_source)`` to initialize an equivalent
149+
``TokenBucket``.
138150
139151
bug_fixes:
140152
# *Changes expected to improve the state of the world and are unlikely to have negative effects*

0 commit comments

Comments
 (0)